summaryrefslogtreecommitdiffstats
path: root/gnu
diff options
context:
space:
mode:
Diffstat (limited to 'gnu')
-rw-r--r--gnu/lib/Makefile2
-rw-r--r--gnu/lib/libgcc/Makefile7
-rw-r--r--gnu/usr.bin/cc/cc_tools/freebsd-native.h10
3 files changed, 9 insertions, 10 deletions
diff --git a/gnu/lib/Makefile b/gnu/lib/Makefile
index 7be57b1..41f3236 100644
--- a/gnu/lib/Makefile
+++ b/gnu/lib/Makefile
@@ -2,9 +2,11 @@
SUBDIR= csu libdialog libgcc libgmp libmp libregex libreadline
+.if ${OBJFORMAT} == aout
.if !defined(NOLIBC_R)
SUBDIR+= libgcc_r
.endif
+.endif
.if !defined(NO_CXX)
SUBDIR+= libstdc++
diff --git a/gnu/lib/libgcc/Makefile b/gnu/lib/libgcc/Makefile
index a9842a0..a16558a 100644
--- a/gnu/lib/libgcc/Makefile
+++ b/gnu/lib/libgcc/Makefile
@@ -4,12 +4,15 @@ GCCDIR= ${.CURDIR}/../../../contrib/gcc.295
.PATH: ${GCCDIR}/cp ${GCCDIR}
+# allow to be overridden for the a.out case
.if !defined(LIB) || ${LIB} != "gcc_r"
LIB= gcc
.endif
+.if ${OBJFORMAT} == aout
# Install libgcc_pic.a, since ld.so uses it.
INSTALL_PIC_ARCHIVE= yes
+.endif
#
# XXX This is a hack, but it seems to work. libgcc1.a is supposed to be
@@ -59,6 +62,10 @@ SRCS= frame.c tinfo.cc tinfo2.cc new.cc exception.cc
CFLAGS+= -I${GCCDIR}/config -I${GCCDIR} -I.
CFLAGS+= -fexceptions
CFLAGS+= -DIN_GCC
+.if ${OBJFORMAT} != aout
+#CFLAGS+= -D_PTHREADS -fPIC -DGTHREAD_USE_WEAK
+CFLAGS+= -D_PTHREADS -DGTHREAD_USE_WEAK
+.endif
CXXFLAGS+= -I${GCCDIR}/cp/inc
CXXFLAGS+= -nostdinc++
diff --git a/gnu/usr.bin/cc/cc_tools/freebsd-native.h b/gnu/usr.bin/cc/cc_tools/freebsd-native.h
index 6fd158c..fd04a68 100644
--- a/gnu/usr.bin/cc/cc_tools/freebsd-native.h
+++ b/gnu/usr.bin/cc/cc_tools/freebsd-native.h
@@ -46,13 +46,3 @@
/* FreeBSD is 4.4BSD derived */
#define bsd4_4
-
-/* Tell gcc to locate libgcc.a for us according to the -m rules. */
-#undef LIBGCC_SPEC
-#define LIBGCC_SPEC \
- "%{!shared: \
- %{!pthread:libgcc.a%s} \
- %{pthread:libgcc_r.a%s}} \
- %{shared: \
- %{!pthread:libgcc_pic.a%s} \
- %{pthread:libgcc_r_pic.a%s}}"
OpenPOWER on IntegriCloud