diff options
author | Rob Landley <rob@landley.net> | 2006-06-22 22:05:00 +0000 |
---|---|---|
committer | Rob Landley <rob@landley.net> | 2006-06-22 22:05:00 +0000 |
commit | 1fa4a9448b4909fb6baf9953c14760f588b680bc (patch) | |
tree | 8826d70851922a008a0412609d3652d4828a7c8a | |
parent | 67d49433930b2e2e9b5af54ebaca072a7b1b4eaa (diff) | |
download | busybox-w32-1fa4a9448b4909fb6baf9953c14760f588b680bc.tar.gz busybox-w32-1fa4a9448b4909fb6baf9953c14760f588b680bc.tar.bz2 busybox-w32-1fa4a9448b4909fb6baf9953c14760f588b680bc.zip |
Patch from Shaun Jackman to replace CFLAGS_EXTRA with .config.mak
-rw-r--r-- | Config.in | 9 | ||||
-rw-r--r-- | Rules.mak | 22 | ||||
-rw-r--r-- | TODO | 2 | ||||
-rw-r--r-- | include/platform.h | 2 |
4 files changed, 3 insertions, 32 deletions
@@ -307,15 +307,6 @@ config CROSS_COMPILER_PREFIX | |||
307 | then I would enter '/usr/i386-linux-uclibc/bin/i386-uclibc-' here, | 307 | then I would enter '/usr/i386-linux-uclibc/bin/i386-uclibc-' here, |
308 | which will ensure the correct compiler is used. | 308 | which will ensure the correct compiler is used. |
309 | 309 | ||
310 | config EXTRA_CFLAGS_OPTIONS | ||
311 | string "Any extra CFLAGS options for the compiler?" | ||
312 | default "" | ||
313 | help | ||
314 | Do you want to pass any extra CFLAGS options to the compiler as | ||
315 | you build BusyBox? If so, this is the option for you... For example, | ||
316 | if you want to add some simple compiler switches (like -march=i686), | ||
317 | or check for warnings using -Werror, just those options here. | ||
318 | |||
319 | config CONFIG_BUILD_AT_ONCE | 310 | config CONFIG_BUILD_AT_ONCE |
320 | bool "Compile all sources at once" | 311 | bool "Compile all sources at once" |
321 | default n | 312 | default n |
@@ -52,26 +52,6 @@ TARGET_OS=linux | |||
52 | # Ensure consistent sort order, 'gcc -print-search-dirs' behavior, etc. | 52 | # Ensure consistent sort order, 'gcc -print-search-dirs' behavior, etc. |
53 | LC_ALL:= C | 53 | LC_ALL:= C |
54 | 54 | ||
55 | # If you want to add some simple compiler switches (like -march=i686), | ||
56 | # especially from the command line, use this instead of CFLAGS directly. | ||
57 | # For optimization overrides, it's better still to set OPTIMIZATION. | ||
58 | CFLAGS_EXTRA=$(subst ",, $(strip $(EXTRA_CFLAGS_OPTIONS))) | ||
59 | # be gentle to vi coloring.. ") | ||
60 | |||
61 | # To compile vs some other alternative libc, you may need to use/adjust | ||
62 | # the following lines to meet your needs... | ||
63 | # | ||
64 | # If you are using Red Hat 6.x with the compatible RPMs (for developing under | ||
65 | # Red Hat 5.x and glibc 2.0) uncomment the following. Be sure to read about | ||
66 | # using the compatible RPMs (compat-*) at http://www.redhat.com ! | ||
67 | #LIBCDIR:=/usr/i386-glibc20-linux | ||
68 | # | ||
69 | # For other libraries, you are on your own. But these may (or may not) help... | ||
70 | #LDFLAGS+=-nostdlib | ||
71 | #LIBRARIES:=$(LIBCDIR)/lib/libc.a -lgcc | ||
72 | #CROSS_CFLAGS+=-nostdinc -I$(LIBCDIR)/include -I$(GCCINCDIR) -funsigned-char | ||
73 | #GCCINCDIR:=$(shell gcc -print-search-dirs | $(SED) -ne "s/install: \(.*\)/\1include/gp") | ||
74 | |||
75 | # This must bind late because srcdir is reset for every source subdirectory. | 55 | # This must bind late because srcdir is reset for every source subdirectory. |
76 | INCS:=-I$(top_builddir)/include -I$(top_srcdir)/include | 56 | INCS:=-I$(top_builddir)/include -I$(top_srcdir)/include |
77 | CFLAGS=$(INCS) -I$(srcdir) -D_GNU_SOURCE | 57 | CFLAGS=$(INCS) -I$(srcdir) -D_GNU_SOURCE |
@@ -343,7 +323,7 @@ endif | |||
343 | 323 | ||
344 | # Put user-supplied flags at the end, where they | 324 | # Put user-supplied flags at the end, where they |
345 | # have a chance of winning. | 325 | # have a chance of winning. |
346 | CFLAGS += $(CFLAGS_EXTRA) | 326 | -include $(top_builddir)/.config.mak |
347 | 327 | ||
348 | #------------------------------------------------------------ | 328 | #------------------------------------------------------------ |
349 | # Installation options | 329 | # Installation options |
@@ -179,7 +179,7 @@ Memory Allocation | |||
179 | allocation on the stack or the heap. Unfortunately, we're not using it much. | 179 | allocation on the stack or the heap. Unfortunately, we're not using it much. |
180 | We need to audit our memory allocations and turn a lot of malloc/free calls | 180 | We need to audit our memory allocations and turn a lot of malloc/free calls |
181 | into RESERVE_CONFIG_BUFFER/RELEASE_CONFIG_BUFFER. | 181 | into RESERVE_CONFIG_BUFFER/RELEASE_CONFIG_BUFFER. |
182 | For a start, see e.g. make CFLAGS_EXTRA=-Wlarger-than-64 | 182 | For a start, see e.g. make EXTRA_CFLAGS=-Wlarger-than-64 |
183 | 183 | ||
184 | And while we're at it, many of the CONFIG_FEATURE_CLEAN_UP #ifdefs will be | 184 | And while we're at it, many of the CONFIG_FEATURE_CLEAN_UP #ifdefs will be |
185 | optimized out by the compiler in the stack allocation case (since there's no | 185 | optimized out by the compiler in the stack allocation case (since there's no |
diff --git a/include/platform.h b/include/platform.h index f23d1fb0b..636c1a56c 100644 --- a/include/platform.h +++ b/include/platform.h | |||
@@ -174,7 +174,7 @@ typedef unsigned long long int uintmax_t; | |||
174 | /* uclibc does not implement daemon for no-mmu systems. | 174 | /* uclibc does not implement daemon for no-mmu systems. |
175 | * For 0.9.29 and svn, __ARCH_USE_MMU__ indicates no-mmu reliably. | 175 | * For 0.9.29 and svn, __ARCH_USE_MMU__ indicates no-mmu reliably. |
176 | * For earlier versions there is no reliable way to check if we are building | 176 | * For earlier versions there is no reliable way to check if we are building |
177 | * for a mmu-less system; the user should pass CFLAGS_EXTRA="-DBB_NOMMU" | 177 | * for a mmu-less system; the user should pass EXTRA_CFLAGS="-DBB_NOMMU" |
178 | * on his own. | 178 | * on his own. |
179 | */ | 179 | */ |
180 | #if defined __UCLIBC__ && __UCLIBC_MAJOR__ >= 0 && __UCLIBC_MINOR__ >= 9 && \ | 180 | #if defined __UCLIBC__ && __UCLIBC_MAJOR__ >= 0 && __UCLIBC_MINOR__ >= 9 && \ |