Clean up configure/build longstanding issues.

2000-07-07  Benjamin Kosnik  <bkoz@soma.redhat.com>

	Clean up configure/build longstanding issues.
	* src/Makefile.am (AC_CXXFLAGS): Don't set @SECTION_LDFLAGS@ here.
	(CXXLINK): Add here, instead.

	* Makefile.am (check-install): Make sure mkcheck has execute privs.
	(check): Same here.
	* configure.in (AC_OUTPUT_COMMANDS): Remove hacks here.

	* configure.in (AC_OUTPUT_COMMANDS): Link c_io_libio.h and
	c_io_libio.cc instead of copying.
	* acinclude.m4 (GLIBCPP_ENABLE_CSTDIO): Do link here.

	* configure.in (AC_OUTPUT_COMMANDS): Link $THREADS.h and
	c++threads.h instead of copying.
	* acinclude.m4 (GLIBCPP_ENABLE_THREADS): Do link here.

From-SVN: r34914
This commit is contained in:
Benjamin Kosnik 2000-07-07 22:46:52 +00:00 committed by Benjamin Kosnik
parent 75555da78d
commit c4561450e1
11 changed files with 1089 additions and 1057 deletions

View File

@ -1,3 +1,21 @@
2000-07-07 Benjamin Kosnik <bkoz@soma.redhat.com>
Clean up configure/build longstanding issues.
* src/Makefile.am (AC_CXXFLAGS): Don't set @SECTION_LDFLAGS@ here.
(CXXLINK): Add here, instead.
* Makefile.am (check-install): Make sure mkcheck has execute privs.
(check): Same here.
* configure.in (AC_OUTPUT_COMMANDS): Remove hacks here.
* configure.in (AC_OUTPUT_COMMANDS): Link c_io_libio.h and
c_io_libio.cc instead of copying.
* acinclude.m4 (GLIBCPP_ENABLE_CSTDIO): Do link here.
* configure.in (AC_OUTPUT_COMMANDS): Link $THREADS.h and
c++threads.h instead of copying.
* acinclude.m4 (GLIBCPP_ENABLE_THREADS): Do link here.
2000-07-07 brent verner <brent@rcfile.org>
* testsuite/27_io/istream_unformatted.cc (test05): New test.

View File

@ -32,9 +32,11 @@ gxx_include_dir=$(includedir)/g++
SUBDIRS = math libio src
check: $(top_builddir)/mkcheck
chmod +x $(top_builddir)/mkcheck
$(top_builddir)/mkcheck 0 $(top_builddir) $(top_srcdir)
check-install: $(top_builddir)/mkcheck
chmod +x $(top_builddir)/mkcheck
$(top_builddir)/mkcheck 1 $(top_builddir) $(top_srcdir) $(prefix)
#all-local: stamp-rebuild

View File

@ -71,8 +71,6 @@ CPP = @CPP@
CPU_FLAGS = @CPU_FLAGS@
CSHADOWFLAGS = @CSHADOWFLAGS@
CSHADOW_INCLUDES = @CSHADOW_INCLUDES@
CSTDIO_CC = @CSTDIO_CC@
CSTDIO_H = @CSTDIO_H@
CXX = @CXX@
CXXCPP = @CXXCPP@
DEBUG_FLAGS = @DEBUG_FLAGS@
@ -467,9 +465,11 @@ mostlyclean distclean maintainer-clean
check: $(top_builddir)/mkcheck
chmod +x $(top_builddir)/mkcheck
$(top_builddir)/mkcheck 0 $(top_builddir) $(top_srcdir)
check-install: $(top_builddir)/mkcheck
chmod +x $(top_builddir)/mkcheck
$(top_builddir)/mkcheck 1 $(top_builddir) $(top_srcdir) $(prefix)
# Multilib Makefile bits.

View File

@ -1166,52 +1166,52 @@ AC_DEFUN(GLIBCPP_ENABLE_CSTDIO, [
dnl Check if a valid thread package
case x${enable_cstdio_flag} in
xlibio | x | xno | xnone | xyes)
# default
CSTDIO_H=c_io_libio.h
CSTDIO_CC=c_io_libio.cc
AC_MSG_RESULT(libio)
# default
CSTDIO_H=config/c_io_libio.h
CSTDIO_CC=config/c_io_libio.cc
AC_MSG_RESULT(libio)
# see if we are on a system with libio native (ie, linux)
AC_CHECK_HEADER(libio.h, has_libio=yes, has_libio=no)
# see if we are on a system with libio native (ie, linux)
AC_CHECK_HEADER(libio.h, has_libio=yes, has_libio=no)
# bkoz XXX hack hack need version checks, this is temporary
has_libio=no
# bkoz XXX hack hack need version checks, this is temporary
has_libio=no
if test $has_libio = "yes"; then
BUILD_LIBIO_INCLUDE=
need_libio=no
else
BUILD_LIBIO_INCLUDE='-I../libio'
need_libio=yes
fi
AC_SUBST(BUILD_LIBIO_INCLUDE)
if test $has_libio = "yes"; then
BUILD_LIBIO_INCLUDE=
need_libio=no
else
BUILD_LIBIO_INCLUDE='-I../libio'
need_libio=yes
fi
AC_SUBST(BUILD_LIBIO_INCLUDE)
# see if the _G_config.h header needs to be built.
# NB: This replaces the _G_CONFIG_H machinery in libio-v2
AC_CHECK_HEADER(_G_config.h, has_gconf_h=yes, has_gconf_h=no)
AM_CONDITIONAL(GLIBCPP_NEED_LIBIO_CONFIG_H, test "$has_gconf_h" = no)
# bkoz XXX hack need to add support for non-glibc systems here
has_gconf=no
# see if the _G_config.h header needs to be built.
# NB: This replaces the _G_CONFIG_H machinery in libio-v2
AC_CHECK_HEADER(_G_config.h, has_gconf_h=yes, has_gconf_h=no)
AM_CONDITIONAL(GLIBCPP_NEED_LIBIO_CONFIG_H, test "$has_gconf_h" = no)
# bkoz XXX hack need to add support for non-glibc systems here
has_gconf=no
# bkoz XXX need to add checks for this
need_wlibio=yes
;;
# bkoz XXX need to add checks for this
need_wlibio=yes
;;
xwince)
CSTDIO_H=c_io_wince.h
CSTDIO_CC=c_io_wince.cc
AC_MSG_RESULT(wince)
CSTDIO_H=config/c_io_wince.h
CSTDIO_CC=config/c_io_wince.cc
AC_MSG_RESULT(wince)
need_libio=no
BUILD_LIBIO_INCLUDE=
AC_SUBST(BUILD_LIBIO_INCLUDE)
;;
need_libio=no
BUILD_LIBIO_INCLUDE=
AC_SUBST(BUILD_LIBIO_INCLUDE)
;;
*)
echo "$enable_cstdio is an unknown io package" 1>&2
exit 1
;;
echo "$enable_cstdio is an unknown io package" 1>&2
exit 1
;;
esac
AC_SUBST(CSTDIO_H)
AC_SUBST(CSTDIO_CC)
AC_LINK_FILES($CSTDIO_H, bits/c++io.h)
AC_LINK_FILES($CSTDIO_CC, src/c++io.cc)
AM_CONDITIONAL(GLIBCPP_NEED_LIBIO, test "$need_libio" = yes)
AM_CONDITIONAL(GLIBCPP_NEED_WLIBIO, test "$need_wlibio" = yes)
])
@ -1306,6 +1306,7 @@ AC_DEFUN(GLIBCPP_ENABLE_THREADS, [
AC_SUBST(THREADDEPS)
AC_SUBST(THREADOBJS)
AC_SUBST(THREADSPEC)
AC_LINK_FILES(config/$THREADH, bits/c++threads.h)
])

View File

@ -1178,52 +1178,52 @@ AC_DEFUN(GLIBCPP_ENABLE_CSTDIO, [
dnl Check if a valid thread package
case x${enable_cstdio_flag} in
xlibio | x | xno | xnone | xyes)
# default
CSTDIO_H=c_io_libio.h
CSTDIO_CC=c_io_libio.cc
AC_MSG_RESULT(libio)
# default
CSTDIO_H=config/c_io_libio.h
CSTDIO_CC=config/c_io_libio.cc
AC_MSG_RESULT(libio)
# see if we are on a system with libio native (ie, linux)
AC_CHECK_HEADER(libio.h, has_libio=yes, has_libio=no)
# see if we are on a system with libio native (ie, linux)
AC_CHECK_HEADER(libio.h, has_libio=yes, has_libio=no)
# bkoz XXX hack hack need version checks, this is temporary
has_libio=no
# bkoz XXX hack hack need version checks, this is temporary
has_libio=no
if test $has_libio = "yes"; then
BUILD_LIBIO_INCLUDE=
need_libio=no
else
BUILD_LIBIO_INCLUDE='-I../libio'
need_libio=yes
fi
AC_SUBST(BUILD_LIBIO_INCLUDE)
if test $has_libio = "yes"; then
BUILD_LIBIO_INCLUDE=
need_libio=no
else
BUILD_LIBIO_INCLUDE='-I../libio'
need_libio=yes
fi
AC_SUBST(BUILD_LIBIO_INCLUDE)
# see if the _G_config.h header needs to be built.
# NB: This replaces the _G_CONFIG_H machinery in libio-v2
AC_CHECK_HEADER(_G_config.h, has_gconf_h=yes, has_gconf_h=no)
AM_CONDITIONAL(GLIBCPP_NEED_LIBIO_CONFIG_H, test "$has_gconf_h" = no)
# bkoz XXX hack need to add support for non-glibc systems here
has_gconf=no
# see if the _G_config.h header needs to be built.
# NB: This replaces the _G_CONFIG_H machinery in libio-v2
AC_CHECK_HEADER(_G_config.h, has_gconf_h=yes, has_gconf_h=no)
AM_CONDITIONAL(GLIBCPP_NEED_LIBIO_CONFIG_H, test "$has_gconf_h" = no)
# bkoz XXX hack need to add support for non-glibc systems here
has_gconf=no
# bkoz XXX need to add checks for this
need_wlibio=yes
;;
# bkoz XXX need to add checks for this
need_wlibio=yes
;;
xwince)
CSTDIO_H=c_io_wince.h
CSTDIO_CC=c_io_wince.cc
AC_MSG_RESULT(wince)
CSTDIO_H=config/c_io_wince.h
CSTDIO_CC=config/c_io_wince.cc
AC_MSG_RESULT(wince)
need_libio=no
BUILD_LIBIO_INCLUDE=
AC_SUBST(BUILD_LIBIO_INCLUDE)
;;
need_libio=no
BUILD_LIBIO_INCLUDE=
AC_SUBST(BUILD_LIBIO_INCLUDE)
;;
*)
echo "$enable_cstdio is an unknown io package" 1>&2
exit 1
;;
echo "$enable_cstdio is an unknown io package" 1>&2
exit 1
;;
esac
AC_SUBST(CSTDIO_H)
AC_SUBST(CSTDIO_CC)
AC_LINK_FILES($CSTDIO_H, bits/c++io.h)
AC_LINK_FILES($CSTDIO_CC, src/c++io.cc)
AM_CONDITIONAL(GLIBCPP_NEED_LIBIO, test "$need_libio" = yes)
AM_CONDITIONAL(GLIBCPP_NEED_WLIBIO, test "$need_wlibio" = yes)
])
@ -1318,6 +1318,7 @@ AC_DEFUN(GLIBCPP_ENABLE_THREADS, [
AC_SUBST(THREADDEPS)
AC_SUBST(THREADOBJS)
AC_SUBST(THREADSPEC)
AC_LINK_FILES(config/$THREADH, bits/c++threads.h)
])

1948
libstdc++-v3/configure vendored

File diff suppressed because it is too large Load Diff

View File

@ -174,19 +174,9 @@ CXX="${CXX}"
blddir=`pwd`
# Generate mkcheck having execute privs
AC_OUTPUT_COMMANDS([chmod +x $blddir/mkcheck])
# Generate bits/c++config.h
# NB: This must be the first generated file as others include it. . .
AC_OUTPUT_COMMANDS([$srcdir/mkc++config $blddir $srcdir])
# Generate bits/std_limits.h and src/limitsMEMBERS.cc
AC_OUTPUT_COMMANDS([$srcdir/mknumeric_limits $blddir $srcdir $xcompiling])
# Generate bits/c++threads.h
AC_OUTPUT_COMMANDS([cp $srcdir/config/$THREADH $blddir/bits/c++threads.h])
# Generate bits/c++io.h and src/c++io.cc
AC_OUTPUT_COMMANDS([cp $srcdir/config/$CSTDIO_H $blddir/bits/c++io.h])
AC_OUTPUT_COMMANDS([cp $srcdir/config/$CSTDIO_CC $blddir/src/c++io.cc])

View File

@ -70,8 +70,6 @@ CC = @CC@
CPP = @CPP@
CPU_FLAGS = @CPU_FLAGS@
CSHADOWFLAGS = @CSHADOWFLAGS@
CSTDIO_CC = @CSTDIO_CC@
CSTDIO_H = @CSTDIO_H@
CXX = @CXX@
CXXCPP = @CXXCPP@
DEBUG_FLAGS = @DEBUG_FLAGS@

View File

@ -71,8 +71,6 @@ CPP = @CPP@
CPU_FLAGS = @CPU_FLAGS@
CSHADOWFLAGS = @CSHADOWFLAGS@
CSHADOW_INCLUDES = @CSHADOW_INCLUDES@
CSTDIO_CC = @CSTDIO_CC@
CSTDIO_H = @CSTDIO_H@
CXX = @CXX@
CXXCPP = @CXXCPP@
DEBUG_FLAGS = @DEBUG_FLAGS@

View File

@ -46,7 +46,7 @@ EXTRA_LTLIBRARIES = libinst-string.la libinst-wstring.la
# NB: DEBUGFLAGS have to be at the end so that -O2 can be overridden.
AC_CXXFLAGS = \
$(WERROR) @WFMT_FLAGS@ @CPU_FLAGS@ @EXTRA_CXX_FLAGS@ \
@SECTION_FLAGS@ @SECTION_LDFLAGS@ @DEBUG_FLAGS@
@SECTION_FLAGS@ @DEBUG_FLAGS@
# Need to manually set this option because AC_CXXFLAGS has to be at
# the end of the compile line so that -O2 can be overridden as the
@ -87,7 +87,7 @@ LTCXXCOMPILE = $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(INCLUDES) \
# rules automake generates would be used. We cannot allow CXX to be used
# in libtool since this would add -lstdc++ to the link line which of
# course is impossible.
CXXLINK = $(LIBTOOL) --mode=link "$(CC)" $(AM_CXXFLAGS) $(LDFLAGS) -o $@
CXXLINK = $(LIBTOOL) --mode=link "$(CC)" @SECTION_LDFLAGS@ $(AM_CXXFLAGS) $(LDFLAGS) -o $@
headers = \

View File

@ -69,8 +69,6 @@ CC = @CC@
CPP = @CPP@
CPU_FLAGS = @CPU_FLAGS@
CSHADOWFLAGS = @CSHADOWFLAGS@
CSTDIO_CC = @CSTDIO_CC@
CSTDIO_H = @CSTDIO_H@
CXX = @CXX@
CXXCPP = @CXXCPP@
DEBUG_FLAGS = @DEBUG_FLAGS@
@ -123,7 +121,7 @@ EXTRA_LTLIBRARIES = libinst-string.la libinst-wstring.la
# NB: DEBUGFLAGS have to be at the end so that -O2 can be overridden.
AC_CXXFLAGS = \
$(WERROR) @WFMT_FLAGS@ @CPU_FLAGS@ @EXTRA_CXX_FLAGS@ \
@SECTION_FLAGS@ @SECTION_LDFLAGS@ @DEBUG_FLAGS@
@SECTION_FLAGS@ @DEBUG_FLAGS@
# Need to manually set this option because AC_CXXFLAGS has to be at
@ -168,7 +166,7 @@ LTCXXCOMPILE = $(LIBTOOL) --mode=compile $(CXX) $(DEFS) $(INCLUDES) \
# rules automake generates would be used. We cannot allow CXX to be used
# in libtool since this would add -lstdc++ to the link line which of
# course is impossible.
CXXLINK = $(LIBTOOL) --mode=link "$(CC)" $(AM_CXXFLAGS) $(LDFLAGS) -o $@
CXXLINK = $(LIBTOOL) --mode=link "$(CC)" @SECTION_LDFLAGS@ $(AM_CXXFLAGS) $(LDFLAGS) -o $@
headers = \
bits/cpp_type_traits.h \