Gary V. Vaughan <gvv@techie.com>. Co-maintainer.
Ossama Othman <ossama@debian.org>. Co-maintainer.
Robert Boehne <rboehne@ricardo-us.com>. Co-maintainer.
-Bruce Korb <bkorb@gnu.org>. Binary-Branch maintainer.
+2002-02-09 Gary V. Vaughan <gary@gnu.org>
+
+ * NEWS: Updated.
+ * THANKS: Added Rob Collins and Chuck Wilson for their cygwin
+ work.
+
+ From Robert Collins <robert.collins@itdomain.com.au>:
+ * configure.ac (AC_EXEEXT): Needed for DOSish systems.
+ * libtool.m4 (shlibpath_overrides_runpath) [cygwin]: Set to yes
+ when compiling with gcc.
+ (lt_prog_compiler_pic) [cygwin]: No longer needs the -DDLL_EXPORT
+ hack, so we just say the pic is the default.
+ (AC_LIBTOOL_PROG_LD_SHLIBS) [cygwin]: Extract symbols from a
+ library normally.
+ [cygwin]: Declare C++ compiler characterisics for g++, taking into
+ account the new auto-import support in cygwin ld.
+ * ltmain.in (specialdeplibs) [cygwin]: Be careful about
+ eliminating duplicate -lgcc's from the link line.
+ [cygwin]: Be smarter about .exe suffixes.
+ * demo/configure.ac (AC_EXEEXT, AC_LIBTOOL_WIN32_DLL): Support
+ DOSish systems properly.
+ * depdemo/configure.ac (AC_EXEEXT, AC_LIBTOOL_WIN32_DLL): Ditto.
+ * demo/Makefile.am (deplibs-check): Allow for .exe suffix. Use
+ hell_static instead of hell.static for multi-`.' inhibited OSes.
+ * tests/demo-exec.test: Ditto.
+ * tests/demo-inst.test: Ditto.
+ * demo/foo.h [cygwin]: Sanitize cygwin dll support.
+ * demo/foo.c (_LIBFOO_COMPILATION_): No longer required.
+ * demo/hello.c (_LIBFOO_COMPILATION_): Ditto.
+ * depdemo/Makefile.am (bin_PROGRAMS): Use depdemo_static instead
+ of depdemo.static for multi-`.' inhibited OSes.
+ * tests/depdemo-exec.test: Ditto.
+ * tests/depdemo-inst.test: Ditto.
+ * mdemo/Makefile.am (bin_PROGRAMS): Ditto for mdemo.static.
+ * tests/dryrun.test: Ditto.
+ * tests/mdemo-exec.test: Ditto.
+ * tests/mdemo-inst.test: Ditto.
+ * tests/build-relink.test: Be careful about possible .exe
+ suffixes.
+ * tests/noinst-link.test: Allow for .exe suffix.
+
2002-02-07 Alexandre Oliva <aoliva@redhat.com>
Reverted incorrect patch:
NEWS - list of user-visible changes between releases of GNU Libtool
+New in 1.4f: 2002-??-??; CVS version 1.4e, Libtool team:
+* Support auto-import patch to binutils on cygwin for much improved dll
+ support.
+* Bug fixes.
+\f
New in 1.4d: 2002-01-07; CVS version 1.4c, Libtool team:
* Help strings display correctly again.
* Better error messages when library linking fails.
\f
New in CVS version 1.2g, Libtool team:
* AM_PROG_LIBTOOL is smaller and faster
-* AC_LIBTOOL_WIN32_DLL is required in configure.in for libtool to
+* AC_LIBTL_L_WIN32_DLL is required in configure.in for libtool to
attempt to build dlls on win32 hosts
* Shared libraries on AmigaOS up to version 4 are now disabled
since they don't meet libtool's requirements for shared libraries
\f
New in 1.2 - 1998-03-20, Gordon Matzigkeit:
* Minor bug fixes to provide a stable public release.
-* Libtool no longer causes Solaris printf to barf due to silly
+* Libtool no longer cseses Solaris printf to barf due to silly
2110-byte static buffers.
\f
New in 1.1 - 1998-03-08, Gordon Matzigkeit:
Art Pope <apope@sarnoff.com>
Bruno Haible <haible@ilog.fr>
Carl D. Roth <roth@cse.ucsc.edu>
+Charles S. Wilson <cwilson@ece.gatech.edu>
Chris P. Ross <cross@eng.us.uu.net>
DJ Delorie <dj@delorie.com>
Edouard G. Parmelan <Edouard.Parmelan@France.NCR.COM>
Ossama Othman <othman@cs.wustl.edu>
Olly Betts <olly@muscat.co.uk>
Pavel Roskin <pavel_roskin@geocities.com>
+Robert Collins <robert.collins@itdomain.com.au>
Sebastian Wilhelmi <wilhelmi@ira.uka.de>
Stephan Kulow <coolo@kde.org>
Steven M. Schultz <sms@wlv.iipo.gtegsc.com>
Todd Vierling <tv@pobox.com>
-Tom Tromey <tromey@cygnus.com>
+Tom Tmemey <tromey@cygnus.com>
Ulrich Drepper <drepper@ipd.info.uni-karlsruhe.de>
Xavier Pianet <xavier@xingo.com>
# Use the specified CC and LD
AC_PROG_CC
+AC_EXEEXT
AM_PROG_LD
AC_SUBST(LD)
AM_PROG_NM
BUILD_helldl =
endif
-bin_PROGRAMS = hell hell.static $(BUILD_helldl)
+bin_PROGRAMS = hell hell_static $(BUILD_helldl)
# Build hell from main.c and libhello.la
hell_SOURCES = main.c
CLEANFILES += $(EXTRA_LIBRARIES) $(EXTRA_LTLIBRARIES) $(EXTRA_PROGRAMS)
-deplibs-check: hell0
+deplibs-check: hell0$(EXEEXT)
## ---------------- ##
AC_PROG_CC
AC_C_CONST
+AC_EXEEXT
## ----------------------- ##
## Libtool initialisation. ##
## ----------------------- ##
AC_LIBTOOL_DLOPEN
+AC_LIBTOOL_WIN32_DLL
AM_PROG_LIBTOOL
AC_SUBST([LIBTOOL_DEPS])
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
USA. */
-#define _LIBFOO_COMPILATION_
#include "foo.h"
-#undef _LIBFOO_COMPILATION_
#include <stdio.h>
/* At some point, cygwin will stop defining __CYGWIN32__, but b19 and
* earlier do not define __CYGWIN__. This snippit allows us to check
- * for __CYGWIN32__ reliably for both old and (probable) future releases.
+ * for __CYGWIN__ reliably for both current, old, and (probable) future
+ * releases.
*/
-#ifdef __CYGWIN__
-# ifndef __CYGWIN32__
-# define __CYGWIN32__
+#ifdef __CYGWIN32__
+# ifndef __CYGWIN__
+# define __CYGWIN__
# endif
#endif
that don't understand ANSI C prototypes still work, and ANSI C
compilers can issue warnings about type mismatches. */
#undef LTDL_PARAMS
-#if defined (__STDC__) || defined (_AIX) || (defined (__mips) && defined (_SYSTYPE_SVR4)) || defined(__CYGWIN32__) || defined(__cplusplus)
+#if defined (__STDC__) || defined (_AIX) || (defined (__mips) && defined (_SYSTYPE_SVR4)) || defined(__CYGWIN__) || defined(__cplusplus)
# define LT_PARAMS(protos) protos
# define lt_ptr_t void*
#else
# define lt_ptr_t char*
#endif
-#ifdef __CYGWIN32__
-# ifdef LIBFOO_DLL
- /* need some (as yet non-existant) automake magic to tell
- * the object whether the libfoo it will be linked with is
- * a dll or not, ie whether LIBFOO_DLL is defined or not.
- */
-# ifdef _LIBFOO_COMPILATION_
-# define EXTERN __declspec(dllexport)
-# else
-# define EXTERN extern __declspec(dllimport)
-# endif
-# else
-# define EXTERN extern
-# endif
-#else
-# define EXTERN extern
-#endif
-
/* Silly constants that the functions return. */
#define HELLO_RET 0xe110
#define FOO_RET 0xf00
__BEGIN_DECLS
int foo LT_PARAMS((void));
int hello LT_PARAMS((void));
-EXTERN int nothing;
+extern int nothing;
__END_DECLS
#endif /* !_FOO_H_ */
USA. */
/* Written by Gordon Matzigkeit <gord@gnu.ai.mit.edu> */
-#define _LIBFOO_COMPILATION
#include "foo.h"
-#undef _LIBFOO_COMPILATION
#include <stdio.h>
EXTRA_DIST = sysdep.h
-bin_PROGRAMS = depdemo depdemo.static
+bin_PROGRAMS = depdemo depdemo_static
depdemo_SOURCES = main.c
depdemo_LDADD = $(top_builddir)/l1/libl1.la $(top_builddir)/l2/libl2.la \
## compiler checks. ##
## ---------------- ##
AC_PROG_CC
-
+AC_EXEEXT
## ----------------------- ##
## Libtool initialisation. ##
## ----------------------- ##
+AC_LIBTOOL_WIN32_DLL
AM_PROG_LIBTOOL
AC_SUBST([LIBTOOL_DEPS])
extradir = $(libdir)/extra
-extra_LTLIBRARIES = libl3.la
+lib_LTLIBRARIES = libl3.la
libl3_la_SOURCES = l3.c l3.h
libl3_la_LIBADD = $(top_builddir)/l1/libl1.la $(top_builddir)/l2/libl2.la
if (argc == 2 && strcmp (argv[1], "-alt") == 0
&& var_l1 + var_l2 + var_l4 == 8)
return 0;
+ printf("var_l1(%d) + var_l2(%d) + var_l4(%d) == %d\n",var_l1,var_l2,var_l4, var_l1 + var_l2 + var_l4);
if (var_l1 + var_l2 + var_l4 != 20)
+ {
+ printf("var_l1(%d) + var_l2(%d) + var_l4(%d) != 20\n",var_l1,var_l2,var_l4);
return 1;
+ }
return 0;
}
destfile="$destdir/$destfile"
fi
+ # If the file is missing, and there is a .exe on the end, strip it
+ # because it is most likely a libtool script we actually want to
+ # install
+ stripped_ext=""
+ case $file in
+ *.exe)
+ if test ! -f "$file"; then
+ file=`echo $file|${SED} 's,.exe$,,'`
+ stripped_ext=".exe"
+ fi
+ ;;
+ esac
+
# Do a test to see if this is really a libtool program.
case $host in
*cygwin*|*mingw*)
$echo "$modename: error: cannot create temporary directory \`$tmpdir'" 1>&2
continue
fi
- file=`$echo "X$file" | $Xsed -e 's%^.*/%%'`
+ file=`$echo "X$file$stripped_ext" | $Xsed -e 's%^.*/%%'`
outputname="$tmpdir/$file"
# Replace the output file specification.
relink_command=`$echo "X$relink_command" | $Xsed -e 's%@OUTPUT@%'"$outputname"'%g'`
fi
else
# Install the binary that we compiled earlier.
- file=`$echo "X$file" | $Xsed -e "s%\([^/]*\)$%$objdir/\1%"`
+ file=`$echo "X$file$stripped_ext" | $Xsed -e "s%\([^/]*\)$%$objdir/\1%"`
fi
fi
*) linkmode=prog ;; # Anything else should be a program.
esac
- specialdeplibs=
+ case $host in
+ *cygwin*)
+ # This is a hack, but we run into problems on cygwin.
+ # libgcc.a depends on libcygwin, but gcc puts -lgcc onto
+ # the link line twice: once before the "normal" libs
+ # (-lcygwin -luser32 -lkernel32 -ladvapi32 -lshell32) and
+ # once AFTER those. However, the "eliminate dup deps"
+ # proceedure keeps only the LAST duplicate -- thus
+ # messing up the order, since after dup elimination
+ # -lgcc comes AFTER -lcygwin. In normal C operation,
+ # you don't notice the problem, because -lgcc isn't
+ # really used. However, now that C++ libraries are
+ # libtool-able, you DO see the problem. So, it must
+ # be fixed. We could always force "--preserve-dup-deps"
+ # but that could lead to other problems. So, on cygwin,
+ # always preserve dups of -lgcc...but only -lgcc. That
+ # way, the dependency order won't get corrupted.
+ specialdeplibs="-lgcc"
+ ;;
+ *)
+ specialdeplibs=
+ ;;
+ esac
+
libs=
# Find all interdependent deplibs by searching for libraries
# that are linked more than once (e.g. -la -lb -la)
esac
# test for cygwin because mv fails w/o .exe extensions
case $host in
- *cygwin*) exeext=.exe ;;
+ *cygwin*)
+ exeext=.exe
+ outputname=`echo $outputname|${SED} 's,.exe$,,'` ;;
*) exeext= ;;
esac
$rm $output
/* --- DLOPEN() INTERFACE LOADER --- */
-/* The Cygwin dlopen implementation prints a spurious error message to
- stderr if its call to LoadLibrary() fails for any reason. We can
+/* Older Cygwin dlopen implementations print a spurious error message to
+ stderr if the call to LoadLibrary() fails for any reason. We can
mitigate this by not using the Cygwin implementation, and falling
back to our own LoadLibrary() wrapper. */
#if HAVE_LIBDL && !defined(__CYGWIN__)
postuninstall_cmds='dldll=`bash 2>&1 -c '\''. $file; echo \$dlname'\''`~
dlpath=$dir/\$dldll~
$rm \$dlpath'
+ shlibpath_overrides_runpath=yes
;;
yes,mingw*)
library_names_spec='${libname}`echo ${release} | sed -e 's/[[.]]/-/g'`${versuffix}.dll'
;;
esac
;;
+
+ cygwin*)
+ # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
+ # as there is no search path for DLLs.
+ _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
+ _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
+ _LT_AC_TAGVAR(always_export_symbols, $1)=yes
+
+ if $LD --help 2>&1 | egrep 'auto-import' > /dev/null; then
+ _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
+ _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}-retain-symbols-file $wl$export_symbols ${wl}--out-implib,$lib'
+ else
+ _LT_AC_TAGVAR(ld_shlibs, $1)=no
+ fi
+ ;;
+
+ mingw* | pw32*)
+ # FIXME: insert proper C++ library support
+ _LT_AC_TAGVAR(ld_shlibs, $1)=no
+ ;;
+
dgux*)
case $cc_basename in
ec++)
# like `-m68040'.
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
;;
- beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
+ beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
# PIC is the default for these OSes.
;;
- cygwin* | mingw* | os2*)
+ mingw* | os2*)
# This hack is so that the source file can tell whether it is being
# built for inclusion in a dll (and should export symbols for example).
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
;;
- beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
+ beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
# PIC is the default for these OSes.
;;
- cygwin* | mingw* | pw32* | os2*)
+ mingw* | pw32* | os2*)
# This hack is so that the source file can tell whether it is being
# built for inclusion in a dll (and should export symbols for example).
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
fi
;;
- cygwin* | mingw* | pw32* | os2*)
+ mingw* | pw32* | os2*)
# This hack is so that the source file can tell whether it is being
# built for inclusion in a dll (and should export symbols for example).
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
fi
;;
- cygwin* | mingw* | pw32*)
+ mingw* | pw32*)
_LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
;;
*)
fi
;;
- cygwin* | mingw* | pw32*)
+ cygwin*)
+ # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
+ # as there is no search path for DLLs.
+ _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
+ _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
+ _LT_AC_TAGVAR(always_export_symbols, $1)=yes
+
+ if $LD --help 2>&1 | egrep 'auto-import' > /dev/null; then
+ _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
+ _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}-retain-symbols-file $wl$export_symbols ${wl}--out-implib,$lib'
+ else
+ ld_shlibs=no
+ fi
+ ;;
+
+ mingw* | pw32*)
# _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, as there is
# no search path for DLLs.
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)='$DLLTOOL --as=$AS --dllname $soname --def $output_objdir/$soname-def --output-lib $output_objdir/$newlib'
- # cygwin and mingw dlls have different entry points and sets of symbols
- # to exclude.
# FIXME: what about values for MSVC?
dll_entry=__cygwin_dll_entry@12
- dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12~
case $host_os in
mingw*)
# mingw values
dll_entry=_DllMainCRTStartup@12
- dll_exclude_symbols=DllMain@12,DllMainCRTStartup@12,DllEntryPoint@12~
;;
esac
- # mingw and cygwin differ, and it's simplest to just exclude the union
- # of the two symbol sets.
dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12,DllMainCRTStartup@12,DllEntryPoint@12
# recent cygwin and mingw systems supply a stub DllMain which the user
*) linkmode=prog ;; # Anything else should be a program.
esac
- specialdeplibs=
+ case $host in
+ *cygwin*)
+ # This is a hack, but we run into problems on cygwin.
+ # libgcc.a depends on libcygwin, but gcc puts -lgcc onto
+ # the link line twice: once before the "normal" libs
+ # (-lcygwin -luser32 -lkernel32 -ladvapi32 -lshell32) and
+ # once AFTER those. However, the "eliminate dup deps"
+ # proceedure keeps only the LAST duplicate -- thus
+ # messing up the order, since after dup elimination
+ # -lgcc comes AFTER -lcygwin. In normal C operation,
+ # you don't notice the problem, because -lgcc isn't
+ # really used. However, now that C++ libraries are
+ # libtool-able, you DO see the problem. So, it must
+ # be fixed. We could always force "--preserve-dup-deps"
+ # but that could lead to other problems. So, on cygwin,
+ # always preserve dups of -lgcc...but only -lgcc. That
+ # way, the dependency order won't get corrupted.
+ specialdeplibs="-lgcc"
+ ;;
+ *)
+ specialdeplibs=
+ ;;
+ esac
+
libs=
# Find all interdependent deplibs by searching for libraries
# that are linked more than once (e.g. -la -lb -la)
esac
# test for cygwin because mv fails w/o .exe extensions
case $host in
- *cygwin*) exeext=.exe ;;
+ *cygwin*)
+ exeext=.exe
+ outputname=`echo $outputname|${SED} 's,.exe$,,'` ;;
*) exeext= ;;
esac
$rm $output
destfile="$destdir/$destfile"
fi
+ # If the file is missing, and there is a .exe on the end, strip it
+ # because it is most likely a libtool script we actually want to
+ # install
+ stripped_ext=""
+ case $file in
+ *.exe)
+ if test ! -f "$file"; then
+ file=`echo $file|${SED} 's,.exe$,,'`
+ stripped_ext=".exe"
+ fi
+ ;;
+ esac
+
# Do a test to see if this is really a libtool program.
case $host in
*cygwin*|*mingw*)
$echo "$modename: error: cannot create temporary directory \`$tmpdir'" 1>&2
continue
fi
- file=`$echo "X$file" | $Xsed -e 's%^.*/%%'`
+ file=`$echo "X$file$stripped_ext" | $Xsed -e 's%^.*/%%'`
outputname="$tmpdir/$file"
# Replace the output file specification.
relink_command=`$echo "X$relink_command" | $Xsed -e 's%@OUTPUT@%'"$outputname"'%g'`
fi
else
# Install the binary that we compiled earlier.
- file=`$echo "X$file" | $Xsed -e "s%\([^/]*\)$%$objdir/\1%"`
+ file=`$echo "X$file$stripped_ext" | $Xsed -e "s%\([^/]*\)$%$objdir/\1%"`
fi
fi
noinst_HEADERS = foo.h
-bin_PROGRAMS = mdemo mdemo.static
+bin_PROGRAMS = mdemo mdemo_static
## use @LIBLTDL@ because some broken makes do not accept macros in targets
## we can only do this because our LIBLTDL does not contain ${top_builddir}
fi
if test "$shlibpath_overrides_runpath" != yes; then
- rm -f $objdir/lt-hell || exit 1
- cp $objdir/hell $objdir/lt-hell || exit 1
+ rm -f $objdir/lt-hell$EXEEXT || exit 1
+ cp $objdir/hell$EXEEXT $objdir/lt-hell$EXEEXT || exit 1
echo "running ../demo/hell with installed libhello.la"
if ./hell; then
echo "Worked, as expected"
echo "shlibpath_overrides_runpath should be set to yes"
status=1
fi
- rm -f $objdir/lt-hell
+ rm -f $objdir/lt-hell$EXEEXT
fi
exit $status
echo "Executing uninstalled programs in ../demo"
status=0
-if ../demo/hell.static| grep 'Welcome to GNU Hell'; then :
+if ../demo/hell_static| grep 'Welcome to GNU Hell'; then :
else
- echo "$0: cannot execute ../demo/hell.static" 1>&2
+ echo "$0: cannot execute ../demo/hell_static" 1>&2
status=1
fi
echo "= Executing installed programs"
status=0
-if $prefix/bin/hell.static | grep 'Welcome to GNU Hell'; then :
+if $prefix/bin/hell_static | grep 'Welcome to GNU Hell'; then :
else
- echo "$0: cannot execute $prefix/bin/hell.static" 1>&2
+ echo "$0: cannot execute $prefix/bin/hell_static" 1>&2
status=1
fi
echo "Executing uninstalled programs in ../depdemo"
status=0
-if ../depdemo/depdemo.static; then :
+if ../depdemo/depdemo_static; then :
else
- echo "$0: cannot execute ../depdemo/depdemo.static" 1>&2
+ echo "$0: cannot execute ../depdemo/depdemo_static" 1>&2
status=1
fi
echo "= Executing installed programs"
status=0
-if $prefix/bin/depdemo.static; then :
+if $prefix/bin/depdemo_static; then :
else
- echo "$0: cannot execute $prefix/bin/depdemo.static" 1>&2
+ echo "$0: cannot execute $prefix/bin/depdemo_static" 1>&2
status=1
fi
echo "= Making programs in ../mdemo (dry run)"
ls -l . $objdir > $before
-force_dry_run=yes $make mdemo$EXEEXT mdemo.static 1>&2 || exit $?
+force_dry_run=yes $make mdemo$EXEEXT mdemo_static$EXEEXT 1>&2 || exit $?
ls -l . $objdir > $after
cmp $before $after > /dev/null || exit 1
# Now really make them
echo "= Making programs in ../mdemo"
-$make mdemo$EXEEXT mdemo.static || exit 1
+$make mdemo$EXEEXT mdemo_static$EXEEXT || exit 1
echo "= Running $make install in ../mdemo (dry run)"
# Libtool does not create these directories
echo "= Running $make uninstall in ../mdemo (dry run)"
# Libtool does not uninstall the programs, remove them first
-rm -f $prefix/bin/mdemo$EXEEXT $prefix/bin/mdemo.static
+rm -f $prefix/bin/mdemo$EXEEXT $prefix/bin/mdemo_static$EXEEXT
ls -l . $objdir > $before
ls -lR $prefix >> $before
force_dry_run=yes $make uninstall 1>&2 || exit $?
echo "Executing uninstalled programs in ../mdemo"
status=0
-if ../mdemo/mdemo.static ../mdemo/foo1.la ../mdemo/libfoo2.la; then :
+if ../mdemo/mdemo_static ../mdemo/foo1.la ../mdemo/libfoo2.la; then :
else
- echo "$0: execution of ../mdemo/mdemo.static failed" 1>&2
+ echo "$0: execution of ../mdemo/mdemo_static failed" 1>&2
status=1
fi
echo "= Executing installed programs"
status=0
-if $prefix/bin/mdemo.static $prefix/lib/foo1.la $prefix/lib/libfoo2.la; then :
+if $prefix/bin/mdemo_static $prefix/lib/foo1.la $prefix/lib/libfoo2.la; then :
else
- echo "$0: cannot execute $prefix/bin/mdemo.static" 1>&2
+ echo "$0: cannot execute $prefix/bin/mdemo_static" 1>&2
status=1
fi
cd ../demo || exit 77
echo "removing libhello.la and hell from ../demo"
-rm -f libhello.la hell
+rm -f libhello.la hell$EXEEXT
echo "linking hell with a broken ../demo/libhello.la"
-if $make hell libhello_la_OBJECTS=hello.lo; then
+if $make hell$EXEEXT libhello_la_OBJECTS=hello.lo; then
echo "= Succeeded: this means the installed library was used, which is wrong"
status=1
fi
-rm -f libhello.la hell
+rm -f libhello.la hell$EXEEXT
exit $status