aboutsummaryrefslogtreecommitdiffstats
path: root/testing/dcc/10-dcc-alpine.patch
blob: a277084333a928d6ee7ee52f2facabbc22559cad (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
--- a/configure
+++ b/configure
@@ -465,6 +465,11 @@
 #define DCC_UNIX 1
 EOF
 
+if test -f /etc/alpine-release; then
+cat >> confdefs.h <<\EOF
+#define DCC_ALPINE 1
+EOF
+fi
 
 # How were we started?
 #   Mangle $@ to prevent duplicates from updatedcc -cwhatever
--- a/include/dcc_config.h.in
+++ b/include/dcc_config.h.in
@@ -33,6 +33,7 @@
 
 
 #undef DCC_UNIX
+#undef DCC_ALPINE
 #undef DCC_WIN32			/* define DCC_WIN32 in the makefiles */
 #if !defined(DCC_UNIX) && !defined(DCC_WIN32)
 #error "you must run ./configure"
--- a/include/dcc_types.h
+++ b/include/dcc_types.h
@@ -29,6 +29,9 @@
 
 /* work on WIN32 and any reasonable UNIX platform */
 #ifdef DCC_UNIX
+# ifdef DCC_ALPINE
+#  include <sys/types.h>
+# endif
 #include <stdarg.h>
 #include <stdio.h>			/* for FreeBSD */
 #include <stdlib.h>