diff options
author | Erik Andersen <andersen@codepoet.org> | 2000-05-16 20:07:38 +0000 |
---|---|---|
committer | Erik Andersen <andersen@codepoet.org> | 2000-05-16 20:07:38 +0000 |
commit | 499f65fb98a8258f8704b52efb3a99da0c82f785 (patch) | |
tree | 8bb86bf2d07ab298eff29daea039449e87d90166 /Makefile | |
parent | 969f9b0486792829378ff7397ee53c1475b22cdc (diff) | |
download | busybox-w32-499f65fb98a8258f8704b52efb3a99da0c82f785.tar.gz busybox-w32-499f65fb98a8258f8704b52efb3a99da0c82f785.tar.bz2 busybox-w32-499f65fb98a8258f8704b52efb3a99da0c82f785.zip |
Some updates for better portability.
-Erik
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 18 |
1 files changed, 10 insertions, 8 deletions
@@ -31,6 +31,12 @@ DODEBUG = false | |||
31 | # If you want a static binary, turn this on. | 31 | # If you want a static binary, turn this on. |
32 | DOSTATIC = false | 32 | DOSTATIC = false |
33 | 33 | ||
34 | # To compile vs an alternative libc, you may need to use/adjust | ||
35 | # the following lines to meet your needs. This is how I did it... | ||
36 | #CFLAGS+=-nostdinc -I/home/andersen/CVS/uC-libc/include -I/usr/include/linux | ||
37 | #LDFLAGS+=-nostdlib -L/home/andersen/CVS/libc.a | ||
38 | |||
39 | |||
34 | CC = gcc | 40 | CC = gcc |
35 | 41 | ||
36 | # use '-Os' optimization if available, else use -O2 | 42 | # use '-Os' optimization if available, else use -O2 |
@@ -43,10 +49,6 @@ ifndef $(STRIPTOOL) | |||
43 | STRIPTOOL = strip | 49 | STRIPTOOL = strip |
44 | endif | 50 | endif |
45 | 51 | ||
46 | # TODO: Try compiling vs other libcs. | ||
47 | # See what -nostdinc and -nostdlib do for them. | ||
48 | # also try --prefix=/usr/my-libc-stuff | ||
49 | |||
50 | # -D_GNU_SOURCE is needed because environ is used in init.c | 52 | # -D_GNU_SOURCE is needed because environ is used in init.c |
51 | ifeq ($(DODEBUG),true) | 53 | ifeq ($(DODEBUG),true) |
52 | CFLAGS += -Wall -g -D_GNU_SOURCE | 54 | CFLAGS += -Wall -g -D_GNU_SOURCE |
@@ -65,11 +67,10 @@ else | |||
65 | #want to give it a shot... | 67 | #want to give it a shot... |
66 | # | 68 | # |
67 | #ifeq ($(shell $(CC) -ffunction-sections -fdata-sections -S \ | 69 | #ifeq ($(shell $(CC) -ffunction-sections -fdata-sections -S \ |
68 | # -o /dev/null -xc /dev/null && $(LD) --gc-sections -v >/dev/null && echo 1),1) | 70 | # -o /dev/null -xc /dev/null 2>/dev/null && $(LD) --gc-sections -v >/dev/null && echo 1),1) |
69 | # CFLAGS += -ffunction-sections -fdata-sections -DFUNCTION_SECTIONS | 71 | # CFLAGS += -ffunction-sections -fdata-sections |
70 | # LDFLAGS += --gc-sections | 72 | # LDFLAGS += --gc-sections |
71 | #endif | 73 | #endif |
72 | # | ||
73 | endif | 74 | endif |
74 | endif | 75 | endif |
75 | 76 | ||
@@ -77,6 +78,7 @@ ifndef $(PREFIX) | |||
77 | PREFIX = `pwd`/_install | 78 | PREFIX = `pwd`/_install |
78 | endif | 79 | endif |
79 | 80 | ||
81 | |||
80 | LIBRARIES = | 82 | LIBRARIES = |
81 | OBJECTS = $(shell ./busybox.sh) busybox.o messages.o utility.o | 83 | OBJECTS = $(shell ./busybox.sh) busybox.o messages.o utility.o |
82 | CFLAGS += -DBB_VER='"$(VERSION)"' | 84 | CFLAGS += -DBB_VER='"$(VERSION)"' |