This is the mail archive of the
newlib@sourceware.cygnus.com
mailing list for the newlib project.
`make check' with --enable-shared
- To: binutils at sourceware dot cygnus dot com, gdb at sourceware dot cygnus dot com, newlib at sourceware dot cygnus dot com
- Subject: `make check' with --enable-shared
- From: Alexandre Oliva <aoliva at cygnus dot com>
- Date: 31 Mar 2000 00:19:43 -0300
- Organization: Cygnus Solutions, a Red Hat Company
When the srcware tree is configured with --enable-shared, the `expect'
program won't run properly. Jim Wilson found out gdb has a local hack
to set LD_LIBRARY_PATH, but, AFAIK, no other project has been hacked
similarly.
Here's a simple patch that renders that gdb hack obsolete, and
arranges for all packages to automatically benefit from it. I'm not
reverting the gdb hack, though. I'll leave that to the gdb hackers
:-)
Here's the patch I'm checking in, approved by Jim Wilson:
Index: expect/ChangeLog
from Alexandre Oliva <oliva@lsd.ic.unicamp.br>
* Makefile.in (expect-bld.sh): New wrapper script.
(all): Depend on it.
(LOCAL_EXPECT): Use it.
Index: expect/Makefile.in
===================================================================
RCS file: /cvs/cvsfiles/devo/expect/Makefile.in,v
retrieving revision 1.98
diff -u -r1.98 Makefile.in
--- expect/Makefile.in 1999/06/01 20:54:07 1.98
+++ expect/Makefile.in 2000/03/31 03:13:04
@@ -337,6 +337,20 @@
info:
dvi:
+# CYGNUS LOCAL aoliva
+LOCAL_EXPECT=$(SHELL) ./expect-bld.sh
+all: expect-bld.sh
+# Run expect within the build tree
+expect-bld.sh: Makefile
+ -rm -f $@ $@T
+ echo "#! $(SHELL)" > $@T
+ r=`pwd`; for var in LD_LIBRARY_PATH SHLIB_PATH ; do \
+ echo "$$var=$$r:$$r/../tk/unix:$$r/../tcl/unix\$${$$var+:\$$$$var}; export $$var" >> $@T ; \
+ done; echo "exec $$r/expect \$${1+\"\$$@\"}" >> $@T
+ chmod +x $@T
+ mv $@T $@
+# END CYGNUS LOCAL
+
# build expect binary that does not depend on Expect's shared libs
expect$(EXEEXT): exp_main_exp.o $(EXP_UNSHARED_LIB_FILE)
$(CC) $(XCFLAGS) @TCL_LD_FLAGS@ -o expect$(EXEEXT) exp_main_exp.o @EXP_BUILD_LIB_SPEC@ $(TCLLIB) $(EXP_AND_TCL_LIBS)
Index: dejagnu/ChangeLog
from Alexandre Oliva <oliva@lsd.ic.unicamp.br>
* runtest (expectbin): After choosing expectbin, try
$expectbin-bld.sh and use it instead.
Index: dejagnu/runtest
===================================================================
RCS file: /cvs/cvsfiles/devo/dejagnu/runtest,v
retrieving revision 1.24
diff -u -r1.24 runtest
--- dejagnu/runtest 1998/08/25 00:21:53 1.24
+++ dejagnu/runtest 2000/03/31 03:14:28
@@ -61,6 +61,13 @@
exit 1
fi
+# CYGNUS LOCAL aoliva
+# This wrapper script will set up run-time library search PATHs
+if [ -x "$expectbin-bld.sh" ]; then
+ expectbin="${CONFIG_SHELL-/bin/sh} $expectbin-bld.sh"
+fi
+# END CYGNUS LOCAL
+
#
# Extract a few options from the option list.
#
--
Alexandre Oliva Enjoy Guaranį, see http://www.ic.unicamp.br/~oliva/
Cygnus Solutions, a Red Hat company aoliva@{redhat, cygnus}.com
Free Software Developer and Evangelist CS PhD student at IC-Unicamp
oliva@{lsd.ic.unicamp.br, gnu.org} Write to mailing lists, not to me