From 2d5de4978845ef847cc21c75cfd6ddda2e843ef6 Mon Sep 17 00:00:00 2001
From: P. J. McDermott <pjm@nac.net>
Date: Sun, 21 Apr 2013 17:25:29 -0400
Subject: Set gxx_include_dir and host_installdir.

---
diff --git a/build b/build
index 295a416..64106ef 100755
--- a/build
+++ b/build
@@ -70,6 +70,8 @@ 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 -- \
+		gxx_include_dir=/usr/include/c++-4.7 \
+		host_installdir=/usr/include/$(OPK_HOST_ARCH)/c++-4.7/bits \
 		libsubdir=/usr/lib/$(OPK_HOST_ARCH)/gcc-$(BASE_VERSION) \
 		libexecsubdir=/usr/lib/$(OPK_HOST_ARCH)/gcc-$(BASE_VERSION) \
 		libsubincludedir=/usr/lib/$(OPK_HOST_ARCH)/gcc-$(BASE_VERSION) \
diff --git a/patches/01_pass-some-dirs-to-child-makes.patch b/patches/01_pass-some-dirs-to-child-makes.patch
index 533ef85..8b81b5f 100644
--- a/patches/01_pass-some-dirs-to-child-makes.patch
+++ b/patches/01_pass-some-dirs-to-child-makes.patch
@@ -79,10 +79,11 @@ diff -Naur src.orig/libssp/Makefile.in src/libssp/Makefile.in
 diff -Naur src.orig/libstdc++-v3/Makefile.am src/libstdc++-v3/Makefile.am
 --- src.orig/libstdc++-v3/Makefile.am	2012-01-23 18:12:01.000000000 -0500
 +++ src/libstdc++-v3/Makefile.am	2013-04-20 15:35:56.177410624 -0400
-@@ -163,6 +163,7 @@
+@@ -163,6 +163,8 @@
  	"prefix=$(prefix)" \
  	"tooldir=$(tooldir)" \
  	"gxx_include_dir=$(gxx_include_dir)" \
++	"host_installdir=$(host_installdir)" \
 +	"toolexeclibdir=$(toolexeclibdir)" \
  	"AR=$(AR)" \
  	"AS=$(AS)" \
@@ -90,10 +91,11 @@ diff -Naur src.orig/libstdc++-v3/Makefile.am src/libstdc++-v3/Makefile.am
 diff -Naur src.orig/libstdc++-v3/Makefile.in src/libstdc++-v3/Makefile.in
 --- src.orig/libstdc++-v3/Makefile.in	2012-02-17 15:26:32.000000000 -0500
 +++ src/libstdc++-v3/Makefile.in	2013-04-20 15:36:11.077844405 -0400
-@@ -362,6 +362,7 @@
+@@ -362,6 +362,8 @@
  	"prefix=$(prefix)" \
  	"tooldir=$(tooldir)" \
  	"gxx_include_dir=$(gxx_include_dir)" \
++	"host_installdir=$(host_installdir)" \
 +	"toolexeclibdir=$(toolexeclibdir)" \
  	"AR=$(AR)" \
  	"AS=$(AS)" \
@@ -101,12 +103,14 @@ diff -Naur src.orig/libstdc++-v3/Makefile.in src/libstdc++-v3/Makefile.in
 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-21 10:37:16.013678375 -0400
-@@ -199,6 +199,12 @@
+@@ -199,6 +199,14 @@
  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= gxx_include_dir ; };
++flags_to_pass = { flag= host_installdir ; };
 +flags_to_pass = { flag= libsubincludedir ; };
 +flags_to_pass = { flag= fincludedir ; };
 +flags_to_pass = { flag= toolexeclibdir ; };
@@ -117,12 +121,14 @@ diff -Naur src.orig/Makefile.def src/Makefile.def
 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-21 10:33:31.899390474 -0400
-@@ -721,6 +721,12 @@
+@@ -721,6 +721,14 @@
  	"tooldir=$(tooldir)" \
  	"build_tooldir=$(build_tooldir)" \
  	"target_alias=$(target_alias)" \
 +	"libsubdir=$(libsubdir)" \
 +	"libexecsubdir=$(libexecsubdir)" \
++	"gxx_include_dir=$(gxx_include_dir)" \
++	"host_installdir=$(host_installdir)" \
 +	"libsubincludedir=$(libsubincludedir)" \
 +	"fincludedir=$(fincludedir)" \
 +	"toolexeclibdir=$(toolexeclibdir)" \
--
cgit v0.9.1