From: Mark Wooding Date: Sat, 9 May 2020 12:26:13 +0000 (+0100) Subject: configure.ac, vars.am: Use host-specific link options for test programs. X-Git-Tag: 2.4.5~10 X-Git-Url: https://git.distorted.org.uk/~mdw/catacomb/commitdiff_plain/aad774b289e65bc8f2045b8aa16f68e9d434a3cc configure.ac, vars.am: Use host-specific link options for test programs. It turns out that `libtool' spams an annoying warning message to the terminal every time you call it with `-no-install' on a Windowsish or Mac OSish system. Since this is just intended to be an optimization and developer-convenience feature, wind it down to `-no-fast-install' on the affected platforms so as not to provoke these really annoying messages. --- diff --git a/configure.ac b/configure.ac index f8ad8b77..8ebda7ba 100644 --- a/configure.ac +++ b/configure.ac @@ -39,6 +39,13 @@ AC_PROG_CC AX_CFLAGS_WARN_ALL AM_PROG_LIBTOOL mdw_LIBTOOL_VERSION_INFO +case $host_os in + cygwin* | mingw* | pw32* | os2* | darwin* | cegcc*) + TEST_LDFLAGS=-no-fast-install ;; + *) + TEST_LDFLAGS=-no-install ;; +esac +AC_SUBST([TEST_LDFLAGS]) AM_PROG_AS diff --git a/vars.am b/vars.am index 115cb317..223f2bab 100644 --- a/vars.am +++ b/vars.am @@ -120,13 +120,13 @@ SUFFIXES += .c .t$(EXEEXT) .to .c.to: $(AM_V_CC)$(COMPILE) -c -DTEST_RIG -DSRCDIR=\"$(srcdir)\" $< -o $@ .to.t$(EXEEXT): - $(AM_V_CCLD)$(LINK) -no-install $< \ + $(AM_V_CCLD)$(LINK) $(TEST_LDFLAGS) $< \ $(TEST_LIBS) $(top_builddir)/libcatacomb.la \ $(mLib_LIBS) $(CATACOMB_LIBS) $(LIBS) %.to: %.c %.lo $(AM_V_CC)$(COMPILE) -c -DTEST_RIG -DSRCDIR=\"$(srcdir)\" $< -o $@ %.t$(EXEEXT): %.to $(TEST_LIBS) $(top_builddir)/libcatacomb.la - $(AM_V_CCLD)$(LINK) -no-install $+ \ + $(AM_V_CCLD)$(LINK) $(TEST_LDFLAGS) $+ \ $(mLib_LIBS) $(CATACOMB_LIBS) $(LIBS) .PRECIOUS: %.to %.t$(EXEEXT)