summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile12
1 files changed, 11 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 0f0b22db72..f922a3ea3c 100644
--- a/Makefile
+++ b/Makefile
@@ -7,13 +7,23 @@ DEFINES=-DHAVE_BYTESWAP_H
ifeq ($(ARCH),i386)
CFLAGS+=-fomit-frame-pointer
-OP_CFLAGS=$(CFLAGS) -malign-functions=0 -mpreferred-stack-boundary=2
+OP_CFLAGS=$(CFLAGS) -mpreferred-stack-boundary=2
+ifeq ($(GCC_MAJOR),3)
+OP_CFLAGS+= -falign-functions=0
+else
+OP_CFLAGS+= -malign-functions=0
+endif
endif
ifeq ($(ARCH),ppc)
OP_CFLAGS=$(CFLAGS)
endif
+ifeq ($(GCC_MAJOR),3)
+# very important to generate a return at the end of every operation
+OP_CFLAGS+=-fno-reorder-blocks -fno-optimize-sibling-calls
+endif
+
#########################################################
DEFINES+=-D_GNU_SOURCE