+2001-02-05 Benjamin Kosnik <bkoz@redhat.com>
+
+ * acinclude.m4 (GLIBCPP_EXPORT_INSTALL_INFO): New
+ macro. Consolidate all the bits to do with where includes might be
+ installed.
+ * aclocal.m4: Regenerate.
+ * configure.in: Use it.
+ * configure: Regenerate.
+ * src/Makefile.am (targetincludep): Use simplified rules.
+ (targetincludep): Rename gxx_target_include_dir.
+ (myincludep): Rename gxx_include_dir.
+ * src/Makefile.in: Regenerate.
+ * libsupc++/Makefile.am: Use simplified rules.
+ * libsupc++/Makefile.in: Regenerate.
+
2001-02-05 Benjamin Kosnik <bkoz@redhat.com>
* include/c_std/bits/std_cerrno.h: Correct date format for copyright.
gcc_version = @gcc_version@
glibcpp_basedir = @glibcpp_basedir@
gxx_include_dir = @gxx_include_dir@
-gxx_target_include_dir = @gxx_target_include_dir@
ifGNUmake = @ifGNUmake@
libinst_wstring_la = @libinst_wstring_la@
libio_la = @libio_la@
-libstdcxx_interface = @libstdcxx_interface@
toplevel_srcdir = @toplevel_srcdir@
AUTOMAKE_OPTIONS = 1.3 cygnus
])
+dnl GLIBCPP_EXPORT_INSTALL_INFO
+dnl calculates gxx_install_dir
+dnl
+AC_DEFUN(GLIBCPP_EXPORT_INSTALL_INFO, [
+
+AC_MSG_CHECKING([for interface version number])
+libstdcxx_interface=$INTERFACE
+AC_MSG_RESULT($libstdcxx_interface)
+
+# Process the option --with-gxx-include-dir=<path to include-files directory>
+AC_MSG_CHECKING([for --with-gxx-include-dir])
+AC_ARG_WITH(gxx-include-dir,
+[ --with-gxx-include-dir the installation directory for include files],
+[case "${withval}" in
+ yes)
+ AC_MSG_ERROR(Missing directory for --with-gxx-include-dir)
+ gxx_include_dir=no
+ ;;
+ no)
+ gxx_include_dir=no
+ ;;
+ *)
+ gxx_include_dir=${withval}
+ ;;
+esac], [gxx_include_dir=no])
+AC_MSG_RESULT($gxx_include_dir)
+
+# Process the option "--enable-version-specific-runtime-libs"
+AC_MSG_CHECKING([for --enable-version-specific-runtime-libs])
+AC_ARG_ENABLE(version-specific-runtime-libs,
+[ --enable-version-specific-runtime-libs Specify that runtime libraries should be installed in a compiler-specific directory ],
+[ version_specific_libs=yes
+# Need the gcc compiler version to know where to install libraries
+# and header files if --enable-version-specific-runtime-libs option
+# is selected.
+changequote(,)dnl
+gcc_tmp=`grep version_string ${srcdir}/../gcc/version.c | awk '{print $6}'`
+gcc_num=`echo ${gcc_tmp} | sed 's/\"//g'`
+#gcc_date=`grep version_string ${srcdir}/../gcc/version.c | awk '{print $7}'`
+#gcc_version=$gcc_num-$gcc_date
+gcc_version=$gcc_num
+gxx_include_dir=$(libdir)/gcc-lib/$(target_alias)/$(gcc_version)/include/g++
+changequote([,])dnl
+AC_SUBST(gcc_version)
+AM_CONDITIONAL(VERSION_SPECIFIC_LIBS, test x"$version_specific_libs" = x"yes")
+],version_specific_libs=no)
+AC_MSG_RESULT($version_specific_libs)
+
+AC_MSG_CHECKING([for install location])
+if test x"$version_specific_libs" = x"no" \
+ && test x"$gxx_include_dir"=x"no"; then
+ gxx_include_dir=${prefix}/include/g++-${libstdcxx_interface}
+fi
+AC_MSG_RESULT($gxx_include_dir)
+AC_SUBST(gxx_include_dir)
+])
+
+
# Check whether LC_MESSAGES is available in <locale.h>.
# Ulrich Drepper <drepper@cygnus.com>, 1995.
#
])
+dnl GLIBCPP_EXPORT_INSTALL_INFO
+dnl calculates gxx_install_dir
+dnl
+AC_DEFUN(GLIBCPP_EXPORT_INSTALL_INFO, [
+
+AC_MSG_CHECKING([for interface version number])
+libstdcxx_interface=$INTERFACE
+AC_MSG_RESULT($libstdcxx_interface)
+
+# Process the option --with-gxx-include-dir=<path to include-files directory>
+AC_MSG_CHECKING([for --with-gxx-include-dir])
+AC_ARG_WITH(gxx-include-dir,
+[ --with-gxx-include-dir the installation directory for include files],
+[case "${withval}" in
+ yes)
+ AC_MSG_ERROR(Missing directory for --with-gxx-include-dir)
+ gxx_include_dir=no
+ ;;
+ no)
+ gxx_include_dir=no
+ ;;
+ *)
+ gxx_include_dir=${withval}
+ ;;
+esac], [gxx_include_dir=no])
+AC_MSG_RESULT($gxx_include_dir)
+
+# Process the option "--enable-version-specific-runtime-libs"
+AC_MSG_CHECKING([for --enable-version-specific-runtime-libs])
+AC_ARG_ENABLE(version-specific-runtime-libs,
+[ --enable-version-specific-runtime-libs Specify that runtime libraries should be installed in a compiler-specific directory ],
+[ version_specific_libs=yes
+# Need the gcc compiler version to know where to install libraries
+# and header files if --enable-version-specific-runtime-libs option
+# is selected.
+changequote(,)dnl
+gcc_tmp=`grep version_string ${srcdir}/../gcc/version.c | awk '{print $6}'`
+gcc_num=`echo ${gcc_tmp} | sed 's/\"//g'`
+#gcc_date=`grep version_string ${srcdir}/../gcc/version.c | awk '{print $7}'`
+#gcc_version=$gcc_num-$gcc_date
+gcc_version=$gcc_num
+gxx_include_dir=$(libdir)/gcc-lib/$(target_alias)/$(gcc_version)/include/g++
+changequote([,])dnl
+AC_SUBST(gcc_version)
+AM_CONDITIONAL(VERSION_SPECIFIC_LIBS, test x"$version_specific_libs" = x"yes")
+],version_specific_libs=no)
+AC_MSG_RESULT($version_specific_libs)
+
+AC_MSG_CHECKING([for install location])
+if test x"$version_specific_libs" = x"no" \
+ && test x"$gxx_include_dir"=x"no"; then
+ gxx_include_dir=${prefix}/include/g++-${libstdcxx_interface}
+fi
+AC_MSG_RESULT($gxx_include_dir)
+AC_SUBST(gxx_include_dir)
+])
+
+
# Check whether LC_MESSAGES is available in <locale.h>.
# Ulrich Drepper <drepper@cygnus.com>, 1995.
#
# Generate the various Makefiles, include files, and scripts.
-# This helps subvert libstdcxx_interface, as calculated by devo/config.if
# Needed so that g++ can find the correct include subdir automatically.
INTERFACE=v3
-# Check for the interface version number for specifying where header
-# files are installed, if a version number is provided.
+# Export all the install information
+
+
echo $ac_n "checking for interface version number""... $ac_c" 1>&6
echo "configure:15614: checking for interface version number" >&5
libstdcxx_interface=$INTERFACE
echo "$ac_t""$libstdcxx_interface" 1>&6
-
# Process the option --with-gxx-include-dir=<path to include-files directory>
echo $ac_n "checking for --with-gxx-include-dir""... $ac_c" 1>&6
-echo "configure:15621: checking for --with-gxx-include-dir" >&5
+echo "configure:15620: checking for --with-gxx-include-dir" >&5
# Check whether --with-gxx-include-dir or --without-gxx-include-dir was given.
if test "${with_gxx_include_dir+set}" = set; then
withval="$with_gxx_include_dir"
echo "$ac_t""$gxx_include_dir" 1>&6
-
-
-if test x${gxx_include_dir} != xno; then
- GXX_INCLUDE_DIR_TRUE=
- GXX_INCLUDE_DIR_FALSE='#'
-else
- GXX_INCLUDE_DIR_TRUE='#'
- GXX_INCLUDE_DIR_FALSE=
-fi
-
# Process the option "--enable-version-specific-runtime-libs"
echo $ac_n "checking for --enable-version-specific-runtime-libs""... $ac_c" 1>&6
-echo "configure:15655: checking for --enable-version-specific-runtime-libs" >&5
+echo "configure:15644: checking for --enable-version-specific-runtime-libs" >&5
# Check whether --enable-version-specific-runtime-libs or --disable-version-specific-runtime-libs was given.
if test "${enable_version_specific_runtime_libs+set}" = set; then
enableval="$enable_version_specific_runtime_libs"
# Need the gcc compiler version to know where to install libraries
# and header files if --enable-version-specific-runtime-libs option
# is selected.
-gcc_tmp=`grep version_string ${srcdir}/../gcc/version.c | awk '{print $6}'`
+gcc_tmp=`grep version_string ${srcdir}/../gcc/version.c | awk '{print }'`
gcc_num=`echo ${gcc_tmp} | sed 's/\"//g'`
-#gcc_date=`grep version_string ${srcdir}/../gcc/version.c | awk '{print $7}'`
+#gcc_date=`grep version_string ${srcdir}/../gcc/version.c | awk '{print }'`
#gcc_version=$gcc_num-$gcc_date
gcc_version=$gcc_num
+gxx_include_dir=$(libdir)/gcc-lib/$(target_alias)/$(gcc_version)/include/g++
-else
- version_specific_libs=no
-fi
-echo "$ac_t""$version_specific_libs" 1>&6
-if test x${version_specific_libs} = xyes; then
-
-
-if test x${version_specific_libs} = xyes; then
+if test x"$version_specific_libs" = x"yes"; then
VERSION_SPECIFIC_LIBS_TRUE=
VERSION_SPECIFIC_LIBS_FALSE='#'
else
VERSION_SPECIFIC_LIBS_TRUE='#'
VERSION_SPECIFIC_LIBS_FALSE=
fi
- echo "configure: warning: version specific directory is: $gcc_version" 1>&2
+
+else
+ version_specific_libs=no
fi
-# We have to install all the generated or linked includes files
-# specified as build_headers in src/Makefile.am in a target-dependent
-# place, or else multiple installs for different compilers will
-# overwrite these files.
-# NB: Keep this and gcc/Makefile.in's -DGPLUSPLUS_TOOL_INCLUDE_DIR in sync.
-gxx_target_include_dir='$(exec_prefix)/$(target_alias)/include/g++-$(libstdcxx_interface)'
+echo "$ac_t""$version_specific_libs" 1>&6
+
+echo $ac_n "checking for install location""... $ac_c" 1>&6
+echo "configure:15676: checking for install location" >&5
+if test x"$version_specific_libs" = x"no" \
+ && test x"$gxx_include_dir"=x"no"; then
+ gxx_include_dir=${prefix}/include/g++-${libstdcxx_interface}
+fi
+echo "$ac_t""$gxx_include_dir" 1>&6
s%@USE_LIBDIR_FALSE@%$USE_LIBDIR_FALSE%g
s%@CANADIAN_TRUE@%$CANADIAN_TRUE%g
s%@CANADIAN_FALSE@%$CANADIAN_FALSE%g
-s%@libstdcxx_interface@%$libstdcxx_interface%g
-s%@gxx_include_dir@%$gxx_include_dir%g
-s%@GXX_INCLUDE_DIR_TRUE@%$GXX_INCLUDE_DIR_TRUE%g
-s%@GXX_INCLUDE_DIR_FALSE@%$GXX_INCLUDE_DIR_FALSE%g
s%@gcc_version@%$gcc_version%g
s%@VERSION_SPECIFIC_LIBS_TRUE@%$VERSION_SPECIFIC_LIBS_TRUE%g
s%@VERSION_SPECIFIC_LIBS_FALSE@%$VERSION_SPECIFIC_LIBS_FALSE%g
-s%@gxx_target_include_dir@%$gxx_target_include_dir%g
+s%@gxx_include_dir@%$gxx_include_dir%g
s%@GLIBCPP_INCLUDE_DIR@%$GLIBCPP_INCLUDE_DIR%g
s%@TOPLEVEL_INCLUDES@%$TOPLEVEL_INCLUDES%g
s%@LIBMATH_INCLUDES@%$LIBMATH_INCLUDES%g
# Generate the various Makefiles, include files, and scripts.
-# This helps subvert libstdcxx_interface, as calculated by devo/config.if
# Needed so that g++ can find the correct include subdir automatically.
INTERFACE=v3
-# Check for the interface version number for specifying where header
-# files are installed, if a version number is provided.
-AC_MSG_CHECKING([for interface version number])
-libstdcxx_interface=$INTERFACE
-AC_MSG_RESULT($libstdcxx_interface)
-AC_SUBST(libstdcxx_interface)
-
-# Process the option --with-gxx-include-dir=<path to include-files directory>
-AC_MSG_CHECKING([for --with-gxx-include-dir])
-AC_ARG_WITH(gxx-include-dir,
-[ --with-gxx-include-dir the installation directory for include files],
-[case "${withval}" in
- yes)
- AC_MSG_ERROR(Missing directory for --with-gxx-include-dir)
- gxx_include_dir=no
- ;;
- no)
- gxx_include_dir=no
- ;;
- *)
- gxx_include_dir=${withval}
- ;;
-esac], [gxx_include_dir=no])
-AC_MSG_RESULT($gxx_include_dir)
-AC_SUBST(gxx_include_dir)
-AM_CONDITIONAL(GXX_INCLUDE_DIR, test x${gxx_include_dir} != xno)
-
-# Process the option "--enable-version-specific-runtime-libs"
-AC_MSG_CHECKING([for --enable-version-specific-runtime-libs])
-AC_ARG_ENABLE(version-specific-runtime-libs,
-[ --enable-version-specific-runtime-libs Specify that runtime libraries should be installed in a compiler-specific directory ],
-[ version_specific_libs=yes
-# Need the gcc compiler version to know where to install libraries
-# and header files if --enable-version-specific-runtime-libs option
-# is selected.
-changequote(,)dnl
-gcc_tmp=`grep version_string ${srcdir}/../gcc/version.c | awk '{print $6}'`
-gcc_num=`echo ${gcc_tmp} | sed 's/\"//g'`
-#gcc_date=`grep version_string ${srcdir}/../gcc/version.c | awk '{print $7}'`
-#gcc_version=$gcc_num-$gcc_date
-gcc_version=$gcc_num
-changequote([,])dnl
-AC_SUBST(gcc_version)
-],version_specific_libs=no)
-AC_MSG_RESULT($version_specific_libs)
-if test x${version_specific_libs} = xyes; then
- AM_CONDITIONAL(VERSION_SPECIFIC_LIBS, test x${version_specific_libs} = xyes)
- AC_MSG_WARN(version specific directory is: $gcc_version)
-fi
-
-# We have to install all the generated or linked includes files
-# specified as build_headers in src/Makefile.am in a target-dependent
-# place, or else multiple installs for different compilers will
-# overwrite these files.
-# NB: Keep this and gcc/Makefile.in's -DGPLUSPLUS_TOOL_INCLUDE_DIR in sync.
-gxx_target_include_dir='$(exec_prefix)/$(target_alias)/include/g++-$(libstdcxx_interface)'
-AC_SUBST(gxx_target_include_dir)
-
+# Export all the install information
+GLIBCPP_EXPORT_INSTALL_INFO
# Export all the include and flag information to makefiles.
GLIBCPP_EXPORT_INCLUDES
gcc_version = @gcc_version@
glibcpp_basedir = @glibcpp_basedir@
gxx_include_dir = @gxx_include_dir@
-gxx_target_include_dir = @gxx_target_include_dir@
ifGNUmake = @ifGNUmake@
libinst_wstring_la = @libinst_wstring_la@
libio_la = @libio_la@
-libstdcxx_interface = @libstdcxx_interface@
toplevel_srcdir = @toplevel_srcdir@
AUTOMAKE_OPTIONS = 1.3 cygnus
gcc_version = @gcc_version@
glibcpp_basedir = @glibcpp_basedir@
gxx_include_dir = @gxx_include_dir@
-gxx_target_include_dir = @gxx_target_include_dir@
ifGNUmake = @ifGNUmake@
libinst_wstring_la = @libinst_wstring_la@
libio_la = @libio_la@
-libstdcxx_interface = @libstdcxx_interface@
toplevel_srcdir = @toplevel_srcdir@
AUTOMAKE_OPTIONS = 1.3 cygnus
libsupc___la_SOURCES = $(sources)
libsupc__convenience_la_SOURCES = $(sources)
-# Check for various configure bits that change where the headers get installed.
-if GXX_INCLUDE_DIR
glibcppinstalldir = @gxx_include_dir@
-else
-if VERSION_SPECIFIC_LIBS
-glibcppinstalldir = $(libdir)/gcc-lib/$(target_alias)/@gcc_version@/include/g++
-else
-glibcppinstalldir = $(prefix)/include/g++-@libstdcxx_interface@
-endif
-endif
-
glibcppinstall_HEADERS = $(headers)
# Flags to force separate libtool library to be static only.
enable_static = @enable_static@
glibcpp_basedir = @glibcpp_basedir@
gxx_include_dir = @gxx_include_dir@
-gxx_target_include_dir = @gxx_target_include_dir@
ifGNUmake = @ifGNUmake@
libinst_wstring_la = @libinst_wstring_la@
libio_la = @libio_la@
-libstdcxx_interface = @libstdcxx_interface@
toplevel_srcdir = @toplevel_srcdir@
AUTOMAKE_OPTIONS = 1.3 cygnus
libsupc___la_SOURCES = $(sources)
libsupc__convenience_la_SOURCES = $(sources)
-@GXX_INCLUDE_DIR_TRUE@glibcppinstalldir = @gxx_include_dir@
-@GXX_INCLUDE_DIR_FALSE@@VERSION_SPECIFIC_LIBS_TRUE@glibcppinstalldir = $(libdir)/gcc-lib/$(target_alias)/@gcc_version@/include/g++
-@GXX_INCLUDE_DIR_FALSE@@VERSION_SPECIFIC_LIBS_FALSE@glibcppinstalldir = $(prefix)/include/g++-@libstdcxx_interface@
+glibcppinstalldir = @gxx_include_dir@
glibcppinstall_HEADERS = $(headers)
# Flags to force separate libtool library to be static only.
## Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307,
## USA.
-## $Id: Makefile.am,v 1.66 2001/01/30 09:18:51 bkoz Exp $
+## $Id: Makefile.am,v 1.67 2001/02/03 09:01:44 bkoz Exp $
AUTOMAKE_OPTIONS = 1.3 gnits
MAINT_CHARSET = latin1
# Check for various configure bits that change where the headers get installed.
-if GXX_INCLUDE_DIR
-myincludep = @gxx_include_dir@
-targetincludep = @gxx_include_dir@
-else
-if VERSION_SPECIFIC_LIBS
-myincludep = $(libdir)/gcc-lib/$(target_alias)/@gcc_version@/include/g++
-targetincludep = $(libdir)/gcc-lib/$(target_alias)/@gcc_version@/include/g++
-else
-myincludep = $(prefix)/include/g++-@libstdcxx_interface@
-targetincludep = @gxx_target_include_dir@
-endif
-endif
+gxx_include_dir = @gxx_include_dir@
+gxx_target_include_dir = $(gxx_include_dir)/$(target_alias)
# We have our own special, ridiculously complicated installation routine
# here, as automake/autoconf is currently brain-damaged when it comes
# NB: installation of shadow header directories is not attempted.
myinstalldirs:
if test -z "$(MULTISUBDIR)"; then \
- $(mkinstalldirs) $(DESTDIR)$(myincludep)/bits; \
- $(mkinstalldirs) $(DESTDIR)$(myincludep)/ext; \
- $(mkinstalldirs) $(DESTDIR)$(targetincludep)/bits; \
+ $(mkinstalldirs) $(DESTDIR)$(gxx_include_dir)/bits; \
+ $(mkinstalldirs) $(DESTDIR)$(gxx_include_dir)/ext; \
+ $(mkinstalldirs) $(DESTDIR)$(gxx_target_include_dir)/bits; \
fi
# NB: As libio_headers may be empty, need this to make sure bash doesn't
myinstallheaders:
if test -z "$(MULTISUBDIR)"; then \
for i in $(base_headers); do \
- echo "$(INSTALL_DATA) $(src_incdir)/$$i $(myincludep)/bits/"; \
- $(INSTALL_DATA) $(src_incdir)/$$i $(myincludep)/bits/; \
+ echo "$(INSTALL_DATA) $(src_incdir)/$$i $(gxx_include_dir)/bits/"; \
+ $(INSTALL_DATA) $(src_incdir)/$$i $(gxx_include_dir)/bits/; \
done; \
for i in $(ext_headers); do \
- echo "$(INSTALL_DATA) $(src_incdir)/$$i $(myincludep)/ext/"; \
- $(INSTALL_DATA) $(src_incdir)/$$i $(myincludep)/ext/; \
+ echo "$(INSTALL_DATA) $(src_incdir)/$$i $(gxx_include_dir)/ext/"; \
+ $(INSTALL_DATA) $(src_incdir)/$$i $(gxx_include_dir)/ext/; \
done; \
for i in $(backward_headers); do \
- echo "$(INSTALL_DATA) $(src_incdir)/$$i $(myincludep)"; \
- $(INSTALL_DATA) $(src_incdir)/$$i $(myincludep); \
+ echo "$(INSTALL_DATA) $(src_incdir)/$$i $(gxx_include_dir)"; \
+ $(INSTALL_DATA) $(src_incdir)/$$i $(gxx_include_dir); \
done; \
for i in $(c_base_headers); do \
- echo "$(INSTALL_DATA) $(c_incdir)/$$i $(myincludep)/bits/"; \
- $(INSTALL_DATA) $(c_incdir)/$$i $(myincludep)/bits/; \
+ echo "$(INSTALL_DATA) $(c_incdir)/$$i $(gxx_include_dir)/bits/"; \
+ $(INSTALL_DATA) $(c_incdir)/$$i $(gxx_include_dir)/bits/; \
done; \
for i in $(std_headers); do \
- echo "$(INSTALL_DATA) $(src_incdir)/std/$$i $(myincludep)";\
- $(INSTALL_DATA) $(src_incdir)/std/$$i $(myincludep); \
+ echo "$(INSTALL_DATA) $(src_incdir)/std/$$i $(gxx_include_dir)";\
+ $(INSTALL_DATA) $(src_incdir)/std/$$i $(gxx_include_dir); \
done; \
for i in $(build_headers); do \
- echo "$(INSTALL_DATA) $(bld_incdir)/$$i $(targetincludep)/bits/"; \
- $(INSTALL_DATA) $(bld_incdir)/$$i $(targetincludep)/bits/; \
+ echo "$(INSTALL_DATA) $(bld_incdir)/$$i $(gxx_target_include_dir)/bits/"; \
+ $(INSTALL_DATA) $(bld_incdir)/$$i $(gxx_target_include_dir)/bits/; \
done; \
libio_headers_install='$(libio_headers)'; \
for i in $$libio_headers_install; do \
- echo "$(INSTALL_DATA) $$i $(myincludep)"; \
- $(INSTALL_DATA) $$i $(myincludep); \
+ echo "$(INSTALL_DATA) $$i $(gxx_include_dir)"; \
+ $(INSTALL_DATA) $$i $(gxx_include_dir); \
done; \
fi;
enable_shared = @enable_shared@
enable_static = @enable_static@
glibcpp_basedir = @glibcpp_basedir@
-gxx_include_dir = @gxx_include_dir@
-gxx_target_include_dir = @gxx_target_include_dir@
ifGNUmake = @ifGNUmake@
libinst_wstring_la = @libinst_wstring_la@
libio_la = @libio_la@
-libstdcxx_interface = @libstdcxx_interface@
toplevel_srcdir = @toplevel_srcdir@
AUTOMAKE_OPTIONS = 1.3 gnits
libstdc___la_DEPENDENCIES = $(libstdc___la_LIBADD)
@GLIBCPP_USE_CSHADOW_TRUE@CSHADOW_H = $(top_builddir)/stamp-cshadow
@GLIBCPP_USE_CSHADOW_FALSE@CSHADOW_H =
-@GXX_INCLUDE_DIR_TRUE@myincludep = @gxx_include_dir@
-@GXX_INCLUDE_DIR_FALSE@@VERSION_SPECIFIC_LIBS_TRUE@myincludep = $(libdir)/gcc-lib/$(target_alias)/@gcc_version@/include/g++
-@GXX_INCLUDE_DIR_FALSE@@VERSION_SPECIFIC_LIBS_FALSE@myincludep = $(prefix)/include/g++-@libstdcxx_interface@
-@GXX_INCLUDE_DIR_TRUE@targetincludep = @gxx_include_dir@
-@GXX_INCLUDE_DIR_FALSE@@VERSION_SPECIFIC_LIBS_TRUE@targetincludep = $(libdir)/gcc-lib/$(target_alias)/@gcc_version@/include/g++
-@GXX_INCLUDE_DIR_FALSE@@VERSION_SPECIFIC_LIBS_FALSE@targetincludep = @gxx_target_include_dir@
+
+# Check for various configure bits that change where the headers get installed.
+gxx_include_dir = @gxx_include_dir@
+gxx_target_include_dir = $(gxx_include_dir)/$(target_alias)
# NB: As libio_headers may be empty, need this to make sure bash doesn't
# choke on an empty for... loop by using libio_headers_install
# NB: installation of shadow header directories is not attempted.
myinstalldirs:
if test -z "$(MULTISUBDIR)"; then \
- $(mkinstalldirs) $(DESTDIR)$(myincludep)/bits; \
- $(mkinstalldirs) $(DESTDIR)$(myincludep)/ext; \
- $(mkinstalldirs) $(DESTDIR)$(targetincludep)/bits; \
+ $(mkinstalldirs) $(DESTDIR)$(gxx_include_dir)/bits; \
+ $(mkinstalldirs) $(DESTDIR)$(gxx_include_dir)/ext; \
+ $(mkinstalldirs) $(DESTDIR)$(gxx_target_include_dir)/bits; \
fi
myinstallheaders:
if test -z "$(MULTISUBDIR)"; then \
for i in $(base_headers); do \
- echo "$(INSTALL_DATA) $(src_incdir)/$$i $(myincludep)/bits/"; \
- $(INSTALL_DATA) $(src_incdir)/$$i $(myincludep)/bits/; \
+ echo "$(INSTALL_DATA) $(src_incdir)/$$i $(gxx_include_dir)/bits/"; \
+ $(INSTALL_DATA) $(src_incdir)/$$i $(gxx_include_dir)/bits/; \
done; \
for i in $(ext_headers); do \
- echo "$(INSTALL_DATA) $(src_incdir)/$$i $(myincludep)/ext/"; \
- $(INSTALL_DATA) $(src_incdir)/$$i $(myincludep)/ext/; \
+ echo "$(INSTALL_DATA) $(src_incdir)/$$i $(gxx_include_dir)/ext/"; \
+ $(INSTALL_DATA) $(src_incdir)/$$i $(gxx_include_dir)/ext/; \
done; \
for i in $(backward_headers); do \
- echo "$(INSTALL_DATA) $(src_incdir)/$$i $(myincludep)"; \
- $(INSTALL_DATA) $(src_incdir)/$$i $(myincludep); \
+ echo "$(INSTALL_DATA) $(src_incdir)/$$i $(gxx_include_dir)"; \
+ $(INSTALL_DATA) $(src_incdir)/$$i $(gxx_include_dir); \
done; \
for i in $(c_base_headers); do \
- echo "$(INSTALL_DATA) $(c_incdir)/$$i $(myincludep)/bits/"; \
- $(INSTALL_DATA) $(c_incdir)/$$i $(myincludep)/bits/; \
+ echo "$(INSTALL_DATA) $(c_incdir)/$$i $(gxx_include_dir)/bits/"; \
+ $(INSTALL_DATA) $(c_incdir)/$$i $(gxx_include_dir)/bits/; \
done; \
for i in $(std_headers); do \
- echo "$(INSTALL_DATA) $(src_incdir)/std/$$i $(myincludep)";\
- $(INSTALL_DATA) $(src_incdir)/std/$$i $(myincludep); \
+ echo "$(INSTALL_DATA) $(src_incdir)/std/$$i $(gxx_include_dir)";\
+ $(INSTALL_DATA) $(src_incdir)/std/$$i $(gxx_include_dir); \
done; \
for i in $(build_headers); do \
- echo "$(INSTALL_DATA) $(bld_incdir)/$$i $(targetincludep)/bits/"; \
- $(INSTALL_DATA) $(bld_incdir)/$$i $(targetincludep)/bits/; \
+ echo "$(INSTALL_DATA) $(bld_incdir)/$$i $(gxx_target_include_dir)/bits/"; \
+ $(INSTALL_DATA) $(bld_incdir)/$$i $(gxx_target_include_dir)/bits/; \
done; \
libio_headers_install='$(libio_headers)'; \
for i in $$libio_headers_install; do \
- echo "$(INSTALL_DATA) $$i $(myincludep)"; \
- $(INSTALL_DATA) $$i $(myincludep); \
+ echo "$(INSTALL_DATA) $$i $(gxx_include_dir)"; \
+ $(INSTALL_DATA) $$i $(gxx_include_dir); \
done; \
fi;