diff: linux bug fix
Fergus Henderson
fjh at hydra.cs.mu.oz.au
Wed Jun 4 04:14:22 AEST 1997
Fix a bug that meant that the source distribution didn't compile
properly on Linux.
configure.in:
Mmake.common.in:
library/Mmakefile:
On systems for which we build both `.pic_o' files and `.o' files,
don't remove the intermediate `.c' files in the library directory.
This avoids compiling things to C twice, and also avoids problems
when bootstrapping from the source distribution.
cvs diff: Diffing .
Index: Mmake.common.in
===================================================================
RCS file: /home/staff/zs/imp/mercury/Mmake.common.in,v
retrieving revision 1.16
diff -u -r1.16 Mmake.common.in
--- Mmake.common.in 1997/02/07 14:18:24 1.16
+++ Mmake.common.in 1997/06/03 18:06:58
@@ -64,6 +64,13 @@
# just reuse the .o files.
EXT_FOR_PIC_OBJECTS = @EXT_FOR_PIC_OBJECTS@
+# Set LIBRARY_RM_C as `:' if EXT_FOR_PIC_OBJECTS is `pic_o', or `$(RM_C)'
+# otherwise. This is used to ensure that in cases when we're building
+# both `.o' and `.pic_o' files, we don't remove the intermediate `.c' files.
+# This avoids compiling things to C twice, and also avoids problems when
+# bootstrapping from the source distribution.
+LIBRARY_RM_C = @LIBRARY_RM_C@
+
# Specify the command to link a shared library
# This is only used if EXT_FOR_SHARED_LIB was defined as `so' above.
# LINK_SHARED_OBJ = ld -shared # for Irix 5
Index: configure.in
===================================================================
RCS file: /home/staff/zs/imp/mercury/configure.in,v
retrieving revision 1.90
diff -u -r1.90 configure.in
--- configure.in 1997/04/26 07:56:41 1.90
+++ configure.in 1997/06/03 05:00:15
@@ -1355,11 +1355,25 @@
AC_MSG_RESULT(no)
;;
esac
+
+case $EXT_FOR_PIC_OBJECTS in
+ o)
+ LIBRARY_RM_C='$(RM_C)'
+ ;;
+ *)
+ # If we're going to be building both `.pic_o' files
+ # and `.o' files, then we should not remove the generated `.c'
+ # files in the library directory after building the `.o' files.
+ LIBRARY_RM_C=:
+ ;;
+esac
+
AC_SUBST(LINK_SHARED_OBJ)
AC_SUBST(CFLAGS_FOR_PIC)
AC_SUBST(EXT_FOR_PIC_OBJECTS)
AC_SUBST(EXT_FOR_SHARED_LIB)
AC_SUBST(SHARED_LIBS)
+AC_SUBST(LIBRARY_RM_C)
#-----------------------------------------------------------------------------#
if test "$BOOTSTRAP_MC" = ""; then
BOOTSTRAP_MC=mc
cvs diff: Diffing bindist
cvs diff: Diffing boehm_gc
cvs diff: Diffing boehm_gc/Mac_files
cvs diff: Diffing boehm_gc/cord
cvs diff: Diffing boehm_gc/cord/private
cvs diff: Diffing boehm_gc/include
cvs diff: Diffing boehm_gc/include/private
cvs diff: Diffing bytecode
cvs diff: Diffing compiler
cvs diff: Diffing compiler/notes
cvs diff: Diffing doc
cvs diff: Diffing library
Index: library/Mmakefile
===================================================================
RCS file: /home/staff/zs/imp/mercury/library/Mmakefile,v
retrieving revision 1.3
diff -u -r1.3 Mmakefile
--- Mmakefile 1997/05/17 03:27:07 1.3
+++ Mmakefile 1997/06/03 04:59:51
@@ -16,6 +16,12 @@
#-----------------------------------------------------------------------------#
+# If we're going to generate both `.o' files and `.pic_o' files, then
+# don't remove the intermediate `.c' files.
+RM_C = $(LIBRARY_RM_C)
+
+#-----------------------------------------------------------------------------#
+
# Specify which compilers to use to compile the library.
# Don't change these without good reason - if you want to
# do a temporary change, change ../Mmake.params.
cvs diff: Diffing lp_solve
cvs diff: Diffing lp_solve/lp_examples
cvs diff: Diffing profiler
cvs diff: Diffing runtime
cvs diff: Diffing runtime/machdeps
cvs diff: Diffing samples
cvs diff: Diffing samples/c_interface
cvs diff: Diffing samples/c_interface/c_calls_mercury
cvs diff: Diffing samples/c_interface/cplusplus_calls_mercury
cvs diff: Diffing samples/c_interface/mercury_calls_c
cvs diff: Diffing samples/c_interface/mercury_calls_cplusplus
cvs diff: Diffing samples/diff
cvs diff: Diffing scripts
cvs diff: Diffing tools
cvs diff: Diffing trial
cvs diff: Diffing util
--
Fergus Henderson <fjh at cs.mu.oz.au> | "I have always known that the pursuit
WWW: <http://www.cs.mu.oz.au/~fjh> | of excellence is a lethal habit"
PGP: finger fjh at 128.250.37.3 | -- the last words of T. S. Garp.
More information about the developers
mailing list