diff options
author | Nuno Teixeira <eduardo@FreeBSD.org> | 2023-03-27 13:30:18 +0100 |
---|---|---|
committer | Nuno Teixeira <eduardo@FreeBSD.org> | 2023-03-27 13:33:43 +0100 |
commit | fb22e1c2e3653558065ffa0509c3c020834723db (patch) | |
tree | d10eea15523e52e7b2b8b6749eb87cf167f2ba49 /net | |
parent | 7ed99c3cb0fc2d93b6251d4ebecc4db0e003b1ff (diff) | |
download | freebsd-ports-fb22e1c2e3653558065ffa0509c3c020834723db.zip |
net/sflowtool: Update to 6.01
- Add patch to fix build on versions that do not have glibc/linux
compatible byteswap.h
ChangeLog: https://github.com/sflow/sflowtool/releases/tag/v6.01
Diffstat (limited to 'net')
-rw-r--r-- | net/sflowtool/Makefile | 9 | ||||
-rw-r--r-- | net/sflowtool/distinfo | 6 | ||||
-rw-r--r-- | net/sflowtool/files/extra-patch-src_sflowtool.c | 25 |
3 files changed, 36 insertions, 4 deletions
diff --git a/net/sflowtool/Makefile b/net/sflowtool/Makefile index e637ae85e1ab..9a237f54a1df 100644 --- a/net/sflowtool/Makefile +++ b/net/sflowtool/Makefile @@ -1,6 +1,6 @@ PORTNAME= sflowtool DISTVERSIONPREFIX= v -DISTVERSION= 5.08 +DISTVERSION= 6.01 CATEGORIES= net MAINTAINER= eduardo@FreeBSD.org @@ -26,6 +26,13 @@ PORTEXAMPLES= sflowenable OPTIONS_DEFINE= DOCS EXAMPLES +.include <bsd.port.options.mk> + +# Patch byteswap.h where not available +.if ${OPSYS} == FreeBSD && ${OSVERSION} < 1301511 +EXTRA_PATCHES= ${PATCHDIR}/extra-patch-src_sflowtool.c +.endif + post-install: @${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${PORTDOCS:S|^|${WRKSRC}/|} ${STAGEDIR}${DOCSDIR} diff --git a/net/sflowtool/distinfo b/net/sflowtool/distinfo index e092aaaf9da6..40a6a3f22490 100644 --- a/net/sflowtool/distinfo +++ b/net/sflowtool/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1667822009 -SHA256 (sflow-sflowtool-v5.08_GH0.tar.gz) = 70a1930e1a99077c0cf92d4205c744aaeaadb794927bae8b98463075432b4a8a -SIZE (sflow-sflowtool-v5.08_GH0.tar.gz) = 79065 +TIMESTAMP = 1679650144 +SHA256 (sflow-sflowtool-v6.01_GH0.tar.gz) = 4cc9f4512a3dcb7da6a970b1de06e3f2fcb599a605e9cfeddd34bd7b9b687f3c +SIZE (sflow-sflowtool-v6.01_GH0.tar.gz) = 81155 diff --git a/net/sflowtool/files/extra-patch-src_sflowtool.c b/net/sflowtool/files/extra-patch-src_sflowtool.c new file mode 100644 index 000000000000..b851dddedd14 --- /dev/null +++ b/net/sflowtool/files/extra-patch-src_sflowtool.c @@ -0,0 +1,25 @@ +--- src/sflowtool.c.orig 2023-03-23 17:36:24 UTC ++++ src/sflowtool.c +@@ -29,13 +29,21 @@ extern "C" { + #include <inttypes.h> + #include <arpa/inet.h> + #include <netdb.h> +-#include <byteswap.h> ++#include <sys/endian.h> + #include <getopt.h> + + #include "sflow.h" /* sFlow v5 */ + #include "sflow_v2v4.h" /* sFlow v2/4 */ + #include "assert.h" + #include "sflow_xdr.h" /* sFlow encode */ ++ ++#define __bswap_16(x) __bswap16(x) ++#define __bswap_32(x) __bswap32(x) ++#define __bswap_64(x) __bswap64(x) ++ ++#define bswap_16(x) __bswap16(x) ++#define bswap_32(x) __bswap32(x) ++#define bswap_64(x) __bswap64(x) + + #define SPOOFSOURCE 1 + #define YES 1 |