diff options
Diffstat (limited to 'net-misc/ip-sentinel/files/ip-sentinel-0.12-fixed-dietlibc-compat-stuff.patch')
-rw-r--r-- | net-misc/ip-sentinel/files/ip-sentinel-0.12-fixed-dietlibc-compat-stuff.patch | 100 |
1 files changed, 100 insertions, 0 deletions
diff --git a/net-misc/ip-sentinel/files/ip-sentinel-0.12-fixed-dietlibc-compat-stuff.patch b/net-misc/ip-sentinel/files/ip-sentinel-0.12-fixed-dietlibc-compat-stuff.patch new file mode 100644 index 000000000000..051956366fe0 --- /dev/null +++ b/net-misc/ip-sentinel/files/ip-sentinel-0.12-fixed-dietlibc-compat-stuff.patch @@ -0,0 +1,100 @@ +From ecf89e635de8778ebbf901279f7672e2c15e4ecb Mon Sep 17 00:00:00 2001 +From: Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> +Date: Fri, 1 Aug 2008 09:20:46 +0200 +Subject: fixed dietlibc compatibility stuff + +removed lot of compatibility stuff which was needed for ancient +dietlibc version. +--- + src/compat.h | 31 ++----------------------------- + src/util.h | 2 +- + src/wrappers.h | 1 + + 3 files changed, 4 insertions(+), 30 deletions(-) + +diff --git a/src/compat.h b/src/compat.h +index c180185..c6fb409 100644 +--- a/src/compat.h ++++ b/src/compat.h +@@ -19,22 +19,8 @@ + #ifndef H_ENSC_IPSENTINEL_SRC_COMPAT_H + #define H_ENSC_IPSENTINEL_SRC_COMPAT_H + +-#if defined(__dietlibc__) && !defined(ENSC_DIETLIBC_C99) && defined(__STRICT_ANSI__) && defined(__STDC_VERSION__) +- // fixed in 0.25+ +-# include <sys/cdefs.h> +-# undef inline +- +-# undef __STRICT_ANSI__ +-# include <stdint.h> +-# define __STRICT_ANSI__ +-#endif +- + #ifdef __dietlibc__ +- // fixed in 0.27+ +-# define ethhdr ethhdrX +-# include <net/ethernet.h> +-# undef ethhdr +- ++struct ether_addr; + # ifndef HAVE_DIET_ETHER_NTOA + char * ether_ntoa(struct ether_addr const *addr); + # endif +@@ -44,22 +30,9 @@ struct ether_addr * ether_aton_r(const char *asc, struct ether_addr *addr); + # endif + #endif + +- +-#ifndef __dietlibc__ +-# include <stropts.h> +-#else +-# include <sys/ioctl.h> +-#endif +- +-#ifdef __dietlibc__ +-# define sin XsinX +-#endif +-#include <netinet/in.h> +-#undef sin +- +- + #ifdef __dietlibc__ + #include <net/if_arp.h> ++#include <net/ethernet.h> + #include <stdint.h> + + struct ether_arp { +diff --git a/src/util.h b/src/util.h +index 20381e3..adfe3a6 100644 +--- a/src/util.h ++++ b/src/util.h +@@ -25,7 +25,6 @@ + #include <unistd.h> + #include <net/ethernet.h> + +- + /*@-namechecks@*/ + #ifndef __cplusplus + # define cAsT_(X) (X)) +@@ -77,6 +76,7 @@ xstrcat(char **dst, size_t *cnt, char const *src) + xstrcatn(dst, cnt, src, strlen(src)); + } + ++struct in_addr; + void writeUInt(int fd, unsigned int nr); + void writeMsgTimestamp(int fd); + void writeIP(int fd, struct in_addr); +diff --git a/src/wrappers.h b/src/wrappers.h +index e1be0ad..5548702 100644 +--- a/src/wrappers.h ++++ b/src/wrappers.h +@@ -24,6 +24,7 @@ + #include <sys/types.h> + #include <sys/socket.h> + #include <sys/stat.h> ++#include <sys/ioctl.h> + #include <fcntl.h> + #include <pwd.h> + #include <errno.h> +-- +cgit v1.2.1 + |