blob: 962bfc1effba089a58125744a496c8b02588db69 [file] [log] [blame]
Andrew Geisslercc589282020-09-18 13:34:40 -050011) Allow recipe to overide optimization.
2
3fixes:
4
5397 | # warning _FORTIFY_SOURCE requires compiling with optimization (-O)
6| | ^~~~~~~
7| cc1: all warnings being treated as errors
8
92) Allow recipe to override OE related compile-/link-flags
10
11fixes:
12
13ERROR: QA Issue: File /usr/bin/tpm_server in package ibmswtpm2 doesn't have GNU_HASH (didn't pass LDFLAGS?) [ldflags]
14
15Upstream-Status: OE specific
16
17Signed-off-by: Jens Rehsack <sno@NetBSD.org>
18
19Index: src/makefile
20===================================================================
21--- src.orig/makefile
22+++ src/makefile
Patrick Williamsdb4c27e2022-08-05 08:10:29 -050023@@ -38,13 +38,11 @@
Andrew Geisslercc589282020-09-18 13:34:40 -050024 #################################################################################
25
26
27-CC = /usr/bin/gcc
28-
29 CCFLAGS = -Wall \
30 -Wmissing-declarations -Wmissing-prototypes -Wnested-externs \
31 -Werror -Wsign-compare \
Patrick Williamsdb4c27e2022-08-05 08:10:29 -050032 -Wno-deprecated-declarations \
Andrew Geisslercc589282020-09-18 13:34:40 -050033- -c -ggdb -O0 \
34+ -c -ggdb -O \
35 -DTPM_POSIX \
36 -D_POSIX_ \
37 -DTPM_NUVOTON
Patrick Williamsdb4c27e2022-08-05 08:10:29 -050038@@ -80,11 +78,11 @@ TcpServerPosix.o : $(HEADERS)
Andrew Geisslercc589282020-09-18 13:34:40 -050039 .PRECIOUS: %.o
40
41 tpm_server: $(OBJFILES)
42- $(CC) $(OBJFILES) $(LNFLAGS) -o tpm_server
43+ $(CCLD) $(OBJFILES) $(LDFLAGS) $(LNFLAGS) -o tpm_server
44
45 clean:
46 rm -f *.o tpm_server *~
47
48 %.o: %.c
49- $(CC) $(CCFLAGS) $< -o $@
50+ $(CC) $(CCFLAGS) $(CFLAGS) $< -o $@
51