From 1fe927756ca51f3e7efd868b29a8d4299e91a331 Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Fri, 2 Apr 2010 18:09:43 +0200 Subject: [PATCH] Tests for module 'havelib', moved here from GNU gettext. --- ChangeLog | 119 ++++++++++++++ modules/havelib-tests | 297 +++++++++++++++++++++++++++++++++++ tests/havelib/Makefile.am | 79 ++++++++++ tests/havelib/README | 77 +++++++++ tests/havelib/rpath-1 | 40 +++++ tests/havelib/rpath-1a | 9 ++ tests/havelib/rpath-1b | 9 ++ tests/havelib/rpath-2_a | 56 +++++++ tests/havelib/rpath-2_b | 69 ++++++++ tests/havelib/rpath-2aaa | 12 ++ tests/havelib/rpath-2aab | 12 ++ tests/havelib/rpath-2aac | 12 ++ tests/havelib/rpath-2aad | 12 ++ tests/havelib/rpath-2aba | 13 ++ tests/havelib/rpath-2abb | 13 ++ tests/havelib/rpath-2abc | 13 ++ tests/havelib/rpath-2abd | 13 ++ tests/havelib/rpath-2baa | 14 ++ tests/havelib/rpath-2bab | 14 ++ tests/havelib/rpath-2bac | 14 ++ tests/havelib/rpath-2bad | 14 ++ tests/havelib/rpath-2bba | 15 ++ tests/havelib/rpath-2bbb | 15 ++ tests/havelib/rpath-2bbc | 15 ++ tests/havelib/rpath-2bbd | 15 ++ tests/havelib/rpath-3_a | 69 ++++++++ tests/havelib/rpath-3_b | 86 ++++++++++ tests/havelib/rpath-3aaa | 14 ++ tests/havelib/rpath-3aab | 14 ++ tests/havelib/rpath-3aac | 14 ++ tests/havelib/rpath-3aad | 14 ++ tests/havelib/rpath-3aae | 14 ++ tests/havelib/rpath-3aaf | 14 ++ tests/havelib/rpath-3aag | 14 ++ tests/havelib/rpath-3aah | 14 ++ tests/havelib/rpath-3aba | 15 ++ tests/havelib/rpath-3abb | 15 ++ tests/havelib/rpath-3abc | 15 ++ tests/havelib/rpath-3abd | 15 ++ tests/havelib/rpath-3abe | 15 ++ tests/havelib/rpath-3abf | 15 ++ tests/havelib/rpath-3abg | 15 ++ tests/havelib/rpath-3abh | 15 ++ tests/havelib/rpath-3baa | 16 ++ tests/havelib/rpath-3bab | 16 ++ tests/havelib/rpath-3bac | 16 ++ tests/havelib/rpath-3bad | 16 ++ tests/havelib/rpath-3bae | 16 ++ tests/havelib/rpath-3baf | 16 ++ tests/havelib/rpath-3bag | 16 ++ tests/havelib/rpath-3bah | 16 ++ tests/havelib/rpath-3bba | 17 ++ tests/havelib/rpath-3bbb | 17 ++ tests/havelib/rpath-3bbc | 17 ++ tests/havelib/rpath-3bbd | 17 ++ tests/havelib/rpath-3bbe | 17 ++ tests/havelib/rpath-3bbf | 17 ++ tests/havelib/rpath-3bbg | 17 ++ tests/havelib/rpath-3bbh | 17 ++ tests/havelib/rpathcfg.sh | 232 +++++++++++++++++++++++++++ tests/havelib/rpathlx/Makefile.am | 7 + tests/havelib/rpathlx/configure.ac | 24 +++ tests/havelib/rpathlx/usex.c | 2 + tests/havelib/rpathly/Makefile.am | 7 + tests/havelib/rpathly/configure.ac | 24 +++ tests/havelib/rpathly/usey.c | 2 + tests/havelib/rpathlyx/Makefile.am | 7 + tests/havelib/rpathlyx/configure.ac | 26 +++ tests/havelib/rpathlyx/usey.c | 2 + tests/havelib/rpathlz/Makefile.am | 7 + tests/havelib/rpathlz/configure.ac | 24 +++ tests/havelib/rpathlz/usez.c | 2 + tests/havelib/rpathlzyx/Makefile.am | 7 + tests/havelib/rpathlzyx/configure.ac | 27 ++++ tests/havelib/rpathlzyx/usez.c | 2 + tests/havelib/rpathx/Makefile.am | 4 + tests/havelib/rpathx/configure.ac | 25 +++ tests/havelib/rpathx/rpathx.c | 1 + tests/havelib/rpathy/Makefile.am | 4 + tests/havelib/rpathy/configure.ac | 26 +++ tests/havelib/rpathy/rpathy.c | 2 + tests/havelib/rpathz/Makefile.am | 4 + tests/havelib/rpathz/configure.ac | 27 ++++ tests/havelib/rpathz/rpathz.c | 3 + 84 files changed, 2120 insertions(+) create mode 100644 modules/havelib-tests create mode 100644 tests/havelib/Makefile.am create mode 100644 tests/havelib/README create mode 100644 tests/havelib/rpath-1 create mode 100755 tests/havelib/rpath-1a create mode 100755 tests/havelib/rpath-1b create mode 100644 tests/havelib/rpath-2_a create mode 100644 tests/havelib/rpath-2_b create mode 100755 tests/havelib/rpath-2aaa create mode 100755 tests/havelib/rpath-2aab create mode 100755 tests/havelib/rpath-2aac create mode 100755 tests/havelib/rpath-2aad create mode 100755 tests/havelib/rpath-2aba create mode 100755 tests/havelib/rpath-2abb create mode 100755 tests/havelib/rpath-2abc create mode 100755 tests/havelib/rpath-2abd create mode 100755 tests/havelib/rpath-2baa create mode 100755 tests/havelib/rpath-2bab create mode 100755 tests/havelib/rpath-2bac create mode 100755 tests/havelib/rpath-2bad create mode 100755 tests/havelib/rpath-2bba create mode 100755 tests/havelib/rpath-2bbb create mode 100755 tests/havelib/rpath-2bbc create mode 100755 tests/havelib/rpath-2bbd create mode 100644 tests/havelib/rpath-3_a create mode 100644 tests/havelib/rpath-3_b create mode 100755 tests/havelib/rpath-3aaa create mode 100755 tests/havelib/rpath-3aab create mode 100755 tests/havelib/rpath-3aac create mode 100755 tests/havelib/rpath-3aad create mode 100755 tests/havelib/rpath-3aae create mode 100755 tests/havelib/rpath-3aaf create mode 100755 tests/havelib/rpath-3aag create mode 100755 tests/havelib/rpath-3aah create mode 100755 tests/havelib/rpath-3aba create mode 100755 tests/havelib/rpath-3abb create mode 100755 tests/havelib/rpath-3abc create mode 100755 tests/havelib/rpath-3abd create mode 100755 tests/havelib/rpath-3abe create mode 100755 tests/havelib/rpath-3abf create mode 100755 tests/havelib/rpath-3abg create mode 100755 tests/havelib/rpath-3abh create mode 100755 tests/havelib/rpath-3baa create mode 100755 tests/havelib/rpath-3bab create mode 100755 tests/havelib/rpath-3bac create mode 100755 tests/havelib/rpath-3bad create mode 100755 tests/havelib/rpath-3bae create mode 100755 tests/havelib/rpath-3baf create mode 100755 tests/havelib/rpath-3bag create mode 100755 tests/havelib/rpath-3bah create mode 100755 tests/havelib/rpath-3bba create mode 100755 tests/havelib/rpath-3bbb create mode 100755 tests/havelib/rpath-3bbc create mode 100755 tests/havelib/rpath-3bbd create mode 100755 tests/havelib/rpath-3bbe create mode 100755 tests/havelib/rpath-3bbf create mode 100755 tests/havelib/rpath-3bbg create mode 100755 tests/havelib/rpath-3bbh create mode 100755 tests/havelib/rpathcfg.sh create mode 100644 tests/havelib/rpathlx/Makefile.am create mode 100644 tests/havelib/rpathlx/configure.ac create mode 100644 tests/havelib/rpathlx/usex.c create mode 100644 tests/havelib/rpathly/Makefile.am create mode 100644 tests/havelib/rpathly/configure.ac create mode 100644 tests/havelib/rpathly/usey.c create mode 100644 tests/havelib/rpathlyx/Makefile.am create mode 100644 tests/havelib/rpathlyx/configure.ac create mode 100644 tests/havelib/rpathlyx/usey.c create mode 100644 tests/havelib/rpathlz/Makefile.am create mode 100644 tests/havelib/rpathlz/configure.ac create mode 100644 tests/havelib/rpathlz/usez.c create mode 100644 tests/havelib/rpathlzyx/Makefile.am create mode 100644 tests/havelib/rpathlzyx/configure.ac create mode 100644 tests/havelib/rpathlzyx/usez.c create mode 100644 tests/havelib/rpathx/Makefile.am create mode 100644 tests/havelib/rpathx/configure.ac create mode 100644 tests/havelib/rpathx/rpathx.c create mode 100644 tests/havelib/rpathy/Makefile.am create mode 100644 tests/havelib/rpathy/configure.ac create mode 100644 tests/havelib/rpathy/rpathy.c create mode 100644 tests/havelib/rpathz/Makefile.am create mode 100644 tests/havelib/rpathz/configure.ac create mode 100644 tests/havelib/rpathz/rpathz.c diff --git a/ChangeLog b/ChangeLog index 07bd51c66..6b71c8894 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,124 @@ 2010-04-02 Bruno Haible + Tests for module 'havelib', moved here from GNU gettext. + * modules/havelib-tests: New file, from gettext/autoconf-lib-link with + modifications. + * tests/havelib/README: New file, from gettext/autoconf-lib-link. + * tests/havelib/Makefile.am: New file, from gettext/autoconf-lib-link + with modifications. + * tests/havelib/rpath-1: New file, from gettext/autoconf-lib-link with + modifications. + * tests/havelib/rpath-1a: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-1b: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2_a: New file, from gettext/autoconf-lib-link + with modifications. + * tests/havelib/rpath-2_b: New file, from gettext/autoconf-lib-link + with modifications. + * tests/havelib/rpath-2aaa: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2aab: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2aac: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2aad: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2aba: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2abb: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2abc: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2abd: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2baa: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2bab: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2bac: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2bad: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2bba: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2bbb: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2bbc: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-2bbd: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3_a: New file, from gettext/autoconf-lib-link + with modifications. + * tests/havelib/rpath-3_b: New file, from gettext/autoconf-lib-link + with modifications. + * tests/havelib/rpath-3aaa: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3aab: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3aac: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3aad: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3aae: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3aaf: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3aag: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3aah: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3aba: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3abb: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3abc: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3abd: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3abe: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3abf: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3abg: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3abh: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3baa: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3bab: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3bac: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3bad: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3bae: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3baf: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3bag: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3bah: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3bba: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3bbb: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3bbc: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3bbd: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3bbe: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3bbf: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3bbg: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpath-3bbh: New file, from gettext/autoconf-lib-link. + * tests/havelib/rpathx/rpathx.c: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathx/Makefile.am: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathx/configure.ac: New file, from + gettext/autoconf-lib-link with modifications. + * tests/havelib/rpathy/rpathy.c: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathy/Makefile.am: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathy/configure.ac: New file, from + gettext/autoconf-lib-link with modifications. + * tests/havelib/rpathz/rpathz.c: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathz/Makefile.am: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathz/configure.ac: New file, from + gettext/autoconf-lib-link with modifications. + * tests/havelib/rpathlx/usex.c: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathlx/Makefile.am: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathlx/configure.ac: New file, from + gettext/autoconf-lib-link with modifications. + * tests/havelib/rpathly/usey.c: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathly/Makefile.am: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathly/configure.ac: New file, from + gettext/autoconf-lib-link with modifications. + * tests/havelib/rpathlz/usez.c: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathlz/Makefile.am: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathlz/configure.ac: New file, from + gettext/autoconf-lib-link with modifications. + * tests/havelib/rpathlyx/usey.c: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathlyx/Makefile.am: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathlyx/configure.ac: New file, from + gettext/autoconf-lib-link with modifications. + * tests/havelib/rpathlzyx/usez.c: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathlzyx/Makefile.am: New file, from + gettext/autoconf-lib-link. + * tests/havelib/rpathlzyx/configure.ac: New file, from + gettext/autoconf-lib-link with modifications. + * tests/havelib/rpathcfg.sh: New file, from gettext/autoconf-lib-link + with modifications. + +2010-04-02 Bruno Haible + gnulib-tool: Create distributed built sources also for the tests. * gnulib-tool (func_create_testdir): Also generate distributed built sources in the tests directory. diff --git a/modules/havelib-tests b/modules/havelib-tests new file mode 100644 index 000000000..6a60b5688 --- /dev/null +++ b/modules/havelib-tests @@ -0,0 +1,297 @@ +Status: +longrunning-test +unportable-test + +Files: +tests/havelib/README +tests/havelib/Makefile.am +tests/havelib/rpath-1 +tests/havelib/rpath-1a +tests/havelib/rpath-1b +tests/havelib/rpath-2_a +tests/havelib/rpath-2_b +tests/havelib/rpath-2aaa +tests/havelib/rpath-2aab +tests/havelib/rpath-2aac +tests/havelib/rpath-2aad +tests/havelib/rpath-2aba +tests/havelib/rpath-2abb +tests/havelib/rpath-2abc +tests/havelib/rpath-2abd +tests/havelib/rpath-2baa +tests/havelib/rpath-2bab +tests/havelib/rpath-2bac +tests/havelib/rpath-2bad +tests/havelib/rpath-2bba +tests/havelib/rpath-2bbb +tests/havelib/rpath-2bbc +tests/havelib/rpath-2bbd +tests/havelib/rpath-3_a +tests/havelib/rpath-3_b +tests/havelib/rpath-3aaa +tests/havelib/rpath-3aab +tests/havelib/rpath-3aac +tests/havelib/rpath-3aad +tests/havelib/rpath-3aae +tests/havelib/rpath-3aaf +tests/havelib/rpath-3aag +tests/havelib/rpath-3aah +tests/havelib/rpath-3aba +tests/havelib/rpath-3abb +tests/havelib/rpath-3abc +tests/havelib/rpath-3abd +tests/havelib/rpath-3abe +tests/havelib/rpath-3abf +tests/havelib/rpath-3abg +tests/havelib/rpath-3abh +tests/havelib/rpath-3baa +tests/havelib/rpath-3bab +tests/havelib/rpath-3bac +tests/havelib/rpath-3bad +tests/havelib/rpath-3bae +tests/havelib/rpath-3baf +tests/havelib/rpath-3bag +tests/havelib/rpath-3bah +tests/havelib/rpath-3bba +tests/havelib/rpath-3bbb +tests/havelib/rpath-3bbc +tests/havelib/rpath-3bbd +tests/havelib/rpath-3bbe +tests/havelib/rpath-3bbf +tests/havelib/rpath-3bbg +tests/havelib/rpath-3bbh +tests/havelib/rpathx/rpathx.c +tests/havelib/rpathx/Makefile.am +tests/havelib/rpathx/configure.ac +tests/havelib/rpathy/rpathy.c +tests/havelib/rpathy/Makefile.am +tests/havelib/rpathy/configure.ac +tests/havelib/rpathz/rpathz.c +tests/havelib/rpathz/Makefile.am +tests/havelib/rpathz/configure.ac +tests/havelib/rpathlx/usex.c +tests/havelib/rpathlx/Makefile.am +tests/havelib/rpathlx/configure.ac +tests/havelib/rpathly/usey.c +tests/havelib/rpathly/Makefile.am +tests/havelib/rpathly/configure.ac +tests/havelib/rpathlz/usez.c +tests/havelib/rpathlz/Makefile.am +tests/havelib/rpathlz/configure.ac +tests/havelib/rpathlyx/usey.c +tests/havelib/rpathlyx/Makefile.am +tests/havelib/rpathlyx/configure.ac +tests/havelib/rpathlzyx/usez.c +tests/havelib/rpathlzyx/Makefile.am +tests/havelib/rpathlzyx/configure.ac +tests/havelib/rpathcfg.sh + +Depends-on: + +configure.ac: +HAVELIB_M4_BASE="${gl_m4_base}" +AC_SUBST([HAVELIB_M4_BASE]) + +AC_LIB_PREPARE_MULTILIB +LIBDIRSTEM=$acl_libdirstem +AC_SUBST([LIBDIRSTEM]) + +dnl Checks for tests/rpathcfg. +AC_SUBST([GCC]) +AC_SUBST([LD]) +AC_SUBST([with_gnu_ld]) + +AC_CONFIG_FILES([havelib/Makefile]) + +Makefile.am: +SUBDIRS += havelib + + +# These variables can be overridden on the 'make' command line. +ACLOCAL = aclocal +AUTOCONF = autoconf +AUTOMAKE = automake +LIBTOOLIZE = libtoolize + +HAVELIB_GENERATED_FILES = \ + havelib/Makefile.in \ + havelib/rpathx/Makefile.in \ + havelib/rpathx/aclocal.m4 \ + havelib/rpathx/configure \ + havelib/rpathy/Makefile.in \ + havelib/rpathy/aclocal.m4 \ + havelib/rpathy/configure \ + havelib/rpathz/Makefile.in \ + havelib/rpathz/aclocal.m4 \ + havelib/rpathz/configure \ + havelib/rpathlx/Makefile.in \ + havelib/rpathlx/aclocal.m4 \ + havelib/rpathlx/configure \ + havelib/rpathly/Makefile.in \ + havelib/rpathly/aclocal.m4 \ + havelib/rpathly/configure \ + havelib/rpathlz/Makefile.in \ + havelib/rpathlz/aclocal.m4 \ + havelib/rpathlz/configure \ + havelib/rpathlyx/Makefile.in \ + havelib/rpathlyx/aclocal.m4 \ + havelib/rpathlyx/configure \ + havelib/rpathlzyx/Makefile.in \ + havelib/rpathlzyx/aclocal.m4 \ + havelib/rpathlzyx/configure + +BUILT_SOURCES += \ + havelib/Makefile.in \ + havelib/rpathx/Makefile.in \ + havelib/rpathx/aclocal.m4 \ + havelib/rpathx/configure \ + havelib/rpathy/Makefile.in \ + havelib/rpathy/aclocal.m4 \ + havelib/rpathy/configure \ + havelib/rpathz/Makefile.in \ + havelib/rpathz/aclocal.m4 \ + havelib/rpathz/configure \ + havelib/rpathlx/Makefile.in \ + havelib/rpathlx/aclocal.m4 \ + havelib/rpathlx/configure \ + havelib/rpathly/Makefile.in \ + havelib/rpathly/aclocal.m4 \ + havelib/rpathly/configure \ + havelib/rpathlz/Makefile.in \ + havelib/rpathlz/aclocal.m4 \ + havelib/rpathlz/configure \ + havelib/rpathlyx/Makefile.in \ + havelib/rpathlyx/aclocal.m4 \ + havelib/rpathlyx/configure \ + havelib/rpathlzyx/Makefile.in \ + havelib/rpathlzyx/aclocal.m4 \ + havelib/rpathlzyx/configure + +$(srcdir)/havelib/Makefile.in: $(srcdir)/havelib/Makefile.am + cd $(srcdir) && $(AUTOMAKE) havelib/Makefile + +# Subdirectories with separate autoconfiguration. + +$(srcdir)/havelib/rpathx/Makefile.in: $(srcdir)/havelib/rpathx/Makefile.am $(srcdir)/havelib/rpathx/configure.ac $(srcdir)/havelib/rpathx/aclocal.m4 + cd $(srcdir)/havelib/rpathx && $(AUTOMAKE) Makefile +$(srcdir)/havelib/rpathx/aclocal.m4: $(srcdir)/havelib/rpathx/configure.ac + cd $(srcdir)/havelib/rpathx && $(LIBTOOLIZE) --copy + abs_m4_dir=`cd $(top_srcdir)/@HAVELIB_M4_BASE@ && pwd`; cd $(srcdir)/havelib/rpathx && $(ACLOCAL) -I "$$abs_m4_dir" -I `cd ../ltm4 && pwd` +$(srcdir)/havelib/rpathx/configure: $(srcdir)/havelib/rpathx/configure.ac $(srcdir)/havelib/rpathx/aclocal.m4 + cd $(srcdir)/havelib/rpathx && $(AUTOCONF) + +$(srcdir)/havelib/rpathy/Makefile.in: $(srcdir)/havelib/rpathy/Makefile.am $(srcdir)/havelib/rpathy/configure.ac $(srcdir)/havelib/rpathy/aclocal.m4 + cd $(srcdir)/havelib/rpathy && $(AUTOMAKE) Makefile +$(srcdir)/havelib/rpathy/aclocal.m4: $(srcdir)/havelib/rpathy/configure.ac $(top_srcdir)/@HAVELIB_M4_BASE@/lib-link.m4 $(top_srcdir)/@HAVELIB_M4_BASE@/lib-prefix.m4 $(top_srcdir)/@HAVELIB_M4_BASE@/lib-ld.m4 + cd $(srcdir)/havelib/rpathy && $(LIBTOOLIZE) --copy + abs_m4_dir=`cd $(top_srcdir)/@HAVELIB_M4_BASE@ && pwd`; cd $(srcdir)/havelib/rpathy && $(ACLOCAL) -I "$$abs_m4_dir" -I `cd ../ltm4 && pwd` +$(srcdir)/havelib/rpathy/configure: $(srcdir)/havelib/rpathy/configure.ac $(srcdir)/havelib/rpathy/aclocal.m4 + cd $(srcdir)/havelib/rpathy && $(AUTOCONF) + +$(srcdir)/havelib/rpathz/Makefile.in: $(srcdir)/havelib/rpathz/Makefile.am $(srcdir)/havelib/rpathz/configure.ac $(srcdir)/havelib/rpathz/aclocal.m4 + cd $(srcdir)/havelib/rpathz && $(AUTOMAKE) Makefile +$(srcdir)/havelib/rpathz/aclocal.m4: $(srcdir)/havelib/rpathz/configure.ac $(top_srcdir)/@HAVELIB_M4_BASE@/lib-link.m4 $(top_srcdir)/@HAVELIB_M4_BASE@/lib-prefix.m4 $(top_srcdir)/@HAVELIB_M4_BASE@/lib-ld.m4 + cd $(srcdir)/havelib/rpathz && $(LIBTOOLIZE) --copy + abs_m4_dir=`cd $(top_srcdir)/@HAVELIB_M4_BASE@ && pwd`; cd $(srcdir)/havelib/rpathz && $(ACLOCAL) -I "$$abs_m4_dir" -I `cd ../ltm4 && pwd` +$(srcdir)/havelib/rpathz/configure: $(srcdir)/havelib/rpathz/configure.ac $(srcdir)/havelib/rpathz/aclocal.m4 + cd $(srcdir)/havelib/rpathz && $(AUTOCONF) + +$(srcdir)/havelib/rpathlx/Makefile.in: $(srcdir)/havelib/rpathlx/Makefile.am $(srcdir)/havelib/rpathlx/configure.ac $(srcdir)/havelib/rpathlx/aclocal.m4 + cd $(srcdir)/havelib/rpathlx && $(AUTOMAKE) Makefile +$(srcdir)/havelib/rpathlx/aclocal.m4: $(srcdir)/havelib/rpathlx/configure.ac $(top_srcdir)/@HAVELIB_M4_BASE@/lib-link.m4 $(top_srcdir)/@HAVELIB_M4_BASE@/lib-prefix.m4 $(top_srcdir)/@HAVELIB_M4_BASE@/lib-ld.m4 + abs_m4_dir=`cd $(top_srcdir)/@HAVELIB_M4_BASE@ && pwd`; cd $(srcdir)/havelib/rpathlx && $(ACLOCAL) -I "$$abs_m4_dir" +$(srcdir)/havelib/rpathlx/configure: $(srcdir)/havelib/rpathlx/configure.ac $(srcdir)/havelib/rpathlx/aclocal.m4 + cd $(srcdir)/havelib/rpathlx && $(AUTOCONF) + +$(srcdir)/havelib/rpathly/Makefile.in: $(srcdir)/havelib/rpathly/Makefile.am $(srcdir)/havelib/rpathly/configure.ac $(srcdir)/havelib/rpathly/aclocal.m4 + cd $(srcdir)/havelib/rpathly && $(AUTOMAKE) Makefile +$(srcdir)/havelib/rpathly/aclocal.m4: $(srcdir)/havelib/rpathly/configure.ac $(top_srcdir)/@HAVELIB_M4_BASE@/lib-link.m4 $(top_srcdir)/@HAVELIB_M4_BASE@/lib-prefix.m4 $(top_srcdir)/@HAVELIB_M4_BASE@/lib-ld.m4 + abs_m4_dir=`cd $(top_srcdir)/@HAVELIB_M4_BASE@ && pwd`; cd $(srcdir)/havelib/rpathly && $(ACLOCAL) -I "$$abs_m4_dir" +$(srcdir)/havelib/rpathly/configure: $(srcdir)/havelib/rpathly/configure.ac $(srcdir)/havelib/rpathly/aclocal.m4 + cd $(srcdir)/havelib/rpathly && $(AUTOCONF) + +$(srcdir)/havelib/rpathlyx/Makefile.in: $(srcdir)/havelib/rpathlyx/Makefile.am $(srcdir)/havelib/rpathlyx/configure.ac $(srcdir)/havelib/rpathlyx/aclocal.m4 + cd $(srcdir)/havelib/rpathlyx && $(AUTOMAKE) Makefile +$(srcdir)/havelib/rpathlyx/aclocal.m4: $(srcdir)/havelib/rpathlyx/configure.ac $(top_srcdir)/@HAVELIB_M4_BASE@/lib-link.m4 $(top_srcdir)/@HAVELIB_M4_BASE@/lib-prefix.m4 $(top_srcdir)/@HAVELIB_M4_BASE@/lib-ld.m4 + abs_m4_dir=`cd $(top_srcdir)/@HAVELIB_M4_BASE@ && pwd`; cd $(srcdir)/havelib/rpathlyx && $(ACLOCAL) -I "$$abs_m4_dir" +$(srcdir)/havelib/rpathlyx/configure: $(srcdir)/havelib/rpathlyx/configure.ac $(srcdir)/havelib/rpathlyx/aclocal.m4 + cd $(srcdir)/havelib/rpathlyx && $(AUTOCONF) + +$(srcdir)/havelib/rpathlz/Makefile.in: $(srcdir)/havelib/rpathlz/Makefile.am $(srcdir)/havelib/rpathlz/configure.ac $(srcdir)/havelib/rpathlz/aclocal.m4 + cd $(srcdir)/havelib/rpathlz && $(AUTOMAKE) Makefile +$(srcdir)/havelib/rpathlz/aclocal.m4: $(srcdir)/havelib/rpathlz/configure.ac $(top_srcdir)/@HAVELIB_M4_BASE@/lib-link.m4 $(top_srcdir)/@HAVELIB_M4_BASE@/lib-prefix.m4 $(top_srcdir)/@HAVELIB_M4_BASE@/lib-ld.m4 + abs_m4_dir=`cd $(top_srcdir)/@HAVELIB_M4_BASE@ && pwd`; cd $(srcdir)/havelib/rpathlz && $(ACLOCAL) -I "$$abs_m4_dir" +$(srcdir)/havelib/rpathlz/configure: $(srcdir)/havelib/rpathlz/configure.ac $(srcdir)/havelib/rpathlz/aclocal.m4 + cd $(srcdir)/havelib/rpathlz && $(AUTOCONF) + +$(srcdir)/havelib/rpathlzyx/Makefile.in: $(srcdir)/havelib/rpathlzyx/Makefile.am $(srcdir)/havelib/rpathlzyx/configure.ac $(srcdir)/havelib/rpathlzyx/aclocal.m4 + cd $(srcdir)/havelib/rpathlzyx && $(AUTOMAKE) Makefile +$(srcdir)/havelib/rpathlzyx/aclocal.m4: $(srcdir)/havelib/rpathlzyx/configure.ac $(top_srcdir)/@HAVELIB_M4_BASE@/lib-link.m4 $(top_srcdir)/@HAVELIB_M4_BASE@/lib-prefix.m4 $(top_srcdir)/@HAVELIB_M4_BASE@/lib-ld.m4 + abs_m4_dir=`cd $(top_srcdir)/@HAVELIB_M4_BASE@ && pwd`; cd $(srcdir)/havelib/rpathlzyx && $(ACLOCAL) -I "$$abs_m4_dir" +$(srcdir)/havelib/rpathlzyx/configure: $(srcdir)/havelib/rpathlzyx/configure.ac $(srcdir)/havelib/rpathlzyx/aclocal.m4 + cd $(srcdir)/havelib/rpathlzyx && $(AUTOCONF) + +MAINTAINERCLEANFILES += $(HAVELIB_GENERATED_FILES) +EXTRA_DIST += $(HAVELIB_GENERATED_FILES) + +# Libtool's infrastructure is installed in +# - $(top_srcdir)/build-aux/ltmain.sh, which gets distributed, +# - $(srcdir)/havelib/ltm4/*.m4, which don't need to be distributed, because +# they are included in each havelib/rpath*/aclocal.m4 file. + +EXTRA_DIST += $(top_srcdir)/build-aux/ltmain.sh + +mostlyclean-local: mostlyclean-local-havelib + +mostlyclean-local-havelib: + rm -rf $(srcdir)/havelib/ltm4 + + +# The AC_CONFIG_AUX_DIR argument in the havelib/rpath*/configure.ac files is +# interpreted in two different contexts: +# 1. at "make distrib" time, when we call automake, relative to +# SRCDIR/havelib/rpath*/, +# 2. at "make check" time, when the directory is copied and configured, +# relative to BUILDDIR/havelib/tst/dir/rp-*/. +# We choose this argument to be '../../../build-aux', for case 1, and therefore +# we need to make a local copy of the build-aux directory, for case 2. + +HAVELIB_COPIED_FILES = \ + havelib/build-aux/config.guess \ + havelib/build-aux/config.sub \ + havelib/build-aux/install-sh \ + havelib/build-aux/ltmain.sh \ + havelib/build-aux/missing \ + havelib/build-aux/config.rpath + +all-local: $(HAVELIB_COPIED_FILES) + +havelib/build-aux-dir: + test -d havelib/build-aux || mkdir havelib/build-aux + touch havelib/build-aux-dir + +havelib/build-aux/config.guess: $(top_srcdir)/build-aux/config.guess havelib/build-aux-dir + cp $(top_srcdir)/build-aux/config.guess havelib/build-aux/config.guess + +havelib/build-aux/config.sub: $(top_srcdir)/build-aux/config.sub havelib/build-aux-dir + cp $(top_srcdir)/build-aux/config.sub havelib/build-aux/config.sub + +havelib/build-aux/install-sh: $(top_srcdir)/build-aux/install-sh havelib/build-aux-dir + cp $(top_srcdir)/build-aux/install-sh havelib/build-aux/install-sh + +havelib/build-aux/ltmain.sh: $(top_srcdir)/build-aux/ltmain.sh havelib/build-aux-dir + cp $(top_srcdir)/build-aux/ltmain.sh havelib/build-aux/ltmain.sh + +havelib/build-aux/missing: $(top_srcdir)/build-aux/missing havelib/build-aux-dir + cp $(top_srcdir)/build-aux/missing havelib/build-aux/missing + +havelib/build-aux/config.rpath: $(top_srcdir)/build-aux/config.rpath havelib/build-aux-dir + cp $(top_srcdir)/build-aux/config.rpath havelib/build-aux/config.rpath + +DISTCLEANFILES += $(HAVELIB_COPIED_FILES) + +distclean-local: distclean-local-havelib + +distclean-local-havelib: + rm -rf havelib/build-aux havelib/build-aux-dir +.PHONY: distclean-local-havelib diff --git a/tests/havelib/Makefile.am b/tests/havelib/Makefile.am new file mode 100644 index 000000000..57dcbf357 --- /dev/null +++ b/tests/havelib/Makefile.am @@ -0,0 +1,79 @@ +## Makefile for the autoconf-lib-link/tests subdirectory of GNU gettext +## Copyright (C) 1995-1997, 2001-2003, 2006, 2009-2010 Free Software Foundation, Inc. +## +## This program is free software: you can redistribute it and/or modify +## it under the terms of the GNU General Public License as published by +## the Free Software Foundation; either version 3 of the License, or +## (at your option) any later version. +## +## This program is distributed in the hope that it will be useful, +## but WITHOUT ANY WARRANTY; without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +## GNU General Public License for more details. +## +## You should have received a copy of the GNU General Public License +## along with this program. If not, see . + +## Process this file with automake to produce Makefile.in. + +AUTOMAKE_OPTIONS = 1.11 gnits no-dependencies color-tests +MOSTLYCLEANFILES = + +TESTS = rpath-1a rpath-1b \ + rpath-2aaa rpath-2aab rpath-2aad \ + rpath-2aba rpath-2abb rpath-2abd \ + rpath-2baa rpath-2bab rpath-2bad \ + rpath-2bba rpath-2bbb rpath-2bbd \ + rpath-3aaa rpath-3aab rpath-3aad \ + rpath-3aah \ + rpath-3aba rpath-3abb rpath-3abd \ + rpath-3abh \ + rpath-3baa rpath-3bab rpath-3bad \ + rpath-3bah \ + rpath-3bba rpath-3bbb rpath-3bbd \ + rpath-3bbh + +EXTRA_DIST = $(TESTS) \ + rpathx/configure.ac rpathx/aclocal.m4 rpathx/configure \ + rpathx/Makefile.am rpathx/Makefile.in rpathx/rpathx.c \ + rpathy/configure.ac rpathy/aclocal.m4 rpathy/configure \ + rpathy/Makefile.am rpathy/Makefile.in rpathy/rpathy.c \ + rpathz/configure.ac rpathz/aclocal.m4 rpathz/configure \ + rpathz/Makefile.am rpathz/Makefile.in rpathz/rpathz.c \ + rpathlx/configure.ac rpathlx/aclocal.m4 rpathlx/configure \ + rpathlx/Makefile.am rpathlx/Makefile.in rpathlx/usex.c \ + rpathly/configure.ac rpathly/aclocal.m4 rpathly/configure \ + rpathly/Makefile.am rpathly/Makefile.in rpathly/usey.c \ + rpathlyx/configure.ac rpathlyx/aclocal.m4 rpathlyx/configure \ + rpathlyx/Makefile.am rpathlyx/Makefile.in rpathlyx/usey.c \ + rpathlz/configure.ac rpathlz/aclocal.m4 rpathlz/configure \ + rpathlz/Makefile.am rpathlz/Makefile.in rpathlz/usez.c \ + rpathlzyx/configure.ac rpathlzyx/aclocal.m4 rpathlzyx/configure \ + rpathlzyx/Makefile.am rpathlzyx/Makefile.in rpathlzyx/usez.c \ + rpath-1 rpath-2_a rpath-2_b rpath-3_a rpath-3_b README \ + rpath-3aae rpath-3aag rpath-3abe rpath-3abg \ + rpathcfg.sh + +TESTS_ENVIRONMENT = top_srcdir=$(srcdir)/../.. srcdir=$(srcdir) \ + OBJEXT='@OBJEXT@' EXEEXT='@EXEEXT@' \ + LIBTOOL='@LIBTOOL@' \ + CC='@CC@' CFLAGS='@CFLAGS@' \ + CPPFLAGS='@CPPFLAGS@' LDFLAGS='@LDFLAGS@' \ + LIBDIRSTEM='@LIBDIRSTEM@' \ + CONFIG_SHELL='$(SHELL)' \ + $(SHELL) + +# Help maintaining config.rpath. +rpathcfg: rpathcfg.sh + top_srcdir=$(srcdir)/../.. srcdir=$(srcdir) \ + CONFIG_SHELL='$(SHELL)' \ + CC='@CC@' GCC='@GCC@' \ + LDFLAGS='@LDFLAGS@' \ + LD='@LD@' with_gnu_ld='@with_gnu_ld@' \ + host='@host@' \ + $(SHELL) $(srcdir)/rpathcfg.sh > rpathcfg 2> rpathcfg.log +MOSTLYCLEANFILES += rpathcfg rpathcfg.log + +# Clean up the intermediate directory created by running the tests. +distclean-local: + rm -rf ../havelib-tstdir diff --git a/tests/havelib/README b/tests/havelib/README new file mode 100644 index 000000000..add09ad8a --- /dev/null +++ b/tests/havelib/README @@ -0,0 +1,77 @@ +Tests for config.rpath and lib-link.m4. + +rpath-1 w + | + +---- a = static, b = shared + +rpath-2 u v w + | | | + | | +---- a = static/static, b = static/shared, + | | c = shared/static, d = shared/shared. + | | + | +------ a = all libraries and the program have the same prefix, + | b = the libraries are in different directories. + | + +-------- a = all shared libraries use the libtool *.la files for + resolving dependencies, b = dependencies are given as + AC_LIB_LINKFLAGS argument instead. + +rpath-3 u v w + | | | + | | +---- a = static/static/static, b = static/static/shared, + | | c = static/shared/static, d = static/shared/shared, + | | e = shared/static/static, f = shared/static/shared, + | | g = shared/shared/static, h = shared/shared/shared. + | | + | +------ a = all libraries and the program have the same prefix, + | b = the libraries are in different directories. + | + +-------- a = all shared libraries use the libtool *.la files for + resolving dependencies, b = dependencies are given as + AC_LIB_LINKFLAGS argument instead. + +The rpath-2* tests are sensitive to + - incomplete shared library support in the system, + - bugs in libtool that creates the shared libraries, + - bugs in lib-link.m4. + +The rpath-3* tests are sensitive to + - incomplete shared library support in the system, + - bugs in libtool that creates the shared libraries. + +Known failures: + +* On all platforms supporting shared libraries, + rpath-3aae rpath-3aag + rpath-3abe rpath-3abg + fail. This is a libtool 1.4.2 bug: When a shared library depends on a + static library indirectly through two different dependency paths, + libtool attempts to link together invalid sets of object files. + +* OSF/1 4.0: the tests + rpath-2bbd + rpath-3bbd rpath-3bbf rpath-3bbg rpath-3bbh + fail, because -rpath options are not cumulative: + The last -rpath option overrides all previous ones. One would need to + pass all directories, separated by colons, in a single -rpath option. + +* On Linux/x86_64: the tests + rpath-2aac rpath-2abc rpath-2bac rpath-2bbc + rpath-3aac rpath-3aaf rpath-3abc rpath-3abf + rpath-3bac rpath-3bae rpath-3baf rpath-3bag + rpath-3bbc rpath-3bbe rpath-3bbf rpath-3bbg + fail, because code from static libraries not compiled with -fPIC cannot + be integrated into shared libraries: linker error about relocations. + +* Solaris: the tests + rpath-3bae rpath-3bbe + rpath-3aaf rpath-3abf + rpath-3baf rpath-3bbf + fail, because code from static libraries not compiled with -fPIC cannot + be integrated into shared libraries: linker error "Text relocation remains". + +* Cygwin: The tests + rpath-2aac rpath-2abc + rpath-3aac rpath-3aaf + rpath-3abc rpath-3abf + fail. diff --git a/tests/havelib/rpath-1 b/tests/havelib/rpath-1 new file mode 100644 index 000000000..2d14f0454 --- /dev/null +++ b/tests/havelib/rpath-1 @@ -0,0 +1,40 @@ +# Common portion of all rpath-1* tests. + +tmpfiles="" +trap 'rm -fr $tmpfiles' 1 2 3 15 + +builddir=`pwd` +global_top_auxdir=`cd "$top_srcdir"/build-aux && pwd` +export global_top_auxdir + +tstdir='tst/dir' +test -d $tstdir || { mkdir tst && mkdir $tstdir; } + +tmpfiles="$tmpfiles $rp-prefix" +rm -rf $rp-prefix +mkdir $rp-prefix + +tmpfiles="$tmpfiles $tstdir/$rp-build1" +rm -rf $tstdir/$rp-build1 +mkdir $tstdir/$rp-build1 +(cd $srcdir/rpathx && tar cf - *) | (cd $tstdir/$rp-build1 && tar xf -) +(cd $tstdir/$rp-build1 + ${CONFIG_SHELL-/bin/sh} ./configure $build1_configure_flags --prefix=$builddir/$rp-prefix --libdir=$builddir/$rp-prefix/$LIBDIRSTEM > configure.log 2>&1 + make > make.log 2>&1 + make install > install.log 2>&1 +) + +tmpfiles="$tmpfiles $tstdir/$rp-build2" +rm -rf $tstdir/$rp-build2 +mkdir $tstdir/$rp-build2 +(cd $srcdir/rpathlx && tar cf - *) | (cd $tstdir/$rp-build2 && tar xf -) +(cd $tstdir/$rp-build2 + ${CONFIG_SHELL-/bin/sh} ./configure --prefix=$builddir/$rp-prefix --libdir=$builddir/$rp-prefix/$LIBDIRSTEM > configure.log 2>&1 + make > make.log 2>&1 + make check >> make.log +) +result=$? + +rm -rf $tmpfiles + +exit $result diff --git a/tests/havelib/rpath-1a b/tests/havelib/rpath-1a new file mode 100755 index 000000000..413a48c68 --- /dev/null +++ b/tests/havelib/rpath-1a @@ -0,0 +1,9 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# Simple case: a static library. + +rp=rp1a +build1_configure_flags=--disable-shared + +. $srcdir/rpath-1 diff --git a/tests/havelib/rpath-1b b/tests/havelib/rpath-1b new file mode 100755 index 000000000..3170d81a4 --- /dev/null +++ b/tests/havelib/rpath-1b @@ -0,0 +1,9 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# Simple case: a shared library. + +rp=rp1b +build1_configure_flags= + +. $srcdir/rpath-1 diff --git a/tests/havelib/rpath-2_a b/tests/havelib/rpath-2_a new file mode 100644 index 000000000..3570e4444 --- /dev/null +++ b/tests/havelib/rpath-2_a @@ -0,0 +1,56 @@ +# Common portion of all rpath-2?a? tests. + +tmpfiles="" +trap 'rm -fr $tmpfiles' 1 2 3 15 + +builddir=`pwd` +global_top_auxdir=`cd "$top_srcdir"/build-aux && pwd` +export global_top_auxdir + +tstdir='tst/dir' +test -d $tstdir || { mkdir tst && mkdir $tstdir; } + +tmpfiles="$tmpfiles $rp-prefix" +rm -rf $rp-prefix +mkdir $rp-prefix + +tmpfiles="$tmpfiles $tstdir/$rp-build1" +rm -rf $tstdir/$rp-build1 +mkdir $tstdir/$rp-build1 +(cd $srcdir/rpathx && tar cf - *) | (cd $tstdir/$rp-build1 && tar xf -) +(cd $tstdir/$rp-build1 + ${CONFIG_SHELL-/bin/sh} ./configure $build1_configure_flags --prefix=$builddir/$rp-prefix --libdir=$builddir/$rp-prefix/$LIBDIRSTEM > configure.log 2>&1 + make > make.log 2>&1 + make install > install.log 2>&1 +) +if test $remove_la = yes; then + rm -f $rp-prefix/lib/librpathx.la +fi + +tmpfiles="$tmpfiles $tstdir/$rp-build2" +rm -rf $tstdir/$rp-build2 +mkdir $tstdir/$rp-build2 +(cd $srcdir/rpathy && tar cf - *) | (cd $tstdir/$rp-build2 && tar xf -) +(cd $tstdir/$rp-build2 + ${CONFIG_SHELL-/bin/sh} ./configure $build2_configure_flags --prefix=$builddir/$rp-prefix --libdir=$builddir/$rp-prefix/$LIBDIRSTEM > configure.log 2>&1 + make > make.log 2>&1 + make install > install.log 2>&1 +) +if test $remove_la = yes; then + rm -f $rp-prefix/lib/librpathy.la +fi + +tmpfiles="$tmpfiles $tstdir/$rp-build3" +rm -rf $tstdir/$rp-build3 +mkdir $tstdir/$rp-build3 +(cd $srcdir/$build3_package && tar cf - *) | (cd $tstdir/$rp-build3 && tar xf -) +(cd $tstdir/$rp-build3 + ${CONFIG_SHELL-/bin/sh} ./configure --prefix=$builddir/$rp-prefix --libdir=$builddir/$rp-prefix/$LIBDIRSTEM > configure.log 2>&1 + make > make.log 2>&1 + make check >> make.log +) +result=$? + +rm -rf $tmpfiles + +exit $result diff --git a/tests/havelib/rpath-2_b b/tests/havelib/rpath-2_b new file mode 100644 index 000000000..e851d0190 --- /dev/null +++ b/tests/havelib/rpath-2_b @@ -0,0 +1,69 @@ +# Common portion of all rpath-2?b? tests. + +tmpfiles="" +trap 'rm -fr $tmpfiles' 1 2 3 15 + +builddir=`pwd` +global_top_auxdir=`cd "$top_srcdir"/build-aux && pwd` +export global_top_auxdir + +tstdir='tst/dir' +test -d $tstdir || { mkdir tst && mkdir $tstdir; } + +tmpfiles="$tmpfiles $rp-prefix1" +rm -rf $rp-prefix1 +mkdir $rp-prefix1 + +tmpfiles="$tmpfiles $rp-prefix2" +rm -rf $rp-prefix2 +mkdir $rp-prefix2 + +tmpfiles="$tmpfiles $rp-prefix" +rm -rf $rp-prefix +mkdir $rp-prefix + +tmpfiles="$tmpfiles $tstdir/$rp-build1" +rm -rf $tstdir/$rp-build1 +mkdir $tstdir/$rp-build1 +(cd $srcdir/rpathx && tar cf - *) | (cd $tstdir/$rp-build1 && tar xf -) +(cd $tstdir/$rp-build1 + ${CONFIG_SHELL-/bin/sh} ./configure $build1_configure_flags --prefix=$builddir/$rp-prefix1 --libdir=$builddir/$rp-prefix1/$LIBDIRSTEM > configure.log 2>&1 + make > make.log 2>&1 + make install > install.log 2>&1 +) +if test $remove_la = yes; then + rm -f $rp-prefix1/lib/librpathx.la +fi + +tmpfiles="$tmpfiles $tstdir/$rp-build2" +rm -rf $tstdir/$rp-build2 +mkdir $tstdir/$rp-build2 +(cd $srcdir/rpathy && tar cf - *) | (cd $tstdir/$rp-build2 && tar xf -) +(cd $tstdir/$rp-build2 + ${CONFIG_SHELL-/bin/sh} ./configure $build2_configure_flags --prefix=$builddir/$rp-prefix2 --libdir=$builddir/$rp-prefix2/$LIBDIRSTEM --with-librpathx-prefix=$builddir/$rp-prefix1 > configure.log 2>&1 + make > make.log 2>&1 + make install > install.log 2>&1 +) +if test $remove_la = yes; then + rm -f $rp-prefix2/lib/librpathy.la +fi + +tmpfiles="$tmpfiles $tstdir/$rp-build3" +rm -rf $tstdir/$rp-build3 +mkdir $tstdir/$rp-build3 +(cd $srcdir/$build3_package && tar cf - *) | (cd $tstdir/$rp-build3 && tar xf -) +(cd $tstdir/$rp-build3 + if test $remove_la = yes; then + build3_configure_flags=--with-librpathx-prefix=$builddir/$rp-prefix1 + else + build3_configure_flags= + fi + ${CONFIG_SHELL-/bin/sh} ./configure --prefix=$builddir/$rp-prefix --libdir=$builddir/$rp-prefix/$LIBDIRSTEM --with-librpathy-prefix=$builddir/$rp-prefix2 $build3_configure_flags > configure.log 2>&1 + make > make.log 2>&1 + make check >> make.log +) +result=$? + +rm -rf $tmpfiles + +exit $result diff --git a/tests/havelib/rpath-2aaa b/tests/havelib/rpath-2aaa new file mode 100755 index 000000000..02b0bdda5 --- /dev/null +++ b/tests/havelib/rpath-2aaa @@ -0,0 +1,12 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a static library. + +rp=rp2aaa +build1_configure_flags=--disable-shared +build2_configure_flags=--disable-shared +build3_package=rpathly +remove_la=no + +. $srcdir/rpath-2_a diff --git a/tests/havelib/rpath-2aab b/tests/havelib/rpath-2aab new file mode 100755 index 000000000..a8e8760be --- /dev/null +++ b/tests/havelib/rpath-2aab @@ -0,0 +1,12 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a shared library. + +rp=rp2aab +build1_configure_flags= +build2_configure_flags=--disable-shared +build3_package=rpathly +remove_la=no + +. $srcdir/rpath-2_a diff --git a/tests/havelib/rpath-2aac b/tests/havelib/rpath-2aac new file mode 100755 index 000000000..9bf805e1c --- /dev/null +++ b/tests/havelib/rpath-2aac @@ -0,0 +1,12 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a static library. + +rp=rp2aac +build1_configure_flags=--disable-shared +build2_configure_flags= +build3_package=rpathly +remove_la=no + +. $srcdir/rpath-2_a diff --git a/tests/havelib/rpath-2aad b/tests/havelib/rpath-2aad new file mode 100755 index 000000000..17ac5d6e6 --- /dev/null +++ b/tests/havelib/rpath-2aad @@ -0,0 +1,12 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a shared library. + +rp=rp2aad +build1_configure_flags= +build2_configure_flags= +build3_package=rpathly +remove_la=no + +. $srcdir/rpath-2_a diff --git a/tests/havelib/rpath-2aba b/tests/havelib/rpath-2aba new file mode 100755 index 000000000..507e7de73 --- /dev/null +++ b/tests/havelib/rpath-2aba @@ -0,0 +1,13 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a static library. +# Each library installed with a different prefix. + +rp=rp2aba +build1_configure_flags=--disable-shared +build2_configure_flags=--disable-shared +build3_package=rpathly +remove_la=no + +. $srcdir/rpath-2_b diff --git a/tests/havelib/rpath-2abb b/tests/havelib/rpath-2abb new file mode 100755 index 000000000..95ce66e0e --- /dev/null +++ b/tests/havelib/rpath-2abb @@ -0,0 +1,13 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a shared library. +# Each library installed with a different prefix. + +rp=rp2abb +build1_configure_flags= +build2_configure_flags=--disable-shared +build3_package=rpathly +remove_la=no + +. $srcdir/rpath-2_b diff --git a/tests/havelib/rpath-2abc b/tests/havelib/rpath-2abc new file mode 100755 index 000000000..39b39fc7d --- /dev/null +++ b/tests/havelib/rpath-2abc @@ -0,0 +1,13 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a static library. +# Each library installed with a different prefix. + +rp=rp2abc +build1_configure_flags=--disable-shared +build2_configure_flags= +build3_package=rpathly +remove_la=no + +. $srcdir/rpath-2_b diff --git a/tests/havelib/rpath-2abd b/tests/havelib/rpath-2abd new file mode 100755 index 000000000..7182fb364 --- /dev/null +++ b/tests/havelib/rpath-2abd @@ -0,0 +1,13 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a shared library. +# Each library installed with a different prefix. + +rp=rp2abd +build1_configure_flags= +build2_configure_flags= +build3_package=rpathly +remove_la=no + +. $srcdir/rpath-2_b diff --git a/tests/havelib/rpath-2baa b/tests/havelib/rpath-2baa new file mode 100755 index 000000000..916c6fdad --- /dev/null +++ b/tests/havelib/rpath-2baa @@ -0,0 +1,14 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a static library. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. + +rp=rp2baa +build1_configure_flags=--disable-shared +build2_configure_flags=--disable-shared +build3_package=rpathlyx +remove_la=yes + +. $srcdir/rpath-2_a diff --git a/tests/havelib/rpath-2bab b/tests/havelib/rpath-2bab new file mode 100755 index 000000000..00b35aa8d --- /dev/null +++ b/tests/havelib/rpath-2bab @@ -0,0 +1,14 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a shared library. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. + +rp=rp2bab +build1_configure_flags= +build2_configure_flags=--disable-shared +build3_package=rpathlyx +remove_la=yes + +. $srcdir/rpath-2_a diff --git a/tests/havelib/rpath-2bac b/tests/havelib/rpath-2bac new file mode 100755 index 000000000..ba379b998 --- /dev/null +++ b/tests/havelib/rpath-2bac @@ -0,0 +1,14 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a static library. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. + +rp=rp2bac +build1_configure_flags=--disable-shared +build2_configure_flags= +build3_package=rpathlyx +remove_la=yes + +. $srcdir/rpath-2_a diff --git a/tests/havelib/rpath-2bad b/tests/havelib/rpath-2bad new file mode 100755 index 000000000..0dabed0d3 --- /dev/null +++ b/tests/havelib/rpath-2bad @@ -0,0 +1,14 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a shared library. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. + +rp=rp2bad +build1_configure_flags= +build2_configure_flags= +build3_package=rpathlyx +remove_la=yes + +. $srcdir/rpath-2_a diff --git a/tests/havelib/rpath-2bba b/tests/havelib/rpath-2bba new file mode 100755 index 000000000..64f8a648e --- /dev/null +++ b/tests/havelib/rpath-2bba @@ -0,0 +1,15 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a static library. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. +# Each library installed with a different prefix. + +rp=rp2bba +build1_configure_flags=--disable-shared +build2_configure_flags=--disable-shared +build3_package=rpathlyx +remove_la=yes + +. $srcdir/rpath-2_b diff --git a/tests/havelib/rpath-2bbb b/tests/havelib/rpath-2bbb new file mode 100755 index 000000000..259104771 --- /dev/null +++ b/tests/havelib/rpath-2bbb @@ -0,0 +1,15 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a shared library. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. +# Each library installed with a different prefix. + +rp=rp2bbb +build1_configure_flags= +build2_configure_flags=--disable-shared +build3_package=rpathlyx +remove_la=yes + +. $srcdir/rpath-2_b diff --git a/tests/havelib/rpath-2bbc b/tests/havelib/rpath-2bbc new file mode 100755 index 000000000..0423d3ef5 --- /dev/null +++ b/tests/havelib/rpath-2bbc @@ -0,0 +1,15 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a static library. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. +# Each library installed with a different prefix. + +rp=rp2bbc +build1_configure_flags=--disable-shared +build2_configure_flags= +build3_package=rpathlyx +remove_la=yes + +. $srcdir/rpath-2_b diff --git a/tests/havelib/rpath-2bbd b/tests/havelib/rpath-2bbd new file mode 100755 index 000000000..921d01470 --- /dev/null +++ b/tests/havelib/rpath-2bbd @@ -0,0 +1,15 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a shared library. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. +# Each library installed with a different prefix. + +rp=rp2bbd +build1_configure_flags= +build2_configure_flags= +build3_package=rpathlyx +remove_la=yes + +. $srcdir/rpath-2_b diff --git a/tests/havelib/rpath-3_a b/tests/havelib/rpath-3_a new file mode 100644 index 000000000..6ccc3f868 --- /dev/null +++ b/tests/havelib/rpath-3_a @@ -0,0 +1,69 @@ +# Common portion of all rpath-3?a? tests. + +tmpfiles="" +trap 'rm -fr $tmpfiles' 1 2 3 15 + +builddir=`pwd` +global_top_auxdir=`cd "$top_srcdir"/build-aux && pwd` +export global_top_auxdir + +tstdir='tst/dir' +test -d $tstdir || { mkdir tst && mkdir $tstdir; } + +tmpfiles="$tmpfiles $rp-prefix" +rm -rf $rp-prefix +mkdir $rp-prefix + +tmpfiles="$tmpfiles $tstdir/$rp-build1" +rm -rf $tstdir/$rp-build1 +mkdir $tstdir/$rp-build1 +(cd $srcdir/rpathx && tar cf - *) | (cd $tstdir/$rp-build1 && tar xf -) +(cd $tstdir/$rp-build1 + ${CONFIG_SHELL-/bin/sh} ./configure $build1_configure_flags --prefix=$builddir/$rp-prefix --libdir=$builddir/$rp-prefix/$LIBDIRSTEM > configure.log 2>&1 + make > make.log 2>&1 + make install > install.log 2>&1 +) +if test $remove_la = yes; then + rm -f $rp-prefix/lib/librpathx.la +fi + +tmpfiles="$tmpfiles $tstdir/$rp-build2" +rm -rf $tstdir/$rp-build2 +mkdir $tstdir/$rp-build2 +(cd $srcdir/rpathy && tar cf - *) | (cd $tstdir/$rp-build2 && tar xf -) +(cd $tstdir/$rp-build2 + ${CONFIG_SHELL-/bin/sh} ./configure $build2_configure_flags --prefix=$builddir/$rp-prefix --libdir=$builddir/$rp-prefix/$LIBDIRSTEM > configure.log 2>&1 + make > make.log 2>&1 + make install > install.log 2>&1 +) +if test $remove_la = yes; then + rm -f $rp-prefix/lib/librpathy.la +fi + +tmpfiles="$tmpfiles $tstdir/$rp-build3" +rm -rf $tstdir/$rp-build3 +mkdir $tstdir/$rp-build3 +(cd $srcdir/rpathz && tar cf - *) | (cd $tstdir/$rp-build3 && tar xf -) +(cd $tstdir/$rp-build3 + ${CONFIG_SHELL-/bin/sh} ./configure $build3_configure_flags --prefix=$builddir/$rp-prefix --libdir=$builddir/$rp-prefix/$LIBDIRSTEM > configure.log 2>&1 + make > make.log 2>&1 + make install > install.log 2>&1 +) +if test $remove_la = yes; then + rm -f $rp-prefix/lib/librpathz.la +fi + +tmpfiles="$tmpfiles $tstdir/$rp-build4" +rm -rf $tstdir/$rp-build4 +mkdir $tstdir/$rp-build4 +(cd $srcdir/$build4_package && tar cf - *) | (cd $tstdir/$rp-build4 && tar xf -) +(cd $tstdir/$rp-build4 + ${CONFIG_SHELL-/bin/sh} ./configure --prefix=$builddir/$rp-prefix --libdir=$builddir/$rp-prefix/$LIBDIRSTEM > configure.log 2>&1 + make > make.log 2>&1 + make check >> make.log +) +result=$? + +rm -rf $tmpfiles + +exit $result diff --git a/tests/havelib/rpath-3_b b/tests/havelib/rpath-3_b new file mode 100644 index 000000000..71b421288 --- /dev/null +++ b/tests/havelib/rpath-3_b @@ -0,0 +1,86 @@ +# Common portion of all rpath-3?b? tests. + +tmpfiles="" +trap 'rm -fr $tmpfiles' 1 2 3 15 + +builddir=`pwd` +global_top_auxdir=`cd "$top_srcdir"/build-aux && pwd` +export global_top_auxdir + +tstdir='tst/dir' +test -d $tstdir || { mkdir tst && mkdir $tstdir; } + +tmpfiles="$tmpfiles $rp-prefix1" +rm -rf $rp-prefix1 +mkdir $rp-prefix1 + +tmpfiles="$tmpfiles $rp-prefix2" +rm -rf $rp-prefix2 +mkdir $rp-prefix2 + +tmpfiles="$tmpfiles $rp-prefix3" +rm -rf $rp-prefix3 +mkdir $rp-prefix3 + +tmpfiles="$tmpfiles $rp-prefix" +rm -rf $rp-prefix +mkdir $rp-prefix + +tmpfiles="$tmpfiles $tstdir/$rp-build1" +rm -rf $tstdir/$rp-build1 +mkdir $tstdir/$rp-build1 +(cd $srcdir/rpathx && tar cf - *) | (cd $tstdir/$rp-build1 && tar xf -) +(cd $tstdir/$rp-build1 + ${CONFIG_SHELL-/bin/sh} ./configure $build1_configure_flags --prefix=$builddir/$rp-prefix1 --libdir=$builddir/$rp-prefix1/$LIBDIRSTEM > configure.log 2>&1 + make > make.log 2>&1 + make install > install.log 2>&1 +) +if test $remove_la = yes; then + rm -f $rp-prefix1/lib/librpathx.la +fi + +tmpfiles="$tmpfiles $tstdir/$rp-build2" +rm -rf $tstdir/$rp-build2 +mkdir $tstdir/$rp-build2 +(cd $srcdir/rpathy && tar cf - *) | (cd $tstdir/$rp-build2 && tar xf -) +(cd $tstdir/$rp-build2 + ${CONFIG_SHELL-/bin/sh} ./configure $build2_configure_flags --prefix=$builddir/$rp-prefix2 --libdir=$builddir/$rp-prefix2/$LIBDIRSTEM --with-librpathx-prefix=$builddir/$rp-prefix1 > configure.log 2>&1 + make > make.log 2>&1 + make install > install.log 2>&1 +) +if test $remove_la = yes; then + rm -f $rp-prefix2/lib/librpathy.la +fi + +tmpfiles="$tmpfiles $tstdir/$rp-build3" +rm -rf $tstdir/$rp-build3 +mkdir $tstdir/$rp-build3 +(cd $srcdir/rpathz && tar cf - *) | (cd $tstdir/$rp-build3 && tar xf -) +(cd $tstdir/$rp-build3 + ${CONFIG_SHELL-/bin/sh} ./configure $build3_configure_flags --prefix=$builddir/$rp-prefix3 --libdir=$builddir/$rp-prefix3/$LIBDIRSTEM --with-librpathx-prefix=$builddir/$rp-prefix1 --with-librpathy-prefix=$builddir/$rp-prefix2 > configure.log 2>&1 + make > make.log 2>&1 + make install > install.log 2>&1 +) +if test $remove_la = yes; then + rm -f $rp-prefix3/lib/librpathz.la +fi + +tmpfiles="$tmpfiles $tstdir/$rp-build4" +rm -rf $tstdir/$rp-build4 +mkdir $tstdir/$rp-build4 +(cd $srcdir/$build4_package && tar cf - *) | (cd $tstdir/$rp-build4 && tar xf -) +(cd $tstdir/$rp-build4 + if test $remove_la = yes; then + build4_configure_flags="--with-librpathx-prefix=$builddir/$rp-prefix1 --with-librpathy-prefix=$builddir/$rp-prefix2" + else + build4_configure_flags= + fi + ${CONFIG_SHELL-/bin/sh} ./configure --prefix=$builddir/$rp-prefix --libdir=$builddir/$rp-prefix/$LIBDIRSTEM --with-librpathz-prefix=$builddir/$rp-prefix3 $build4_configure_flags > configure.log 2>&1 + make > make.log 2>&1 + make check >> make.log +) +result=$? + +rm -rf $tmpfiles + +exit $result diff --git a/tests/havelib/rpath-3aaa b/tests/havelib/rpath-3aaa new file mode 100755 index 000000000..f353d8071 --- /dev/null +++ b/tests/havelib/rpath-3aaa @@ -0,0 +1,14 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a static library, +# and a static library depending on both. + +rp=rp3aaa +build1_configure_flags=--disable-shared +build2_configure_flags=--disable-shared +build3_configure_flags=--disable-shared +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3aab b/tests/havelib/rpath-3aab new file mode 100755 index 000000000..93d157eaf --- /dev/null +++ b/tests/havelib/rpath-3aab @@ -0,0 +1,14 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a shared library, +# and a static library depending on both. + +rp=rp3aab +build1_configure_flags= +build2_configure_flags=--disable-shared +build3_configure_flags=--disable-shared +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3aac b/tests/havelib/rpath-3aac new file mode 100755 index 000000000..3d2d6cc4c --- /dev/null +++ b/tests/havelib/rpath-3aac @@ -0,0 +1,14 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a static library, +# and a static library depending on both. + +rp=rp3aac +build1_configure_flags=--disable-shared +build2_configure_flags= +build3_configure_flags=--disable-shared +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3aad b/tests/havelib/rpath-3aad new file mode 100755 index 000000000..3e35be000 --- /dev/null +++ b/tests/havelib/rpath-3aad @@ -0,0 +1,14 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a shared library, +# and a static library depending on both. + +rp=rp3aad +build1_configure_flags= +build2_configure_flags= +build3_configure_flags=--disable-shared +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3aae b/tests/havelib/rpath-3aae new file mode 100755 index 000000000..6bea00fa4 --- /dev/null +++ b/tests/havelib/rpath-3aae @@ -0,0 +1,14 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a static library, +# and a shared library depending on both. + +rp=rp3aae +build1_configure_flags=--disable-shared +build2_configure_flags=--disable-shared +build3_configure_flags= +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3aaf b/tests/havelib/rpath-3aaf new file mode 100755 index 000000000..102d4eb96 --- /dev/null +++ b/tests/havelib/rpath-3aaf @@ -0,0 +1,14 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a shared library, +# and a shared library depending on both. + +rp=rp3aaf +build1_configure_flags= +build2_configure_flags=--disable-shared +build3_configure_flags= +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3aag b/tests/havelib/rpath-3aag new file mode 100755 index 000000000..e7f636829 --- /dev/null +++ b/tests/havelib/rpath-3aag @@ -0,0 +1,14 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a static library, +# and a shared library depending on both. + +rp=rp3aag +build1_configure_flags=--disable-shared +build2_configure_flags= +build3_configure_flags= +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3aah b/tests/havelib/rpath-3aah new file mode 100755 index 000000000..21677ee37 --- /dev/null +++ b/tests/havelib/rpath-3aah @@ -0,0 +1,14 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a shared library, +# and a shared library depending on both. + +rp=rp3aah +build1_configure_flags= +build2_configure_flags= +build3_configure_flags= +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3aba b/tests/havelib/rpath-3aba new file mode 100755 index 000000000..020cf211d --- /dev/null +++ b/tests/havelib/rpath-3aba @@ -0,0 +1,15 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a static library, +# and a static library depending on both. +# Each library installed with a different prefix. + +rp=rp3aba +build1_configure_flags=--disable-shared +build2_configure_flags=--disable-shared +build3_configure_flags=--disable-shared +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpath-3abb b/tests/havelib/rpath-3abb new file mode 100755 index 000000000..89542f69c --- /dev/null +++ b/tests/havelib/rpath-3abb @@ -0,0 +1,15 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a shared library, +# and a static library depending on both. +# Each library installed with a different prefix. + +rp=rp3abb +build1_configure_flags= +build2_configure_flags=--disable-shared +build3_configure_flags=--disable-shared +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpath-3abc b/tests/havelib/rpath-3abc new file mode 100755 index 000000000..9fd989619 --- /dev/null +++ b/tests/havelib/rpath-3abc @@ -0,0 +1,15 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a static library, +# and a static library depending on both. +# Each library installed with a different prefix. + +rp=rp3abc +build1_configure_flags=--disable-shared +build2_configure_flags= +build3_configure_flags=--disable-shared +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpath-3abd b/tests/havelib/rpath-3abd new file mode 100755 index 000000000..ecf34b9f5 --- /dev/null +++ b/tests/havelib/rpath-3abd @@ -0,0 +1,15 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a shared library, +# and a static library depending on both. +# Each library installed with a different prefix. + +rp=rp3abd +build1_configure_flags= +build2_configure_flags= +build3_configure_flags=--disable-shared +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpath-3abe b/tests/havelib/rpath-3abe new file mode 100755 index 000000000..2590a85a2 --- /dev/null +++ b/tests/havelib/rpath-3abe @@ -0,0 +1,15 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a static library, +# and a shared library depending on both. +# Each library installed with a different prefix. + +rp=rp3abe +build1_configure_flags=--disable-shared +build2_configure_flags=--disable-shared +build3_configure_flags= +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpath-3abf b/tests/havelib/rpath-3abf new file mode 100755 index 000000000..860c77ae8 --- /dev/null +++ b/tests/havelib/rpath-3abf @@ -0,0 +1,15 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a shared library, +# and a shared library depending on both. +# Each library installed with a different prefix. + +rp=rp3abf +build1_configure_flags= +build2_configure_flags=--disable-shared +build3_configure_flags= +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpath-3abg b/tests/havelib/rpath-3abg new file mode 100755 index 000000000..56c6db594 --- /dev/null +++ b/tests/havelib/rpath-3abg @@ -0,0 +1,15 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a static library, +# and a shared library depending on both. +# Each library installed with a different prefix. + +rp=rp3abg +build1_configure_flags=--disable-shared +build2_configure_flags= +build3_configure_flags= +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpath-3abh b/tests/havelib/rpath-3abh new file mode 100755 index 000000000..c088dbd55 --- /dev/null +++ b/tests/havelib/rpath-3abh @@ -0,0 +1,15 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a shared library, +# and a shared library depending on both. +# Each library installed with a different prefix. + +rp=rp3abh +build1_configure_flags= +build2_configure_flags= +build3_configure_flags= +build4_package=rpathlz +remove_la=no + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpath-3baa b/tests/havelib/rpath-3baa new file mode 100755 index 000000000..721d4f4f8 --- /dev/null +++ b/tests/havelib/rpath-3baa @@ -0,0 +1,16 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a static library, +# and a static library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. + +rp=rp3baa +build1_configure_flags=--disable-shared +build2_configure_flags=--disable-shared +build3_configure_flags=--disable-shared +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3bab b/tests/havelib/rpath-3bab new file mode 100755 index 000000000..ed5038b72 --- /dev/null +++ b/tests/havelib/rpath-3bab @@ -0,0 +1,16 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a shared library, +# and a static library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. + +rp=rp3bab +build1_configure_flags= +build2_configure_flags=--disable-shared +build3_configure_flags=--disable-shared +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3bac b/tests/havelib/rpath-3bac new file mode 100755 index 000000000..27f5b49c2 --- /dev/null +++ b/tests/havelib/rpath-3bac @@ -0,0 +1,16 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a static library, +# and a static library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. + +rp=rp3bac +build1_configure_flags=--disable-shared +build2_configure_flags= +build3_configure_flags=--disable-shared +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3bad b/tests/havelib/rpath-3bad new file mode 100755 index 000000000..95b3c2f5b --- /dev/null +++ b/tests/havelib/rpath-3bad @@ -0,0 +1,16 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a shared library, +# and a static library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. + +rp=rp3bad +build1_configure_flags= +build2_configure_flags= +build3_configure_flags=--disable-shared +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3bae b/tests/havelib/rpath-3bae new file mode 100755 index 000000000..c90beb362 --- /dev/null +++ b/tests/havelib/rpath-3bae @@ -0,0 +1,16 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a static library, +# and a shared library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. + +rp=rp3bae +build1_configure_flags=--disable-shared +build2_configure_flags=--disable-shared +build3_configure_flags= +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3baf b/tests/havelib/rpath-3baf new file mode 100755 index 000000000..57b906d9c --- /dev/null +++ b/tests/havelib/rpath-3baf @@ -0,0 +1,16 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a shared library, +# and a shared library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. + +rp=rp3baf +build1_configure_flags= +build2_configure_flags=--disable-shared +build3_configure_flags= +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3bag b/tests/havelib/rpath-3bag new file mode 100755 index 000000000..52a83a3a8 --- /dev/null +++ b/tests/havelib/rpath-3bag @@ -0,0 +1,16 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a static library, +# and a shared library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. + +rp=rp3bag +build1_configure_flags=--disable-shared +build2_configure_flags= +build3_configure_flags= +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3bah b/tests/havelib/rpath-3bah new file mode 100755 index 000000000..2ec95194a --- /dev/null +++ b/tests/havelib/rpath-3bah @@ -0,0 +1,16 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a shared library, +# and a shared library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. + +rp=rp3bah +build1_configure_flags= +build2_configure_flags= +build3_configure_flags= +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_a diff --git a/tests/havelib/rpath-3bba b/tests/havelib/rpath-3bba new file mode 100755 index 000000000..33fa2d9b5 --- /dev/null +++ b/tests/havelib/rpath-3bba @@ -0,0 +1,17 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a static library, +# and a static library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. +# Each library installed with a different prefix. + +rp=rp3bba +build1_configure_flags=--disable-shared +build2_configure_flags=--disable-shared +build3_configure_flags=--disable-shared +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpath-3bbb b/tests/havelib/rpath-3bbb new file mode 100755 index 000000000..32dcde7e5 --- /dev/null +++ b/tests/havelib/rpath-3bbb @@ -0,0 +1,17 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a shared library, +# and a static library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. +# Each library installed with a different prefix. + +rp=rp3bbb +build1_configure_flags= +build2_configure_flags=--disable-shared +build3_configure_flags=--disable-shared +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpath-3bbc b/tests/havelib/rpath-3bbc new file mode 100755 index 000000000..f37295a2f --- /dev/null +++ b/tests/havelib/rpath-3bbc @@ -0,0 +1,17 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a static library, +# and a static library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. +# Each library installed with a different prefix. + +rp=rp3bbc +build1_configure_flags=--disable-shared +build2_configure_flags= +build3_configure_flags=--disable-shared +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpath-3bbd b/tests/havelib/rpath-3bbd new file mode 100755 index 000000000..9d5faef46 --- /dev/null +++ b/tests/havelib/rpath-3bbd @@ -0,0 +1,17 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a shared library, +# and a static library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. +# Each library installed with a different prefix. + +rp=rp3bbd +build1_configure_flags= +build2_configure_flags= +build3_configure_flags=--disable-shared +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpath-3bbe b/tests/havelib/rpath-3bbe new file mode 100755 index 000000000..3e2d96dc6 --- /dev/null +++ b/tests/havelib/rpath-3bbe @@ -0,0 +1,17 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a static library, +# and a shared library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. +# Each library installed with a different prefix. + +rp=rp3bbe +build1_configure_flags=--disable-shared +build2_configure_flags=--disable-shared +build3_configure_flags= +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpath-3bbf b/tests/havelib/rpath-3bbf new file mode 100755 index 000000000..b03f0db79 --- /dev/null +++ b/tests/havelib/rpath-3bbf @@ -0,0 +1,17 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a static library depending on a shared library, +# and a shared library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. +# Each library installed with a different prefix. + +rp=rp3bbf +build1_configure_flags= +build2_configure_flags=--disable-shared +build3_configure_flags= +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpath-3bbg b/tests/havelib/rpath-3bbg new file mode 100755 index 000000000..0a6476c13 --- /dev/null +++ b/tests/havelib/rpath-3bbg @@ -0,0 +1,17 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a static library, +# and a shared library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. +# Each library installed with a different prefix. + +rp=rp3bbg +build1_configure_flags=--disable-shared +build2_configure_flags= +build3_configure_flags= +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpath-3bbh b/tests/havelib/rpath-3bbh new file mode 100755 index 000000000..02c0bda47 --- /dev/null +++ b/tests/havelib/rpath-3bbh @@ -0,0 +1,17 @@ +#!/bin/sh + +# Test config.rpath and AC_LIB_LINKFLAGS macro. +# With dependencies: a shared library depending on a shared library, +# and a shared library depending on both. +# No libtool *.la files are assumed, dependencies given as AC_LIB_LINKFLAGS +# argument instead. +# Each library installed with a different prefix. + +rp=rp3bbh +build1_configure_flags= +build2_configure_flags= +build3_configure_flags= +build4_package=rpathlzyx +remove_la=yes + +. $srcdir/rpath-3_b diff --git a/tests/havelib/rpathcfg.sh b/tests/havelib/rpathcfg.sh new file mode 100755 index 000000000..89a98a7ab --- /dev/null +++ b/tests/havelib/rpathcfg.sh @@ -0,0 +1,232 @@ +#!/bin/sh +# Prints information for maintaining config.rpath. + +# The caller should set the environment variables +# top_srcdir, srcdir, CONFIG_SHELL, CC, GCC, LDFLAGS, LD, LIBDIRSTEM, with_gnu_ld, host. + +if test -f $top_srcdir/build-aux/config.rpath; then + build_aux_dir=$top_srcdir/build-aux +else + build_aux_dir=$top_srcdir/../build-aux +fi + +echo "=============== rpathcfg for $host ===============" +echo +echo "--------------- config.rpath output ---------------" +${CONFIG_SHELL-/bin/sh} $build_aux_dir/config.rpath "$host" | sed -e 's/^acl_cv_//' +echo "--------------- experimentally determined ---------------" +builddir=`pwd` +global_top_auxdir=`cd "$top_srcdir"/build-aux && pwd` +export global_top_auxdir + +tstdir='tst/dir' +test -d $tstdir || { mkdir tst && mkdir $tstdir; } + +rm -rf tstprefix $tstdir/build tstlib + +eval `${CONFIG_SHELL-/bin/sh} $build_aux_dir/config.rpath "$host" | grep '^acl_cv_wl='` +wl="$acl_cv_wl" + +# Static library suffix (normally "a"). +mkdir tstprefix +mkdir $tstdir/build +(cd $srcdir/rpathx && tar cf - *) | (cd $tstdir/build && tar xf -) +(cd $tstdir/build + ${CONFIG_SHELL-/bin/sh} ./configure --disable-shared --prefix=$builddir/tstprefix --libdir=$builddir/tstprefix/${LIBDIRSTEM-lib} > configure.log 2>&1 + make > make.log 2>&1 + make install > install.log 2>&1 +) +rm -rf $tstdir/build +libext= +cd tstprefix/lib +for f in *; do + case $f in + *.la) ;; + *[0-9]) ;; + *) libext=`echo $f | sed -e 's/^.*\.//'`;; + esac + if test -n "$libext"; then + break + fi +done +cd ../.. +rm -rf tstprefix + +# Shared library suffix (normally "so"). +mkdir tstprefix +mkdir $tstdir/build +(cd $srcdir/rpathx && tar cf - *) | (cd $tstdir/build && tar xf -) +(cd $tstdir/build + ${CONFIG_SHELL-/bin/sh} ./configure --disable-static --prefix=$builddir/tstprefix --libdir=$builddir/tstprefix/${LIBDIRSTEM-lib} > configure.log 2>&1 + make > make.log 2>&1 + make install > install.log 2>&1 +) +rm -rf $tstdir/build +shlibext= +cd tstprefix/lib || exit 1 +for f in *; do + case $f in + *.la) ;; + *[0-9]) ;; + *) shlibext=`echo $f | sed -e 's/^.*\.//'`;; + esac + if test -n "$shlibext"; then + break + fi +done +cd ../.. +rm -rf tstprefix + +# Prepare hardcoding tests. +mkdir tstprefix +mkdir $tstdir/build +(cd $srcdir/rpathx && tar cf - *) | (cd $tstdir/build && tar xf -) +(cd $tstdir/build + ${CONFIG_SHELL-/bin/sh} ./configure --disable-static --prefix=$builddir/tstprefix --libdir=$builddir/tstprefix/${LIBDIRSTEM-lib} > configure.log 2>&1 + make > make.log 2>&1 + make install > install.log 2>&1 +) +rm -rf $tstdir/build + +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist. +hardcode_libdir_flag_spec= +for spec in \ + '-L$libdir' \ + '-R$libdir' \ + '-rpath $libdir' '${wl}-rpath ${wl}$libdir' \ + '${wl}+b ${wl}$libdir' \ + '${wl}-R $libdir:/usr/lib:/lib' \ + '${wl}-blibpath:$libdir:/usr/lib:/lib' \ + '${wl}-bnolibpath ${wl}-blibpath:$libdir:/usr/lib:/lib' \ + ; do + mv tstprefix/lib tstlib + libdir=`pwd`/tstprefix/lib + eval flag=\"$spec\" + echo 1>&2 + echo "$CC $LDFLAGS $srcdir/rpathlx/usex.c tstlib/librpathx.$shlibext $flag -o a.out" 1>&2 + $CC $LDFLAGS $srcdir/rpathlx/usex.c tstlib/librpathx.$shlibext $flag -o a.out + if test $? = 0; then + mv tstlib tstprefix/lib + echo "ok, running created a.out." 1>&2 + if ./a.out; then + hardcode_libdir_flag_spec="$hardcode_libdir_flag_spec$spec +" + fi + else + mv tstlib tstprefix/lib + fi + rm -f a.out +done + +# Whether we need a single -rpath flag with a separated argument. +hardcode_libdir_separator= +if test -n "$hardcode_libdir_flag_spec"; then + spec=`echo "$hardcode_libdir_flag_spec" | sed -e '2,$d'` + # Try with multiple -rpath flags. + mv tstprefix/lib tstlib + libdir=`pwd`/tstprefix/lib + eval flag1=\"$spec\" + libdir=/tmp + eval flag2=\"$spec\" + echo 1>&2 + echo "$CC $LDFLAGS $srcdir/rpathlx/usex.c tstlib/librpathx.$shlibext $flag1 $flag2 -o a.out" 1>&2 + $CC $LDFLAGS $srcdir/rpathlx/usex.c tstlib/librpathx.$shlibext $flag1 $flag2 -o a.out + if test $? = 0; then + mv tstlib tstprefix/lib + echo "ok, running created a.out." 1>&2 + if ./a.out; then + hardcode_libdir_separator=NONE + fi + else + mv tstlib tstprefix/lib + fi + rm -f a.out + if test -z "$hardcode_libdir_separator"; then + # Try with a single -rpath flag. + mv tstprefix/lib tstlib + libdir=`pwd`/tstprefix/lib:/tmp + eval flag=\"$spec\" + echo 1>&2 + echo "$CC $LDFLAGS $srcdir/rpathlx/usex.c tstlib/librpathx.$shlibext $flag -o a.out" 1>&2 + $CC $LDFLAGS $srcdir/rpathlx/usex.c tstlib/librpathx.$shlibext $flag -o a.out + if test $? = 0; then + mv tstlib tstprefix/lib + echo "ok, running created a.out." 1>&2 + if ./a.out; then + hardcode_libdir_separator=: + fi + else + mv tstlib tstprefix/lib + fi + rm -f a.out + fi + if test -z "$hardcode_libdir_separator"; then + echo "hardcode_libdir_separator test failed!" 1>&2 + else + if test "$hardcode_libdir_separator" = NONE; then + hardcode_libdir_separator= + fi + fi +fi + +# Set to yes if using DIR/libNAME.so during linking hardcodes DIR into the +# resulting binary. +hardcode_direct=no +echo 1>&2 +echo "$CC $LDFLAGS $srcdir/rpathlx/usex.c tstprefix/lib/librpathx.$shlibext -o a.out" 1>&2 +$CC $LDFLAGS $srcdir/rpathlx/usex.c tstprefix/lib/librpathx.$shlibext -o a.out +if test $? = 0; then + echo "ok, running created a.out." 1>&2 + if ./a.out; then + hardcode_direct=yes + fi +fi +rm -f a.out + +# Set to yes if using the -LDIR flag during linking hardcodes DIR into the +# resulting binary. +hardcode_minus_L=no +echo 1>&2 +echo "$CC $LDFLAGS $srcdir/rpathlx/usex.c -Ltstprefix/lib -lrpathx -o a.out" 1>&2 +$CC $LDFLAGS $srcdir/rpathlx/usex.c -Ltstprefix/lib -lrpathx -o a.out +if test $? = 0; then + echo "ok, running created a.out." 1>&2 + if ./a.out; then + hardcode_minus_L=yes + fi +fi +rm -f a.out + +# Clean up. +rm -rf tstprefix $tstdir + +sed_quote_subst='s/\(["`$\\]\)/\\\1/g' +escaped_hardcode_libdir_flag_spec=`echo "X$hardcode_libdir_flag_spec" | sed -e 's/^X//' -e "$sed_quote_subst"` +escaped_sys_lib_search_path_spec=`echo "X$sys_lib_search_path_spec" | sed -e 's/^X//' -e "$sed_quote_subst"` +escaped_sys_lib_dlsearch_path_spec=`echo "X$sys_lib_dlsearch_path_spec" | sed -e 's/^X//' -e "$sed_quote_subst"` + +cat <. + +AC_INIT([configure.ac]) +AC_CONFIG_AUX_DIR([../../../build-aux]) +AM_INIT_AUTOMAKE([gettext_rpathlx], [0]) +AC_PROG_CC +AC_LIB_LINKFLAGS([rpathx]) +AC_SUBST([global_top_auxdir]) +AC_OUTPUT([Makefile]) diff --git a/tests/havelib/rpathlx/usex.c b/tests/havelib/rpathlx/usex.c new file mode 100644 index 000000000..d09b11176 --- /dev/null +++ b/tests/havelib/rpathlx/usex.c @@ -0,0 +1,2 @@ +extern int rpathx_value (void); +int main () { return !(rpathx_value () == 5); } diff --git a/tests/havelib/rpathly/Makefile.am b/tests/havelib/rpathly/Makefile.am new file mode 100644 index 000000000..44812b5bc --- /dev/null +++ b/tests/havelib/rpathly/Makefile.am @@ -0,0 +1,7 @@ +AUTOMAKE_OPTIONS = 1.5 foreign no-dependencies +bin_PROGRAMS = usey +usey_SOURCES = usey.c +LDADD = @LIBRPATHY@ + +check: all + ./usey diff --git a/tests/havelib/rpathly/configure.ac b/tests/havelib/rpathly/configure.ac new file mode 100644 index 000000000..379431f67 --- /dev/null +++ b/tests/havelib/rpathly/configure.ac @@ -0,0 +1,24 @@ +dnl Configuration of a program that links with librpathy. +dnl +dnl Copyright (C) 2002-2003, 2005, 2010 Free Software Foundation, Inc. +dnl +dnl This program is free software: you can redistribute it and/or modify +dnl it under the terms of the GNU General Public License as published by +dnl the Free Software Foundation; either version 3 of the License, or +dnl (at your option) any later version. +dnl +dnl This program is distributed in the hope that it will be useful, +dnl but WITHOUT ANY WARRANTY; without even the implied warranty of +dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +dnl GNU General Public License for more details. +dnl +dnl You should have received a copy of the GNU General Public License +dnl along with this program. If not, see . + +AC_INIT([configure.ac]) +AC_CONFIG_AUX_DIR([../../../build-aux]) +AM_INIT_AUTOMAKE([gettext_rpathly], [0]) +AC_PROG_CC +AC_LIB_LINKFLAGS([rpathy]) +AC_SUBST([global_top_auxdir]) +AC_OUTPUT([Makefile]) diff --git a/tests/havelib/rpathly/usey.c b/tests/havelib/rpathly/usey.c new file mode 100644 index 000000000..9fff7871b --- /dev/null +++ b/tests/havelib/rpathly/usey.c @@ -0,0 +1,2 @@ +extern int rpathy_value (void); +int main () { return !(rpathy_value () == 57); } diff --git a/tests/havelib/rpathlyx/Makefile.am b/tests/havelib/rpathlyx/Makefile.am new file mode 100644 index 000000000..44812b5bc --- /dev/null +++ b/tests/havelib/rpathlyx/Makefile.am @@ -0,0 +1,7 @@ +AUTOMAKE_OPTIONS = 1.5 foreign no-dependencies +bin_PROGRAMS = usey +usey_SOURCES = usey.c +LDADD = @LIBRPATHY@ + +check: all + ./usey diff --git a/tests/havelib/rpathlyx/configure.ac b/tests/havelib/rpathlyx/configure.ac new file mode 100644 index 000000000..18f817bbd --- /dev/null +++ b/tests/havelib/rpathlyx/configure.ac @@ -0,0 +1,26 @@ +dnl Configuration of a program that links with librpathy. +dnl +dnl Copyright (C) 2002-2003, 2005, 2010 Free Software Foundation, Inc. +dnl +dnl This program is free software: you can redistribute it and/or modify +dnl it under the terms of the GNU General Public License as published by +dnl the Free Software Foundation; either version 3 of the License, or +dnl (at your option) any later version. +dnl +dnl This program is distributed in the hope that it will be useful, +dnl but WITHOUT ANY WARRANTY; without even the implied warranty of +dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +dnl GNU General Public License for more details. +dnl +dnl You should have received a copy of the GNU General Public License +dnl along with this program. If not, see . + +AC_INIT([configure.ac]) +AC_CONFIG_AUX_DIR([../../../build-aux]) +AM_INIT_AUTOMAKE([gettext_rpathlyx], [0]) +AC_PROG_CC +AC_LIB_LINKFLAGS([rpathx]) +AC_LIB_LINKFLAGS([rpathy],[rpathx]) +LIBRPATHY="$LIBRPATHY $LIBRPATHX" +AC_SUBST([global_top_auxdir]) +AC_OUTPUT([Makefile]) diff --git a/tests/havelib/rpathlyx/usey.c b/tests/havelib/rpathlyx/usey.c new file mode 100644 index 000000000..9fff7871b --- /dev/null +++ b/tests/havelib/rpathlyx/usey.c @@ -0,0 +1,2 @@ +extern int rpathy_value (void); +int main () { return !(rpathy_value () == 57); } diff --git a/tests/havelib/rpathlz/Makefile.am b/tests/havelib/rpathlz/Makefile.am new file mode 100644 index 000000000..ff0e6027a --- /dev/null +++ b/tests/havelib/rpathlz/Makefile.am @@ -0,0 +1,7 @@ +AUTOMAKE_OPTIONS = 1.5 foreign no-dependencies +bin_PROGRAMS = usez +usez_SOURCES = usez.c +LDADD = @LIBRPATHZ@ + +check: all + ./usez diff --git a/tests/havelib/rpathlz/configure.ac b/tests/havelib/rpathlz/configure.ac new file mode 100644 index 000000000..3b9c99f65 --- /dev/null +++ b/tests/havelib/rpathlz/configure.ac @@ -0,0 +1,24 @@ +dnl Configuration of a program that links with librpathz. +dnl +dnl Copyright (C) 2002-2003, 2005, 2010 Free Software Foundation, Inc. +dnl +dnl This program is free software: you can redistribute it and/or modify +dnl it under the terms of the GNU General Public License as published by +dnl the Free Software Foundation; either version 3 of the License, or +dnl (at your option) any later version. +dnl +dnl This program is distributed in the hope that it will be useful, +dnl but WITHOUT ANY WARRANTY; without even the implied warranty of +dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +dnl GNU General Public License for more details. +dnl +dnl You should have received a copy of the GNU General Public License +dnl along with this program. If not, see . + +AC_INIT([configure.ac]) +AC_CONFIG_AUX_DIR([../../../build-aux]) +AM_INIT_AUTOMAKE([gettext_rpathlz], [0]) +AC_PROG_CC +AC_LIB_LINKFLAGS([rpathz]) +AC_SUBST([global_top_auxdir]) +AC_OUTPUT([Makefile]) diff --git a/tests/havelib/rpathlz/usez.c b/tests/havelib/rpathlz/usez.c new file mode 100644 index 000000000..18d86897b --- /dev/null +++ b/tests/havelib/rpathlz/usez.c @@ -0,0 +1,2 @@ +extern int rpathz_value (void); +int main () { return !(rpathz_value () == 5171); } diff --git a/tests/havelib/rpathlzyx/Makefile.am b/tests/havelib/rpathlzyx/Makefile.am new file mode 100644 index 000000000..ff0e6027a --- /dev/null +++ b/tests/havelib/rpathlzyx/Makefile.am @@ -0,0 +1,7 @@ +AUTOMAKE_OPTIONS = 1.5 foreign no-dependencies +bin_PROGRAMS = usez +usez_SOURCES = usez.c +LDADD = @LIBRPATHZ@ + +check: all + ./usez diff --git a/tests/havelib/rpathlzyx/configure.ac b/tests/havelib/rpathlzyx/configure.ac new file mode 100644 index 000000000..29c45a33c --- /dev/null +++ b/tests/havelib/rpathlzyx/configure.ac @@ -0,0 +1,27 @@ +dnl Configuration of a program that links with librpathz. +dnl +dnl Copyright (C) 2002-2003, 2005, 2010 Free Software Foundation, Inc. +dnl +dnl This program is free software: you can redistribute it and/or modify +dnl it under the terms of the GNU General Public License as published by +dnl the Free Software Foundation; either version 3 of the License, or +dnl (at your option) any later version. +dnl +dnl This program is distributed in the hope that it will be useful, +dnl but WITHOUT ANY WARRANTY; without even the implied warranty of +dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +dnl GNU General Public License for more details. +dnl +dnl You should have received a copy of the GNU General Public License +dnl along with this program. If not, see . + +AC_INIT([configure.ac]) +AC_CONFIG_AUX_DIR([../../../build-aux]) +AM_INIT_AUTOMAKE([gettext_rpathlzyx], [0]) +AC_PROG_CC +AC_LIB_LINKFLAGS([rpathx]) +AC_LIB_LINKFLAGS([rpathy],[rpathx]) +AC_LIB_LINKFLAGS([rpathz],[rpathx rpathy]) +LIBRPATHZ="$LIBRPATHZ $LIBRPATHY $LIBRPATHX" +AC_SUBST([global_top_auxdir]) +AC_OUTPUT([Makefile]) diff --git a/tests/havelib/rpathlzyx/usez.c b/tests/havelib/rpathlzyx/usez.c new file mode 100644 index 000000000..18d86897b --- /dev/null +++ b/tests/havelib/rpathlzyx/usez.c @@ -0,0 +1,2 @@ +extern int rpathz_value (void); +int main () { return !(rpathz_value () == 5171); } diff --git a/tests/havelib/rpathx/Makefile.am b/tests/havelib/rpathx/Makefile.am new file mode 100644 index 000000000..69b4cc987 --- /dev/null +++ b/tests/havelib/rpathx/Makefile.am @@ -0,0 +1,4 @@ +AUTOMAKE_OPTIONS = 1.5 foreign no-dependencies +lib_LTLIBRARIES = librpathx.la +librpathx_la_SOURCES = rpathx.c +librpathx_la_LDFLAGS = -lc -no-undefined diff --git a/tests/havelib/rpathx/configure.ac b/tests/havelib/rpathx/configure.ac new file mode 100644 index 000000000..c781d1622 --- /dev/null +++ b/tests/havelib/rpathx/configure.ac @@ -0,0 +1,25 @@ +dnl Configuration of librpathx. +dnl +dnl Copyright (C) 2002-2003, 2005, 2010 Free Software Foundation, Inc. +dnl +dnl This program is free software: you can redistribute it and/or modify +dnl it under the terms of the GNU General Public License as published by +dnl the Free Software Foundation; either version 3 of the License, or +dnl (at your option) any later version. +dnl +dnl This program is distributed in the hope that it will be useful, +dnl but WITHOUT ANY WARRANTY; without even the implied warranty of +dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +dnl GNU General Public License for more details. +dnl +dnl You should have received a copy of the GNU General Public License +dnl along with this program. If not, see . + +AC_INIT([configure.ac]) +AC_CONFIG_AUX_DIR([../../../build-aux]) +AC_CONFIG_MACRO_DIR([../ltm4]) +AM_INIT_AUTOMAKE([gettext_rpathx], [0]) +AC_PROG_CC +AM_PROG_LIBTOOL +AC_SUBST([global_top_auxdir]) +AC_OUTPUT([Makefile]) diff --git a/tests/havelib/rpathx/rpathx.c b/tests/havelib/rpathx/rpathx.c new file mode 100644 index 000000000..fd1a3772f --- /dev/null +++ b/tests/havelib/rpathx/rpathx.c @@ -0,0 +1 @@ +int rpathx_value () { return 5; } diff --git a/tests/havelib/rpathy/Makefile.am b/tests/havelib/rpathy/Makefile.am new file mode 100644 index 000000000..6b44f37f6 --- /dev/null +++ b/tests/havelib/rpathy/Makefile.am @@ -0,0 +1,4 @@ +AUTOMAKE_OPTIONS = 1.5 foreign no-dependencies +lib_LTLIBRARIES = librpathy.la +librpathy_la_SOURCES = rpathy.c +librpathy_la_LDFLAGS = @LTLIBRPATHX@ -lc -no-undefined diff --git a/tests/havelib/rpathy/configure.ac b/tests/havelib/rpathy/configure.ac new file mode 100644 index 000000000..0df1fe66b --- /dev/null +++ b/tests/havelib/rpathy/configure.ac @@ -0,0 +1,26 @@ +dnl Configuration of librpathy that depends on librpathx. +dnl +dnl Copyright (C) 2002-2003, 2005, 2010 Free Software Foundation, Inc. +dnl +dnl This program is free software: you can redistribute it and/or modify +dnl it under the terms of the GNU General Public License as published by +dnl the Free Software Foundation; either version 3 of the License, or +dnl (at your option) any later version. +dnl +dnl This program is distributed in the hope that it will be useful, +dnl but WITHOUT ANY WARRANTY; without even the implied warranty of +dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +dnl GNU General Public License for more details. +dnl +dnl You should have received a copy of the GNU General Public License +dnl along with this program. If not, see . + +AC_INIT([configure.ac]) +AC_CONFIG_AUX_DIR([../../../build-aux]) +AC_CONFIG_MACRO_DIR([../ltm4]) +AM_INIT_AUTOMAKE([gettext_rpathy], [0]) +AC_PROG_CC +AM_PROG_LIBTOOL +AC_LIB_LINKFLAGS([rpathx]) +AC_SUBST([global_top_auxdir]) +AC_OUTPUT([Makefile]) diff --git a/tests/havelib/rpathy/rpathy.c b/tests/havelib/rpathy/rpathy.c new file mode 100644 index 000000000..42514bf1a --- /dev/null +++ b/tests/havelib/rpathy/rpathy.c @@ -0,0 +1,2 @@ +extern int rpathx_value (void); +int rpathy_value () { return 10 * rpathx_value () + 7; } diff --git a/tests/havelib/rpathz/Makefile.am b/tests/havelib/rpathz/Makefile.am new file mode 100644 index 000000000..675dda261 --- /dev/null +++ b/tests/havelib/rpathz/Makefile.am @@ -0,0 +1,4 @@ +AUTOMAKE_OPTIONS = 1.5 foreign no-dependencies +lib_LTLIBRARIES = librpathz.la +librpathz_la_SOURCES = rpathz.c +librpathz_la_LDFLAGS = @LTLIBRPATHX@ @LTLIBRPATHY@ -lc -no-undefined diff --git a/tests/havelib/rpathz/configure.ac b/tests/havelib/rpathz/configure.ac new file mode 100644 index 000000000..e03e2546e --- /dev/null +++ b/tests/havelib/rpathz/configure.ac @@ -0,0 +1,27 @@ +dnl Configuration of librpathz that depends on librpathx and librpathy. +dnl +dnl Copyright (C) 2002-2003, 2005, 2010 Free Software Foundation, Inc. +dnl +dnl This program is free software: you can redistribute it and/or modify +dnl it under the terms of the GNU General Public License as published by +dnl the Free Software Foundation; either version 3 of the License, or +dnl (at your option) any later version. +dnl +dnl This program is distributed in the hope that it will be useful, +dnl but WITHOUT ANY WARRANTY; without even the implied warranty of +dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +dnl GNU General Public License for more details. +dnl +dnl You should have received a copy of the GNU General Public License +dnl along with this program. If not, see . + +AC_INIT([configure.ac]) +AC_CONFIG_AUX_DIR([../../../build-aux]) +AC_CONFIG_MACRO_DIR([../ltm4]) +AM_INIT_AUTOMAKE([gettext_rpathz], [0]) +AC_PROG_CC +AM_PROG_LIBTOOL +AC_LIB_LINKFLAGS([rpathx]) +AC_LIB_LINKFLAGS([rpathy],[rpathx]) +AC_SUBST([global_top_auxdir]) +AC_OUTPUT([Makefile]) diff --git a/tests/havelib/rpathz/rpathz.c b/tests/havelib/rpathz/rpathz.c new file mode 100644 index 000000000..da34af1c8 --- /dev/null +++ b/tests/havelib/rpathz/rpathz.c @@ -0,0 +1,3 @@ +extern int rpathx_value (void); +extern int rpathy_value (void); +int rpathz_value () { return 1000 * rpathx_value () + 3 * rpathy_value (); } -- 2.11.0