aboutsummaryrefslogtreecommitdiff
path: root/unix/Makefile
diff options
context:
space:
mode:
authorAntonin ENFRUN2014-05-11 21:28:26 +0200
committerAntonin ENFRUN2014-05-12 00:13:10 +0200
commit6caae0bcb183fabd2bcf65c2ae2346b4e2d5cbe7 (patch)
tree03308bc86f381203cbed3e0611e801bd10250bcc /unix/Makefile
parent147c80bf7cad0f8e02f3b7ccf8ec14e65092e52b (diff)
unix: Create __bss_start and _end symbols for Mach-O targets.
It's a hack, but can't find a cleaner way to do it.
Diffstat (limited to 'unix/Makefile')
-rw-r--r--unix/Makefile9
1 files changed, 7 insertions, 2 deletions
diff --git a/unix/Makefile b/unix/Makefile
index 05cdfb5b3..ba2180fe5 100644
--- a/unix/Makefile
+++ b/unix/Makefile
@@ -19,8 +19,8 @@ CFLAGS = $(INC) -Wall -Werror -ansi -std=gnu99 -DUNIX $(CFLAGS_MOD) $(COPT)
UNAME_S := $(shell uname -s)
ifeq ($(UNAME_S),Darwin)
- LDFLAGS = $(LDFLAGS_MOD) -lm -Wl,-map,$@.map
-else
+ LDFLAGS = $(LDFLAGS_MOD) -lm -Wl,-map,$@.map,-order_file,order.def
+ else
LDFLAGS = $(LDFLAGS_MOD) -lm -Wl,-Map=$@.map,--cref
endif
@@ -70,6 +70,11 @@ SRC_C = \
modsocket.c \
$(SRC_MOD)
+# Must be the last file
+ifeq ($(UNAME_S),Darwin)
+SRC_C += seg_helpers.c
+endif
+
OBJ = $(PY_O) $(addprefix $(BUILD)/, $(SRC_C:.c=.o))
include ../py/mkrules.mk