]> pilppa.org Git - familiar-h63xx-build.git/blob - org.handhelds.familiar/packages/hotplug-ng/files/flags.patch
OE tree imported from monotone branch org.openembedded.oz354fam083 at revision 8b12e3...
[familiar-h63xx-build.git] / org.handhelds.familiar / packages / hotplug-ng / files / flags.patch
1 Index: hotplug-ng-001/Makefile
2 ===================================================================
3 --- hotplug-ng-001.orig/Makefile        2005-02-10 17:40:02.000000000 -0600
4 +++ hotplug-ng-001/Makefile     2005-02-17 11:22:09.000000000 -0600
5 @@ -96,25 +96,28 @@
6                 then echo "-Os"; else echo "-O2" ; fi}
7  
8  # add -Wredundant-decls when libsysfs gets cleaned up
9 -WARNINGS := -Wall 
10 +WARNINGS = -Wall 
11  
12 -CFLAGS := -pipe
13 +CFLAGS = -pipe
14 +rCFLAGS = -D_GNU_SOURCE
15  
16  ifeq ($(strip $(USE_LOG)),true)
17 -       CFLAGS  += -DLOG
18 +       rCFLAGS  += -DLOG
19  endif
20  
21  # if DEBUG is enabled, then we do not strip or optimize
22  ifeq ($(strip $(DEBUG)),true)
23 -       CFLAGS  += -O1 -g -DDEBUG -D_GNU_SOURCE
24 +       CFLAGS  += -O1 -g -DDEBUG
25         LDFLAGS += -Wl,-warn-common
26         STRIPCMD = /bin/true -Since_we_are_debugging
27  else
28 -       CFLAGS  += $(OPTIMIZATION) -fomit-frame-pointer -D_GNU_SOURCE
29 +       CFLAGS  += $(OPTIMIZATION) -fomit-frame-pointer
30         LDFLAGS += -s -Wl,-warn-common
31         STRIPCMD = $(STRIP) -s --remove-section=.note --remove-section=.comment
32  endif
33  
34 +CFLAGS += $(WARNINGS)
35 +
36  # If we are using our version of klibc, then we need to build, link it, and then
37  # link udev against it statically.
38  # Otherwise, use glibc and link dynamically.
39 @@ -132,8 +135,8 @@
40  
41         CRT0 = $(KLIBC_DIR)/crt0.o
42         LIBC = $(ARCH_LIB_OBJS) $(LIB_OBJS) $(CRT0)
43 -       CFLAGS += $(WARNINGS) -nostdinc                         \
44 -               $(OPTFLAGS)                                     \
45 +       CFLAGS += $(OPTFLAGS)
46 +       rCFLAGS += -nostdinc                            \
47                 -D__KLIBC__ -fno-builtin-printf                 \
48                 -I$(KLIBC_FIXUPS_DIR)                           \
49                 -include $(KLIBC_FIXUPS_DIR)/klibc_fixups.h     \
50 @@ -148,17 +151,16 @@
51         WARNINGS += -Wshadow -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations
52         CRT0 =
53         LIBC =
54 -       CFLAGS += $(WARNINGS) -I$(GCCINCDIR)
55         LIB_OBJS = -lc
56         LDFLAGS =
57  endif
58  
59  ifeq ($(strip $(USE_SELINUX)),true)
60 -       CFLAGS += -DUSE_SELINUX
61 +       rCFLAGS += -DUSE_SELINUX
62         LIB_OBJS += -lselinux
63  endif
64  
65 -CFLAGS +=      -I$(PWD)/libsysfs/sysfs \
66 +rCFLAGS +=     -I$(PWD)/libsysfs/sysfs \
67                 -I$(PWD)/libsysfs
68  
69  all: $(ROOT) $(MODULE_ALL) $(GEN_CONFIGS)
70 @@ -169,7 +171,7 @@
71         @if [ ! -r klibc/linux ]; then \
72                 ln -f -s $(KERNEL_DIR) klibc/linux; \
73         fi
74 -       $(MAKE) -C klibc SUBDIRS=klibc
75 +       $(MAKE) -C klibc CFLAGS="$(rCFLAGS) $(CFLAGS)" SUBDIRS=klibc
76  
77  SYSFS =        $(PWD)/libsysfs/sysfs_bus.o     \
78         $(PWD)/libsysfs/sysfs_class.o   \
79 @@ -272,7 +274,7 @@
80  #.c.o:
81  #      $(CC) $(CFLAGS) $(DEFS) $(CPPFLAGS) -c -o $@ $<
82  .c.o:
83 -       $(QUIET) $(CC) $(CFLAGS) -c -o $@ $<
84 +       $(QUIET) $(CC) $(rCFLAGS) $(CFLAGS) -c -o $@ $<
85  
86  
87  clean: