pkgsrc/devel/gnustep-objc/patches/patch-GNUmakefile
2016-11-16 22:46:48 +00:00

34 lines
1.2 KiB
Text

$NetBSD: patch-GNUmakefile,v 1.1 2016/11/16 22:46:49 wiedi Exp $
- only use -no-integrated-as with clang
- _XOPEN_SOURCE=500 conflicts with c99
--- GNUmakefile.orig 2012-03-21 16:45:31.000000000 +0000
+++ GNUmakefile
@@ -81,7 +81,7 @@ ${LIBOBJC}_OBJ_FILES = \
# Add rule for producing object files from assembler
$(GNUSTEP_OBJ_INSTANCE_DIR)/%.S$(OEXT) : %.S
- $(ECHO_COMPILING)$(CC) -no-integrated-as $< -c \
+ $(ECHO_COMPILING)$(CC) $(ASMFLAGS) $< -c \
$(filter-out $($<_FILE_FILTER_OUT_FLAGS),$(ALL_CPPFLAGS) \
$(ALL_CFLAGS)) \
$($<_FILE_FLAGS) -o $@$(END_ECHO)
@@ -153,7 +153,7 @@ endif
# we are special, precious, little flowers.
${LIBOBJC}_CPPFLAGS +=\
-D__OBJC_RUNTIME_INTERNAL__=1\
- -D_XOPEN_SOURCE=500\
+ -D_XOPEN_SOURCE=600\
-D__BSD_VISIBLE=1\
-D_BSD_SOURCE=1\
@@ -164,6 +164,8 @@ ${LIBOBJC}_CFLAGS += -std=gnu99 -g -fexc
${LIBOBJC}_CCFLAGS += -std=c++98 -g -fexceptions #-fvisibility=hidden
${LIBOBJC}_CFLAGS += -Wno-unused-function
+ASMFLAGS += `if $(CC) -v 2>&1| grep -q 'clang' ; then echo -no-integrated-as ; fi`
+
# Uncomment this when debugging - it makes everything slow, but means that the
# debugger actually works...
ifeq ($(debug), yes)