Commit 90f86cb5 by Alexandre Oliva Committed by Alexandre Oliva

Makefile.in (AR, RANLIB): Add, for substitutions.

* Makefile.in (AR, RANLIB): Add, for substitutions.
(all-unilib, $(LIBG2C)): Depend on object lists, not
convenience libraries.
(s-libe77): Renamed from libE77.la; build object list.
(install): Do not move libraries to libdir.
(mostlyclean, clean): Adjust.
* libF77/Makefile.in (RANLIB): Add.
(LINK): Remove.
(../s-libf77): Renamed from ../libF77.la; build object list.
(../libfrtbegin.a): Remove target first.  Don't use $<.
(all, clean, distclean): Adjust.
* libF77/configure.in: Substitute RANLIB.
* libF77/configure: Rebuilt.
* libI77/Makefile.in (LINK): Delete.
(../s-libi77): Renamed from ../libI77.la; build object list.
(all, clean, distclean): Adjust.
* libU77/Makefile.in: Likewise.

From-SVN: r47605
parent 9471d3e2
2001-12-04 Alexandre Oliva <aoliva@redhat.com>
* Makefile.in (AR, RANLIB): Add, for substitutions.
(all-unilib, $(LIBG2C)): Depend on object lists, not
convenience libraries.
(s-libe77): Renamed from libE77.la; build object list.
(install): Do not move libraries to libdir.
(mostlyclean, clean): Adjust.
* libF77/Makefile.in (RANLIB): Add.
(LINK): Remove.
(../s-libf77): Renamed from ../libF77.la; build object list.
(../libfrtbegin.a): Remove target first. Don't use $<.
(all, clean, distclean): Adjust.
* libF77/configure.in: Substitute RANLIB.
* libF77/configure: Rebuilt.
* libI77/Makefile.in (LINK): Delete.
(../s-libi77): Renamed from ../libI77.la; build object list.
(all, clean, distclean): Adjust.
* libU77/Makefile.in: Likewise.
2001-12-02 Toon Moene <toon@moene.indiv.nluug.nl>
PR fortran/4885
......
# Makefile for GNU F77 compiler runtime.
# Copyright (C) 1995-1998 Free Software Foundation, Inc.
# Copyright (C) 1995-1998, 2001 Free Software Foundation, Inc.
# Contributed by Dave Love (d.love@dl.ac.uk).
#
#This file is part of GNU Fortran.
......@@ -61,6 +61,8 @@ INSTALL_DATA = @INSTALL_DATA@
LIBTOOL = @LIBTOOL@
CC = @CC@
CFLAGS = @CFLAGS@
AR = @AR@
RANLIB = @RANLIB@
# List of variables to pass to sub-makes.
# Quote this way so that it can be used to set shell variables too.
......@@ -118,24 +120,34 @@ all: all-unilib
# meant to be invoked via multi-do for multilibs.
# Its dependencies can be satisfied in parallel. The [fiu]77 targets
# always invoke sub makes to check dependencies in the subdirs, else we'd
# update stamp files (object file lists, actually, see the subdir
# makefiles) on which the $(LIBG2C) depends. The stamp files
# s-lib[fiu]77 are intentionally not targets, since we're only meant
# to come in at the level of this target. The [fiu]77 targets always
# invoke sub makes to check dependencies in the subdirs, else we'd
# have to maintain them at this level; we live with the overhead of
# some recursive makes which may do nothing.
all-unilib: i77 f77 u77 libE77.la
all-unilib: i77 f77 u77 s-libe77
$(MAKE) $(FLAGS_TO_PASS) $(LIBG2C)
i77 f77 u77: g2c.h
# This target should normally only get invoked via `all-unilib' --
# after all's well in the subdirs -- actually to assemble the library.
# The stamp files contain the object lists of each component of the
# library. The point of breaking them up is to avoid command-line
# length limitations.
$(LIBG2C): libF77.la libI77.la libU77.la libE77.la
rm -f $@ ;\
set -e; \
$(LIBG2C): s-libi77 s-libf77 s-libu77 s-libe77
$(LIBTOOL) --mode=link $(CC) -o $@ \
-version-info $(VERSION_MAJOR):$(VERSION_MINOR):$(VERSION_SUB) \
-rpath $(prefix)/lib libE77.la libF77.la libI77.la libU77.la -lc -lm
-rpath $(prefix)/lib \
-objectlist s-libe77 \
-objectlist s-libf77 \
-objectlist s-libi77 \
-objectlist s-libu77 \
-lc -lm
i77:
cd libI77; $(MAKE) $(FLAGS_TO_PASS) all
......@@ -146,18 +158,19 @@ f77:
u77:
cd libU77; $(MAKE) $(FLAGS_TO_PASS) all
libE77.la: f2cext.c
rm -f $@
s-libe77: f2cext.c
if [ -d libE77 ]; then rm -f libE77/*.o libE77/*.lo; else mkdir libE77; fi
-rm -f $@.T $@
for name in $(F2CEXT); \
do \
echo $${name}; \
$(LIBTOOL) --mode=compile $(CC) -c -I. -I$(srcdir) -I../../include \
$(CPPFLAGS) $(CFLAGS) -DL$${name} $(srcdir)/f2cext.c \
-o libE77/L$${name}.o ; \
-o libE77/L$${name}.lo ; \
if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
echo libE77/L$${name}.lo >> $@.T; \
done
$(LIBTOOL) --mode=link $(CC) -o libE77.la libE77/*.lo
mv $@.T $@
f2cext.c: g2c.h
......@@ -192,7 +205,6 @@ check:
install: all
$(LIBTOOL) --mode=install $(INSTALL_DATA) $(LIBG2C) $(libsubdir)/$(MULTISUBDIR)
(cd $(libsubdir)/$(MULTISUBDIR) ; mv -f $(LIBG2C_BASE).* $(prefix)/lib)
$(INSTALL_DATA) libfrtbegin.a $(libsubdir)/$(MULTISUBDIR)
$(RANLIB) $(libsubdir)/$(MULTISUBDIR)/libfrtbegin.a
$(INSTALL_DATA) g2c.h $(libsubdir)/include/g2c.h
......@@ -220,7 +232,7 @@ mostlyclean:
rm -f $(LIBG2C) objlist
$(MAKE) DO=$@ DODIRS="$(SUBDIRS)" $(FLAGS_TO_PASS) subdir_do; \
$(MULTICLEAN) multi-clean DO=$@
rm -fr libE77 libE77.la
rm -fr libE77 s-libe77
clean: mostlyclean
rm -f config.log
......@@ -229,7 +241,7 @@ clean: mostlyclean
rm -rf .libs
distclean: clean
rm -f g2c.h libE77.la
rm -f g2c.h s-libe77
$(MAKE) DO=$@ DODIRS="$(SUBDIRS)" $(FLAGS_TO_PASS) subdir_do; \
$(MULTICLEAN) multi-clean DO=distclean
rm -f config.cache config.status Makefile
......
# Makefile for GNU F77 compiler runtime.
# Copyright 1990 - 1994 by AT&T Bell Laboratories and Bellcore (see the
# file `Notice').
# Portions of this file Copyright (C) 1995-1998 Free Software Foundation, Inc.
# Portions of this file Copyright (C) 1995-1998, 2001 Free Software Foundation, Inc.
# Contributed by Dave Love (d.love@dl.ac.uk).
#
#This file is part of GNU Fortran.
......@@ -38,6 +38,7 @@ CFLAGS = @CFLAGS@
CPPFLAGS = @CPPFLAGS@
AR = @AR@
ARFLAGS = rc
RANLIB = @RANLIB@
@SET_MAKE@
SHELL = /bin/sh
......@@ -52,8 +53,6 @@ ALL_CFLAGS = -I. -I$(srcdir) -I$(G2C_H_DIR) -I$(F2C_H_DIR) $(CPPFLAGS) $(DEFS) $
.c.lo:
@LIBTOOL@ --mode=compile $(CC) -c -DSkip_f2c_Undefs $(ALL_CFLAGS) $<
LINK = @LIBTOOL@ --mode=link $(CC) -o $@
MISC = F77_aloc.lo VersionF.lo s_rnge.lo abort_.lo getarg_.lo iargc_.lo\
getenv_.lo signal_.lo s_stop.lo s_paus.lo system_.lo cabs.lo\
derf_.lo derfc_.lo erf_.lo erfc_.lo sig_die.lo exit_.lo setarg.lo setsig.lo
......@@ -80,10 +79,13 @@ F90BIT = lbitbits.lo lbitshft.lo qbitbits.lo qbitshft.lo
OBJS = $(MISC) $(POW) $(CX) $(DCX) $(REAL) $(DBL) $(INT) \
$(HALF) $(CMP) $(EFL) $(CHAR) $(F90BIT)
all: ../libF77.la ../libfrtbegin.a
all: ../s-libf77 ../libfrtbegin.a
../libF77.la: $(OBJS)
$(LINK) $(OBJS)
../s-libf77: $(OBJS)
-rm -f $@.T $@
objs='$(OBJS)'; for name in $$objs; do \
echo libF77/$${name} >> $@.T; done
mv $@.T $@
Makefile: Makefile.in config.status
$(SHELL) config.status
......@@ -104,7 +106,8 @@ frtbegin.o : main.c
$(CC) -c $(ALL_CFLAGS) $(srcdir)/main.c -o $@
../libfrtbegin.a: frtbegin.o
$(AR) $(ARFLAGS) $@ $<
-rm -f $@
$(AR) $(ARFLAGS) $@ frtbegin.o
$(RANLIB) $@
F77_aloc.lo: F77_aloc.c
......@@ -241,10 +244,10 @@ mostlyclean:
clean: mostlyclean
rm -f config.log
rm -f ../libF77.la
rm -f ../s-libf77
distclean: clean
rm -f config.cache config.status Makefile ../libF77.la configure
rm -f config.cache config.status Makefile ../s-libf77 configure
maintainer-clean:
......
# Process this file with autoconf to produce a configure script.
# Copyright (C) 1995, 1997, 1998 Free Software Foundation, Inc.
# Copyright (C) 1995, 1997, 1998, 2001 Free Software Foundation, Inc.
# Contributed by Dave Love (d.love@dl.ac.uk).
#
#This file is part of GNU Fortran.
......@@ -37,6 +37,11 @@ AC_SUBST(LIBTOOL)
test "$AR" || AR=ar
AC_SUBST(AR)
if test "$RANLIB"; then :
AC_SUBST(RANLIB)
else
AC_PROG_RANLIB
fi
AC_PROG_MAKE_SET
dnl Checks for libraries.
......
......@@ -51,18 +51,19 @@ ALL_CFLAGS = -I. -I$(srcdir) -I$(G2C_H_DIR) -I$(F2C_H_DIR) $(CPPFLAGS) \
.c.lo:
@LIBTOOL@ --mode=compile $(CC) -c -DSkip_f2c_Undefs -DAllow_TYQUAD $(ALL_CFLAGS) $<
LINK = @LIBTOOL@ --mode=link $(CC) -o $@
OBJS = VersionI.lo backspace.lo close.lo dfe.lo dolio.lo due.lo endfile.lo err.lo \
fmt.lo fmtlib.lo iio.lo ilnw.lo inquire.lo lread.lo lwrite.lo open.lo \
rdfmt.lo rewind.lo rsfe.lo rsli.lo rsne.lo sfe.lo sue.lo typesize.lo uio.lo \
util.lo wref.lo wrtfmt.lo wsfe.lo wsle.lo wsne.lo xwsne.lo \
ftell_.lo
all: ../libI77.la
all: ../s-libi77
../libI77.la: $(OBJS)
$(LINK) $(OBJS)
../s-libi77: $(OBJS)
-rm -f $@.T $@
objs='$(OBJS)'; for name in $$objs; do \
echo libI77/$${name} >> $@.T; done
mv $@.T $@
Makefile: Makefile.in config.status
$(SHELL) config.status
......@@ -157,10 +158,10 @@ mostlyclean:
rm -rf .libs
clean: mostlyclean
rm -f config.log ../libI77.la
rm -f config.log ../s-libi77
distclean: clean
rm -f config.cache config.status Makefile ../libI77.la configure
rm -f config.cache config.status Makefile ../s-libi77 configure
maintainer-clean:
......
# Makefile for GNU F77 compiler runtime, libc interface.
# Copyright (C) 1995-1998 Free Software Foundation, Inc.
# Copyright (C) 1995-1998, 2001 Free Software Foundation, Inc.
# Contributed by Dave Love (d.love@dl.ac.uk).
#
#This file is part of the GNU Fortran libU77 library.
......@@ -55,8 +55,6 @@ G77DIR = ../../../gcc/
.c.lo:
@LIBTOOL@ --mode=compile $(CC) -c -DSkip_f2c_Undefs $(ALL_CFLAGS) $<
LINK = @LIBTOOL@ --mode=link $(CC) -o $@
OBJS = VersionU.lo gerror_.lo perror_.lo ierrno_.lo itime_.lo time_.lo \
unlink_.lo fnum_.lo getpid_.lo getuid_.lo getgid_.lo kill_.lo rand_.lo \
srand_.lo irand_.lo sleep_.lo idate_.lo ctime_.lo etime_.lo \
......@@ -78,10 +76,13 @@ SRCS = Version.c gerror_.c perror_.c ierrno_.c itime_.c time_.c \
umask_.c sys_clock_.c date_.c second_.c flush1_.c mclock_.c \
alarm_.c datetime_.c
all: ../libU77.la
all: ../s-libu77
../libU77.la: $(OBJS)
$(LINK) $(OBJS)
../s-libu77: $(OBJS)
-rm -f $@.T $@
objs='$(OBJS)'; for name in $$objs; do \
echo libU77/$${name} >> $@.T; done
mv $@.T $@
Makefile: Makefile.in config.status
$(SHELL) config.status
......@@ -178,11 +179,11 @@ mostlyclean:
rm -rf .libs
clean: mostlyclean
rm -f config.log ../libU77.la
rm -f config.log ../s-libu77
distclean: clean
rm -f config.cache config.status Makefile config.h stamp.h \
../libU77.la configure
../s-libu77 configure
maintainer-clean:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment