aboutsummaryrefslogtreecommitdiffstats
path: root/include/rules.make
diff options
context:
space:
mode:
Diffstat (limited to 'include/rules.make')
-rw-r--r--include/rules.make7
1 files changed, 5 insertions, 2 deletions
diff --git a/include/rules.make b/include/rules.make
index 14ccdee..b2b6336 100644
--- a/include/rules.make
+++ b/include/rules.make
@@ -1,5 +1,6 @@
CC=diet gcc
-CFLAGS=-mpreferred-stack-boundary=2 -malign-jumps=0 -malign-loops=0 -malign-functions=0 -Os -march=i386 -mcpu=i386
+CFLAGS=$(GCC_ARCH_SMALL) $(GCC_CPU_SMALL) $(GCC_OPT_SMALL)
+#-mpreferred-stack-boundary=2 -malign-jumps=0 -malign-loops=0 -malign-functions=0 -Os -march=i386 -mcpu=i386
LDFLAGS=-s
all: $(OBJS)
@@ -8,12 +9,14 @@ all: $(OBJS)
$(CC) $(LDFLAGS) $(CFLAGS) -o $@ $<
strip -R .comment -R .note $@
objdump -h $@ | grep -q '\.data[ ]*00000000' && strip -R .data $@ || true
- sstrip $@
+ objdump -h $@ | grep -q '\.sbss[ ]*00000000' && strip -R .sbss $@ || true
+ -sstrip $@
%-debug: %.c
$(CC) $(LDFLAGS) $(CFLAGS) -DDEBUG -o $@ $<
strip -R .comment -R .note $@
objdump -h $@ | grep -q '\.data[ ]*00000000' && strip -R .data $@ || true
+ objdump -h $@ | grep -q '\.sbss[ ]*00000000' && strip -R .sbss $@ || true
clean:
@rm -f *.[ao] *~ core