mirror of
git://git.sv.gnu.org/autoconf
synced 2024-11-21 01:01:48 +08:00
219 lines
7.1 KiB
Makefile
219 lines
7.1 KiB
Makefile
# Makefile for Autoconf.
|
|
# Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc.
|
|
|
|
# This program is free software; you can redistribute it and/or modify
|
|
# it under the terms of the GNU General Public License as published by
|
|
# the Free Software Foundation; either version 2, or (at your option)
|
|
# any later version.
|
|
|
|
# This program is distributed in the hope that it will be useful,
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
# GNU General Public License for more details.
|
|
|
|
# You should have received a copy of the GNU General Public License
|
|
# along with this program; if not, write to the Free Software
|
|
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
|
|
|
#### Start of system configuration section. ####
|
|
|
|
srcdir = @srcdir@
|
|
VPATH = @srcdir@
|
|
|
|
INSTALL = @INSTALL@
|
|
INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
|
INSTALL_DATA = @INSTALL_DATA@
|
|
MAKEINFO = makeinfo
|
|
TEXI2DVI = texi2dvi
|
|
M4 = @M4@
|
|
|
|
PROGS = autoconf autoheader autoreconf autoupdate ifnames @PROGS@
|
|
# Path of the perl interpreter.
|
|
PERL = @PERL@
|
|
|
|
prefix = @prefix@
|
|
exec_prefix = @exec_prefix@
|
|
|
|
# Directory in which to install scripts.
|
|
bindir = $(exec_prefix)/bin
|
|
|
|
# Directory in which to install library files.
|
|
datadir = $(prefix)/lib
|
|
acdatadir = $(datadir)/autoconf
|
|
|
|
# Directory in which to install documentation info files.
|
|
infodir = $(prefix)/info
|
|
|
|
#### End of system configuration section. ####
|
|
|
|
SHELL = /bin/sh
|
|
|
|
SUBDIRS = testsuite
|
|
# Files that can be generated, but should be up to date for a distribution.
|
|
DISTDEP = info Makefile
|
|
# Files to distribute.
|
|
DISTFILES = COPYING ChangeLog INSTALL Makefile.in NEWS README TODO \
|
|
acconfig.h acfunctions acgeneral.m4 acheaders acidentifiers \
|
|
acmakevars acoldnames.m4 acprograms acspecific.m4 autoconf.info* \
|
|
autoconf.sh autoconf.texi install.texi \
|
|
autoheader.sh autoreconf.sh autoscan.pl autoupdate.sh \
|
|
shindent.sh ifnames.sh \
|
|
config.guess config.sub configure configure.in \
|
|
install.sh mkinstalldirs texinfo.tex \
|
|
testsuite/Makefile.in testsuite/config/*.exp \
|
|
testsuite/lib/*.exp testsuite/autoconf.[gs]/*.exp \
|
|
standards.texi make-stds.texi standards.info*
|
|
|
|
editsh = sed -e 's,@''datadir''@,$(acdatadir),g' -e 's,@''M4''@,$(M4),g'
|
|
editpl = sed -e 's,@''datadir''@,$(acdatadir),g' -e 's,@''PERL''@,$(PERL),g'
|
|
|
|
all: ${PROGS}
|
|
|
|
autoconf: autoconf.sh
|
|
rm -f $@ $@.tmp
|
|
$(editsh) $(srcdir)/autoconf.sh > $@.tmp && mv $@.tmp $@ && chmod +x $@
|
|
|
|
autoheader: autoheader.sh
|
|
rm -f $@ $@.tmp
|
|
$(editsh) $(srcdir)/autoheader.sh > $@.tmp && mv $@.tmp $@ && chmod +x $@
|
|
|
|
autoreconf: autoreconf.sh
|
|
rm -f $@ $@.tmp
|
|
$(editsh) $(srcdir)/autoreconf.sh > $@.tmp && mv $@.tmp $@ && chmod +x $@
|
|
|
|
autoupdate: autoupdate.sh
|
|
rm -f $@ $@.tmp
|
|
$(editsh) $(srcdir)/autoupdate.sh > $@.tmp && mv $@.tmp $@ && chmod +x $@
|
|
|
|
shindent: shindent.sh
|
|
rm -f $@ $@.tmp
|
|
$(editsh) $(srcdir)/shindent.sh > $@.tmp && mv $@.tmp $@ && chmod +x $@
|
|
|
|
ifnames: ifnames.sh
|
|
rm -f $@ $@.tmp
|
|
$(editsh) $(srcdir)/ifnames.sh > $@.tmp && mv $@.tmp $@ && chmod +x $@
|
|
|
|
autoscan: autoscan.pl
|
|
rm -f $@ $@.tmp
|
|
$(editpl) $(srcdir)/autoscan.pl > $@.tmp && mv $@.tmp $@ && chmod +x $@
|
|
|
|
info: autoconf.info @standards_info@ INSTALL
|
|
|
|
autoconf.info: autoconf.texi install.texi
|
|
$(MAKEINFO) -I$(srcdir) $(srcdir)/autoconf.texi --output=$@
|
|
|
|
INSTALL: install.texi
|
|
$(MAKEINFO) -I$(srcdir) $(srcdir)/install.texi --output=$@ \
|
|
--no-headers --no-validate
|
|
|
|
standards.info: standards.texi make-stds.texi
|
|
$(MAKEINFO) -I$(srcdir) $(srcdir)/standards.texi --output=$@
|
|
|
|
dvi: autoconf.dvi @standards_dvi@
|
|
|
|
autoconf.dvi: autoconf.texi
|
|
$(TEXI2DVI) $(srcdir)/autoconf.texi
|
|
|
|
standards.dvi: standards.texi make-stds.texi
|
|
$(TEXI2DVI) $(srcdir)/standards.texi
|
|
|
|
check: all
|
|
rootme=`pwd`; cd testsuite && ${MAKE} $@ AUTOCONF=$$rootme/autoconf \
|
|
AUTOCONFFLAGS="-m $$rootme"
|
|
installcheck: all install
|
|
cd testsuite && ${MAKE} AUTOCONF=${bindir}/autoconf $@
|
|
|
|
installdirs:
|
|
$(SHELL) ${srcdir}/mkinstalldirs $(bindir) $(infodir) $(acdatadir)
|
|
|
|
# References to install-info have been removed until it's released.
|
|
install: all acgeneral.m4 acoldnames.m4 acspecific.m4 acconfig.h \
|
|
installdirs install-info
|
|
$(INSTALL_PROGRAM) autoconf $(bindir)/autoconf
|
|
$(INSTALL_PROGRAM) autoheader $(bindir)/autoheader
|
|
$(INSTALL_PROGRAM) autoreconf $(bindir)/autoreconf
|
|
$(INSTALL_PROGRAM) autoupdate $(bindir)/autoupdate
|
|
$(INSTALL_PROGRAM) ifnames $(bindir)/ifnames
|
|
$(INSTALL_DATA) $(srcdir)/acgeneral.m4 $(acdatadir)/acgeneral.m4
|
|
$(INSTALL_DATA) $(srcdir)/acoldnames.m4 $(acdatadir)/acoldnames.m4
|
|
$(INSTALL_DATA) $(srcdir)/acspecific.m4 $(acdatadir)/acspecific.m4
|
|
$(INSTALL_DATA) $(srcdir)/acconfig.h $(acdatadir)/acconfig.h
|
|
-if test -f autoscan; then \
|
|
$(INSTALL_PROGRAM) autoscan $(bindir)/autoscan; \
|
|
else :; fi
|
|
-if test -f shindent; then \
|
|
$(INSTALL_PROGRAM) shindent $(bindir)/shindent; \
|
|
$(INSTALL_DATA) $(srcdir)/acfunctions $(acdatadir)/acfunctions; \
|
|
$(INSTALL_DATA) $(srcdir)/acheaders $(acdatadir)/acheaders; \
|
|
$(INSTALL_DATA) $(srcdir)/acidentifiers $(acdatadir)/acidentifiers; \
|
|
$(INSTALL_DATA) $(srcdir)/acprograms $(acdatadir)/acprograms; \
|
|
$(INSTALL_DATA) $(srcdir)/acmakevars $(acdatadir)/acmakevars; \
|
|
else :; fi
|
|
|
|
install-info: info installdirs
|
|
-test -f autoconf.info || cd $(srcdir); \
|
|
for i in autoconf.info*; do \
|
|
$(INSTALL_DATA) $$i $(infodir)/$$i; \
|
|
done
|
|
-test -f standards.info || cd $(srcdir); \
|
|
for i in standards.info*; do \
|
|
$(INSTALL_DATA) $$i $(infodir)/$$i; \
|
|
done
|
|
|
|
uninstall:
|
|
rm -f $(bindir)/autoconf $(bindir)/autoheader $(bindir)/autoscan
|
|
rm -f $(bindir)/autoreconf $(bindir)/autoupdate
|
|
rm -f $(bindir)/shindent $(bindir)/ifnames
|
|
rm -fr $(acdatadir)
|
|
cd $(infodir); rm -f autoconf.info*
|
|
if test -f standards.info || test -f $(srcdir)/standards.info; \
|
|
then cd $(infodir); rm -f standards.info*; fi
|
|
|
|
configure: configure.in acgeneral.m4 acspecific.m4 acoldnames.m4
|
|
cd $(srcdir); \
|
|
rm -f $@ $@.tmp; \
|
|
$(M4) acgeneral.m4 acspecific.m4 acoldnames.m4 configure.in > $@.tmp && \
|
|
mv $@.tmp $@ && \
|
|
chmod +x $@
|
|
Makefile: Makefile.in config.status
|
|
./config.status
|
|
config.status: configure
|
|
./config.status --recheck
|
|
|
|
clean mostlyclean distclean realclean::
|
|
for dir in $(SUBDIRS); do \
|
|
echo making $@ in $$dir ; \
|
|
(cd $$dir; $(MAKE) $@) ; \
|
|
done
|
|
|
|
clean mostlyclean distclean realclean::
|
|
rm -f autoconf autoheader autoscan autoreconf autoupdate
|
|
rm -f shindent ifnames *.tmp
|
|
rm -f *.aux *.cp *.cps *.dvi *.fn *.fns *.ky *.kys *.log
|
|
rm -f *.pg *.pgs *.toc *.tp *.tps *.vr *.vrs *.ma *.mas
|
|
|
|
distclean realclean::
|
|
rm -f Makefile config.status config.cache config.log
|
|
|
|
realclean::
|
|
rm -f TAGS *.info* INSTALL
|
|
|
|
TAGS:
|
|
etags ${srcdir}/*.m4 ${srcdir}/*.sh ${srcdir}/[a-z]*.in ${srcdir}/*.texi
|
|
|
|
# Don't depend on DISTFILES because there's no rule for "standards.info*".
|
|
dist: $(DISTDEP)
|
|
distname=`sed -e '/define(AC_ACVERSION,/!d' \
|
|
-e 's/[^0-9.]*\([0-9.]*\).*/autoconf-\1/' -e q acgeneral.m4`; \
|
|
rm -fr $$distname; \
|
|
mkdir $$distname $$distname/testsuite $$distname/testsuite/config \
|
|
$$distname/testsuite/lib $$distname/testsuite/autoconf.g \
|
|
$$distname/testsuite/autoconf.s; \
|
|
for file in $(DISTFILES); do \
|
|
ln $$file $$distname/$$file \
|
|
|| { echo copying $$file instead; cp -p $$file $$distname/$$file;}; \
|
|
done; \
|
|
chmod -R a+rX $$distname; \
|
|
tar -chz -f $$distname.tar.gz $$distname; \
|
|
rm -fr $$distname
|