summaryrefslogtreecommitdiff
path: root/package/libgpg-error/patches/patch-src_Makefile_in
blob: f33ffcfb7a168c1469d1153a78872c98bc9f1518 (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
--- libgpg-error-1.12.orig/src/Makefile.in	2013-06-24 06:42:26.000000000 +0200
+++ libgpg-error-1.12/src/Makefile.in	2015-11-08 22:40:50.500389023 +0100
@@ -192,6 +192,7 @@ BUILD_TIMESTAMP = @BUILD_TIMESTAMP@
 CC = @CC@
 CCDEPMODE = @CCDEPMODE@
 CC_FOR_BUILD = @CC_FOR_BUILD@
+CFLAGS_FOR_BUILD = @CFLAGS_FOR_BUILD@
 CFLAGS = @CFLAGS@
 CPP = @CPP@
 CPPFLAGS = @CPPFLAGS@
@@ -979,7 +980,7 @@ code-to-errno.h: Makefile mkerrnos.awk e
 # It is correct to use $(CPP).  We want the host's idea of the error codes.
 mkerrcodes.h: Makefile mkerrcodes.awk $(gpg_extra_headers)
 	$(AWK) -f $(srcdir)/mkerrcodes1.awk $(srcdir)/errnos.in >_$@
-	$(CPP) $(CPPFLAGS) $(extra_cppflags) _$@ | grep GPG_ERR_ | \
+	$(CPP) $(CPPFLAGS) $(extra_cppflags) -P _$@ | grep GPG_ERR_ | \
                $(AWK) -f $(srcdir)/mkerrcodes.awk >$@
 	-rm _$@
 
@@ -1006,12 +1007,12 @@ gpg-error.def: Makefile gpg-error.def.in
 # It is correct to use $(CC_FOR_BUILD) here.  We want to run the
 # program at build time.
 mkerrcodes: mkerrcodes.c mkerrcodes.h Makefile
-	$(CC_FOR_BUILD) -I. -I$(srcdir) -o $@ $(srcdir)/mkerrcodes.c
+	$(CC_FOR_BUILD) $(CFLAGS_FOR_BUILD) -I. -I$(srcdir) -o $@ $(srcdir)/mkerrcodes.c
 
 # It is correct to use $(CC_FOR_BUILD) here.  We want to run the
 # program at build time.
 @HAVE_W32CE_SYSTEM_TRUE@mkw32errmap: mkw32errmap.c mkw32errmap.tab.h Makefile
-@HAVE_W32CE_SYSTEM_TRUE@	$(CC_FOR_BUILD) -I. -I$(srcdir) -o $@ $(srcdir)/mkw32errmap.c
+@HAVE_W32CE_SYSTEM_TRUE@	$(CC_FOR_BUILD) $(CC_FOR_BUILD) -I. -I$(srcdir) -o $@ $(srcdir)/mkw32errmap.c
 
 code-from-errno.h: mkerrcodes Makefile
 	./mkerrcodes | $(AWK) -f $(srcdir)/mkerrcodes2.awk >$@