summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xbuild8
-rw-r--r--patches/01_pass-some-dirs-to-child-makes.patch14
2 files changed, 13 insertions, 9 deletions
diff --git a/build b/build
index d4e3e05..c56bebe 100755
--- a/build
+++ b/build
@@ -52,6 +52,8 @@ build: configure
>src/$${f}; \
done
oh-autobuild -B gcc-build -T bootstrap-lean -- -j $${JOBS:-1} \
+ libsubdir=/usr/lib/$(OPK_HOST_ARCH)/gcc-$(BASE_VERSION) \
+ libexecsubdir=/usr/lib/$(OPK_HOST_ARCH)/gcc-$(BASE_VERSION) \
toolexeclibdir=/usr/lib/$(OPK_HOST_ARCH) MULTIOSDIR=
touch $@
@@ -66,12 +68,10 @@ install: build
# See also: <http://gcc.gnu.org/ml/gcc/2013-04/msg00171.html>.
# TODO: Replace $(OPK_HOST_ARCH) with the target arch.
oh-autoinstall -B gcc-build -T install -- \
+ libsubdir=/usr/lib/$(OPK_HOST_ARCH)/gcc-$(BASE_VERSION) \
+ libexecsubdir=/usr/lib/$(OPK_HOST_ARCH)/gcc-$(BASE_VERSION) \
toolexeclibdir=/usr/lib/$(OPK_HOST_ARCH) MULTIOSDIR=
rm -f dest/usr/lib/$(OPK_HOST_ARCH)/libiberty.a
- mv dest/usr/lib/$(OPK_HOST_ARCH)/gcc/*/*/ \
- dest/usr/lib/$(OPK_HOST_ARCH)/gcc-$(BASE_VERSION)/
- rmdir dest/usr/lib/$(OPK_HOST_ARCH)/gcc/*/
- rmdir dest/usr/lib/$(OPK_HOST_ARCH)/gcc/
# POSIX.1-2008:
# If the pathname does not begin with a '/' it shall be treated as relative to
diff --git a/patches/01_pass-some-dirs-to-child-makes.patch b/patches/01_pass-some-dirs-to-child-makes.patch
index 4c629fc..3082994 100644
--- a/patches/01_pass-some-dirs-to-child-makes.patch
+++ b/patches/01_pass-some-dirs-to-child-makes.patch
@@ -1,6 +1,6 @@
Description: Pass some dir paths to child makes
- toolexeclibdir is hardcoded in many makefiles, and MULTIOSDIR is hardcoded in
- gcc/Makefile.in. We want to change these values.
+ libsubdir, libexecsubdir, and toolexeclibdir are hardcoded in many makefiles.
+ MULTIOSDIR is hardcoded in gcc/Makefile.in. We want to change these values.
From: "P. J. McDermott" <pjm@nac.net>
diff -Naur src.orig/libmudflap/Makefile.am src/libmudflap/Makefile.am
@@ -93,11 +93,13 @@ diff -Naur src.orig/libstdc++-v3/Makefile.in src/libstdc++-v3/Makefile.in
"LD=$(LD)" \
diff -Naur src.orig/Makefile.def src/Makefile.def
--- src.orig/Makefile.def 2013-04-20 14:46:22.918763972 -0400
-+++ src/Makefile.def 2013-04-20 17:04:58.238791783 -0400
++++ src/Makefile.def 2013-04-21 10:37:16.013678375 -0400
@@ -199,6 +199,8 @@
flags_to_pass = { flag= tooldir ; };
flags_to_pass = { flag= build_tooldir ; };
flags_to_pass = { flag= target_alias ; };
++flags_to_pass = { flag= libsubdir ; };
++flags_to_pass = { flag= libexecsubdir ; };
+flags_to_pass = { flag= toolexeclibdir ; };
+flags_to_pass = { flag= MULTIOSDIR ; };
@@ -105,11 +107,13 @@ diff -Naur src.orig/Makefile.def src/Makefile.def
flags_to_pass = { flag= AWK ; };
diff -Naur src.orig/Makefile.in src/Makefile.in
--- src.orig/Makefile.in 2012-08-06 10:34:27.000000000 -0400
-+++ src/Makefile.in 2013-04-20 17:02:07.889802316 -0400
-@@ -721,6 +721,8 @@
++++ src/Makefile.in 2013-04-21 10:33:31.899390474 -0400
+@@ -721,6 +721,10 @@
"tooldir=$(tooldir)" \
"build_tooldir=$(build_tooldir)" \
"target_alias=$(target_alias)" \
++ "libsubdir=$(libsubdir)" \
++ "libexecsubdir=$(libexecsubdir)" \
+ "toolexeclibdir=$(toolexeclibdir)" \
+ "MULTIOSDIR=$(MULTIOSDIR)" \
"AWK=$(AWK)" \