Commit 5ec62d44 by Phil Edwards

Makefile.am: Use LD_RUN_PATH when linking abi_check.

2002-09-01  Phil Edwards  <pme@gcc.gnu.org>

	* testsuite/Makefile.am:  Use LD_RUN_PATH when linking abi_check.
	Fix spelling in comment.
	* testsuite/Makefile.in:  Regenerate.
	* testsuite/abi_check.cc:  Use string literals to build 'cmd' rather
	than 'quote' and 'bslash'.

From-SVN: r56722
parent 0475ed26
2002-09-01 Phil Edwards <pme@gcc.gnu.org>
* testsuite/Makefile.am: Use LD_RUN_PATH when linking abi_check.
Fix spelling in comment.
* testsuite/Makefile.in: Regenerate.
* testsuite/abi_check.cc: Use string literals to build 'cmd' rather
than 'quote' and 'bslash'.
2002-08-31 Phil Edwards <pme@gcc.gnu.org> 2002-08-31 Phil Edwards <pme@gcc.gnu.org>
* acinclude.m4: Minor comment tweaks. * acinclude.m4: Minor comment tweaks.
......
...@@ -37,10 +37,11 @@ AM_RUNTESTFLAGS = ...@@ -37,10 +37,11 @@ AM_RUNTESTFLAGS =
RUNTESTFLAGS = RUNTESTFLAGS =
## CXX is actually a "C" compiler. These are real C++ programs. ## CXX is actually a "C" compiler. These are real C++ programs.
## Do the same thing as `testsuite_hooks --build-cxx` ## Do the same thing as `testsuite_flags --build-cxx`
CXX_fake = @glibcpp_CXX@ CXX_fake = @glibcpp_CXX@
CXX=`echo $(CXX_fake) | sed 's/xgcc/g++/g'` CXX=`echo $(CXX_fake) | sed 's/xgcc/g++/g'`
CXXLINK = \ CXXLINK = \
LD_RUN_PATH=${LD_RUN_PATH:+$LD_RUN_PATH:}${glibcpp_builddir}/src/.libs\
$(LIBTOOL) --tag=CXX --mode=link $(CXX) \ $(LIBTOOL) --tag=CXX --mode=link $(CXX) \
$(AM_CXXFLAGS) $(CXXFLAGS) $(LDFLAGS) -o $@ $(AM_CXXFLAGS) $(CXXFLAGS) $(LDFLAGS) -o $@
......
# Makefile.in generated automatically by automake 1.4-p5 from Makefile.am # Makefile.in generated automatically by automake 1.4-p6 from Makefile.am
# Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc. # Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation # This Makefile.in is free software; the Free Software Foundation
...@@ -136,14 +136,10 @@ AUTOMAKE_OPTIONS = cygnus dejagnu ...@@ -136,14 +136,10 @@ AUTOMAKE_OPTIONS = cygnus dejagnu
DEJATOOL = libstdc++-v3 DEJATOOL = libstdc++-v3
EXPECT = `if [ -f @glibcpp_builddir@/../../expect/expect ] ; then \ EXPECT = `if [ -f @glibcpp_builddir@/../../expect/expect ] ; then echo @glibcpp_builddir@/../../expect/expect ; else echo expect ; fi`
echo @glibcpp_builddir@/../../expect/expect ; \
else echo expect ; fi`
RUNTEST = `if [ -f @glibcpp_srcdir@/../dejagnu/runtest ] ; then \ RUNTEST = `if [ -f @glibcpp_srcdir@/../dejagnu/runtest ] ; then echo @glibcpp_srcdir@/../dejagnu/runtest ; else echo runtest; fi`
echo @glibcpp_srcdir@/../dejagnu/runtest ; \
else echo runtest; fi`
AM_RUNTESTFLAGS = AM_RUNTESTFLAGS =
...@@ -151,19 +147,15 @@ RUNTESTFLAGS = ...@@ -151,19 +147,15 @@ RUNTESTFLAGS =
CXX_fake = @glibcpp_CXX@ CXX_fake = @glibcpp_CXX@
CXX = `echo $(CXX_fake) | sed 's/xgcc/g++/g'` CXX = `echo $(CXX_fake) | sed 's/xgcc/g++/g'`
CXXLINK = \ CXXLINK = LD_RUN_PATH=${LD_RUN_PATH:+$LD_RUN_PATH:}${glibcpp_builddir}/src/.libs $(LIBTOOL) --tag=CXX --mode=link $(CXX) $(AM_CXXFLAGS) $(CXXFLAGS) $(LDFLAGS) -o $@
$(LIBTOOL) --tag=CXX --mode=link $(CXX) \
$(AM_CXXFLAGS) $(CXXFLAGS) $(LDFLAGS) -o $@
INCLUDES = \ INCLUDES = -nostdinc++ @GLIBCPP_INCLUDES@ @LIBSUPCXX_INCLUDES@ @TOPLEVEL_INCLUDES@
-nostdinc++ \
@GLIBCPP_INCLUDES@ @LIBSUPCXX_INCLUDES@ @TOPLEVEL_INCLUDES@
noinst_LIBRARIES = libv3test.a noinst_LIBRARIES = libv3test.a
libv3test_a_SOURCES = testsuite_hooks.cc libv3test_a_SOURCES = testsuite_hooks.cc
@GLIBCPP_BUILD_ABI_CHECK_TRUE@noinst_PROGRAMS = @GLIBCPP_BUILD_ABI_CHECK_TRUE@abi_check @GLIBCPP_BUILD_ABI_CHECK_TRUE@noinst_PROGRAMS = abi_check
@GLIBCPP_BUILD_ABI_CHECK_FALSE@noinst_PROGRAMS = @GLIBCPP_BUILD_ABI_CHECK_FALSE@noinst_PROGRAMS =
abi_check_SOURCES = abi_check.cc abi_check_SOURCES = abi_check.cc
mkinstalldirs = $(SHELL) $(top_srcdir)/../mkinstalldirs mkinstalldirs = $(SHELL) $(top_srcdir)/../mkinstalldirs
...@@ -194,7 +186,7 @@ DIST_COMMON = README Makefile.am Makefile.in ...@@ -194,7 +186,7 @@ DIST_COMMON = README Makefile.am Makefile.in
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
TAR = gtar TAR = tar
GZIP_ENV = --best GZIP_ENV = --best
SOURCES = $(libv3test_a_SOURCES) $(abi_check_SOURCES) SOURCES = $(libv3test_a_SOURCES) $(abi_check_SOURCES)
OBJECTS = $(libv3test_a_OBJECTS) $(abi_check_OBJECTS) OBJECTS = $(libv3test_a_OBJECTS) $(abi_check_OBJECTS)
...@@ -305,7 +297,7 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) $(LISP) ...@@ -305,7 +297,7 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) $(LISP)
awk ' { files[$$0] = 1; } \ awk ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \ END { for (i in files) print i; }'`; \
test -z "$(ETAGS_ARGS)$$unique$(LISP)$$tags" \ test -z "$(ETAGS_ARGS)$$unique$(LISP)$$tags" \
|| (cd $(srcdir) && etags $(ETAGS_ARGS) $$tags $$unique $(LISP) -o $$here/TAGS) || (cd $(srcdir) && etags -o $$here/TAGS $(ETAGS_ARGS) $$tags $$unique $(LISP))
mostlyclean-tags: mostlyclean-tags:
...@@ -362,7 +354,7 @@ site.exp: Makefile ...@@ -362,7 +354,7 @@ site.exp: Makefile
@echo 'set build_alias $(build_alias)' >> $@-t @echo 'set build_alias $(build_alias)' >> $@-t
@echo 'set build_triplet $(build_triplet)' >> $@-t @echo 'set build_triplet $(build_triplet)' >> $@-t
@echo '## All variables above are generated by configure. Do Not Edit ##' >> $@-t @echo '## All variables above are generated by configure. Do Not Edit ##' >> $@-t
@test ! -f site.exp || sed '1,/^## All variables above are.*##/ d' site.exp >> $@-t @test ! -f $(srcdir)/site.exp || sed '1,/^## All variables above are.*##/ d' $(srcdir)/site.exp >> $@-t
@test ! -f site.exp || mv site.exp site.bak @test ! -f site.exp || mv site.exp site.bak
@mv $@-t site.exp @mv $@-t site.exp
info-am: info-am:
......
...@@ -249,8 +249,6 @@ int main(int argc, char** argv) ...@@ -249,8 +249,6 @@ int main(int argc, char** argv)
"%s:%s\n", $4, $8; else if ($4 == "OBJECT") printf "%s:%s:%s\n", $4, "%s:%s\n", $4, $8; else if ($4 == "OBJECT") printf "%s:%s:%s\n", $4,
$3, $8;}' | sort >& current_symbols.txt $3, $8;}' | sort >& current_symbols.txt
*/ */
const char quote = '"';
const char bslash = '\\';
// GNU binutils, somewhere after version 2.11.2, requires -W/--wide // GNU binutils, somewhere after version 2.11.2, requires -W/--wide
// to avoid default line truncation. -W is not supported and // to avoid default line truncation. -W is not supported and
...@@ -259,15 +257,13 @@ int main(int argc, char** argv) ...@@ -259,15 +257,13 @@ int main(int argc, char** argv)
(system("readelf --help | grep -- --wide >/dev/null") == 0); (system("readelf --help | grep -- --wide >/dev/null") == 0);
ostringstream cmd; ostringstream cmd;
cmd << "readelf -s " << (readelf_need_wide ? "-W " : "") cmd << "readelf -s " << (readelf_need_wide ? "-W " : "") << test_lib
<< test_lib << " | sed '/" << bslash << " | sed '/\\.dynsym/,/^$/p;d' | egrep -v ' (LOCAL|UND) ' | "
<< ".dynsym/,/^$/p;d' | egrep -v ' (LOCAL|UND) ' | " "awk '{ if ($4 == \"FUNC\" || $4 == \"NOTYPE\") "
<< "awk '{ if ($4 == " << quote << "FUNC" << quote << "|| $4 == " "printf \"%s:%s\\n\", $4, $8; "
<< quote << "NOTYPE" << quote << ") printf " << quote << "%s:%s" "else if ($4 == \"OBJECT\") "
<< bslash << "n" << quote << ", $4, $8; else if ($4 == " "printf \"%s:%s:%s\\n\", $4, $3, $8;}' | sort > "
<< quote << "OBJECT" << quote << ") printf " << quote << test_file << " 2>&1";
<< "%s:%s:%s" << bslash << "n" << quote << ", $4, $3, $8;}' | "
<< "sort > " << test_file << " 2>&1";
if (system(cmd.str().c_str()) != 0) if (system(cmd.str().c_str()) != 0)
{ {
cerr << "Unable to generate the list of exported symbols." << endl; cerr << "Unable to generate the list of exported symbols." << endl;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment