summaryrefslogtreecommitdiff
path: root/cross
diff options
context:
space:
mode:
authortv <tv>1998-08-14 00:12:52 +0000
committertv <tv>1998-08-14 00:12:52 +0000
commit3f63b9cdd0cc52756ca7adeb68c8c086ff93b364 (patch)
treeb54d25784f74a46982b8c12b0a79433dc9333a22 /cross
parent066edd0e3ef60dae2a151bf61399ea2f7e1d931d (diff)
downloadpkgsrc-3f63b9cdd0cc52756ca7adeb68c8c086ff93b364.tar.gz
- Pass LDFLAGS_FOR_TARGET down to the built libraries, needed for
"-rpath-link". - Make sure that SYS_INCLUDE and SYS_LIB dependent stuff is only used if these variables are defined.
Diffstat (limited to 'cross')
-rw-r--r--cross/COMMON/cross.mk17
-rw-r--r--cross/COMMON/patches-egcs-ss/patch-aa12
2 files changed, 23 insertions, 6 deletions
diff --git a/cross/COMMON/cross.mk b/cross/COMMON/cross.mk
index 8c4d22a8491..9b35193fe02 100644
--- a/cross/COMMON/cross.mk
+++ b/cross/COMMON/cross.mk
@@ -1,4 +1,4 @@
-# $NetBSD: cross.mk,v 1.1 1998/08/12 02:42:29 tv Exp $
+# $NetBSD: cross.mk,v 1.2 1998/08/14 00:12:52 tv Exp $
# Shared definitions for building a cross-compile environment.
@@ -27,6 +27,7 @@ CROSS_DISTFILES+= ${BINUTILS_DISTNAME}.tar.gz
MASTER_SITES+= ${MASTER_SITE_GNU}
CONFIGURE_ARGS+= --with-gnu-as --with-gnu-ld
PLIST_PRE+= ${COMMON_DIR}/PLIST-binutils
+#CROSS_PATCHFILES+= ${COMMON_DIR}/patches-binutils/patch-*
USE_CROSS_EGCS= yes
post-extract: post-extract-binutils
@@ -76,11 +77,19 @@ CONFIGURE_ARGS+= --target=${TARGET_ARCH} \
--enable-version-specific-runtime-libs
CONFIGURE_ENV+= CXXFLAGS="${CXXFLAGS}"
USE_GMAKE= yes
-MAKE_FLAGS+= CC_FOR_TARGET="${WRKSRC}/gcc/xgcc -B${WRKSRC}/gcc/ -idirafter ${SYS_INCLUDE} -L${SYS_LIB}" \
+MAKE_FLAGS+= CC_FOR_TARGET="${WRKSRC}/gcc/xgcc -B${WRKSRC}/gcc/ ${CFLAGS_FOR_TARGET}" \
GCC_FOR_TARGET='$${CC_FOR_TARGET}' \
CXX_FOR_TARGET='$${CC_FOR_TARGET}' \
- LANGUAGES="c c++ f77 objc" \
- SYSTEM_HEADER_DIR="${SYS_INCLUDE}"
+ LDFLAGS_FOR_TARGET="${LDFLAGS_FOR_TARGET}" \
+ LANGUAGES="c c++ f77 objc"
+
+.if defined(SYS_INCLUDE)
+CFLAGS_FOR_TARGET+= -idirafter ${SYS_INCLUDE}
+MAKE_FLAGS+= SYSTEM_HEADER_DIR="${SYS_INCLUDE}"
+.endif
+.if defined(SYS_LIB)
+LDFLAGS_FOR_TARGET+= -L${SYS_LIB}
+.endif
post-extract: post-extract-egcs
post-extract-egcs:
diff --git a/cross/COMMON/patches-egcs-ss/patch-aa b/cross/COMMON/patches-egcs-ss/patch-aa
index 2f73356289e..5441504dfe8 100644
--- a/cross/COMMON/patches-egcs-ss/patch-aa
+++ b/cross/COMMON/patches-egcs-ss/patch-aa
@@ -1,7 +1,7 @@
-$NetBSD: patch-aa,v 1.1 1998/08/12 02:42:31 tv Exp $
+$NetBSD: patch-aa,v 1.2 1998/08/14 00:12:53 tv Exp $
--- Makefile.in.orig Sat Jun 27 18:08:28 1998
-+++ Makefile.in Mon Aug 3 18:24:12 1998
++++ Makefile.in Thu Aug 13 17:32:08 1998
@@ -349,6 +349,7 @@
"NM_FOR_TARGET=$(NM_FOR_TARGET)" \
"RANLIB_FOR_TARGET=$(RANLIB_FOR_TARGET)" \
@@ -18,3 +18,11 @@ $NetBSD: patch-aa,v 1.1 1998/08/12 02:42:31 tv Exp $
"prefix=$(prefix)" \
"tooldir=$(tooldir)" \
"gxx_include_dir=$(gxx_include_dir)" \
+@@ -405,6 +407,7 @@
+ 'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
+ 'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
+ 'LD=$$(LD_FOR_TARGET)' \
++ 'LDFLAGS=$$(LDFLAGS_FOR_TARGET)' \
+ 'LIBCFLAGS=$$(LIBCFLAGS_FOR_TARGET)' \
+ 'LIBCXXFLAGS=$$(LIBCXXFLAGS_FOR_TARGET)' \
+ 'NM=$$(NM_FOR_TARGET)' \