summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorWichert Akkerman <wakkerma@debian.org>1999-11-25 02:14:53 +0000
committerWichert Akkerman <wakkerma@debian.org>1999-11-25 02:14:53 +0000
commit72c22a38a857b1685762b7fc51c91ad01027f464 (patch)
tree181311e764e764cc03d51abf9894caef17b7eafd /scripts
parentb3b861c1ac307cfe324c7295710e13060e6d1c9d (diff)
downloaddpkg-72c22a38a857b1685762b7fc51c91ad01027f464.tar.gz
Move the new buildsystem into the main branch
Diffstat (limited to 'scripts')
-rw-r--r--scripts/Makefile.am93
-rw-r--r--scripts/Makefile.in107
2 files changed, 107 insertions, 93 deletions
diff --git a/scripts/Makefile.am b/scripts/Makefile.am
deleted file mode 100644
index a3e5ad298..000000000
--- a/scripts/Makefile.am
+++ /dev/null
@@ -1,93 +0,0 @@
-## Process this file with automake to produce a Makefile.in
-
-AUTOMAKE_OPTIONS = 1.1 foreign
-
-## Directory definitions
-
-pkglibdir = $(libdir)/@PACKAGE@
-pkglocalstatedir = $(sharedstatedir)/@PACKAGE@
-
-parsechangelogdir = $(pkglibdir)/parsechangelog
-altssysconfdir = $(pkgsysconfdir)/alternatives
-altslocalstatedir = $(pkglocalstatedir)/alternatives
-
-# This should be $(pkgsysconfdir), but uses $(sysconfdir) for backwards compatibility.
-altssysconfdir = $(sysconfdir)/alternatives
-
-
-## Automake variables
-
-bin_SCRIPTS = dpkg-name dpkg-source dpkg-genchanges dpkg-gencontrol \
- dpkg-shlibdeps dpkg-buildpackage dpkg-parsechangelog \
- dpkg-distaddfile 822-date dpkg-scanpackages \
- dpkg-scansources dpkg-architecture
-
-sbin_SCRIPTS = update-rc.d update-alternatives \
- install-info dpkg-divert cleanup-info
-
-pkglib_SCRIPTS = controllib.pl
-
-lisp_LISP = debian-changelog-mode.el
-ELCFILES = debian-changelog-mode.elc
-
-man_MANS = dpkg-name.1 dpkg-source.1 822-date.1 update-rc.d.8 \
- update-alternatives.8 \
- install-info.8 dpkg-scanpackages.8 \
- dpkg-scansources.8 dpkg-architecture.1
-
-EXTRA_DIST = update-rc.d.pl \
- dpkg-name.sh dpkg-source.pl dpkg-genchanges.pl \
- dpkg-gencontrol.pl dpkg-shlibdeps.pl \
- dpkg-buildpackage.sh dpkg-parsechangelog.pl \
- dpkg-distaddfile.pl 822-date.pl dpkg-scanpackages.pl \
- update-alternatives.pl install-info.pl dpkg-divert.pl \
- cleanup-info.pl controllib.pl debian-changelog-mode.el \
- cl-debian.pl dpkg-architecture.pl dpkg-scansources.pl \
- $(man_MANS) README.alternatives
-
-noinst_DATA = cl-debian
-
-LSMANL = dpkg-gencontrol dpkg-genchanges dpkg-buildpackage \
- dpkg-distaddfile dpkg-parsechangelog dpkg-shlibdeps
-
-CLEANFILES = $(bin_SCRIPTS) $(sbin_SCRIPTS) $(noinst_DATA) $(ELCFILES)
-MAINTAINERCLEANFILES = $(srcdir)/Makefile.in $(srcdir)/elisp-comp
-
-## Rules
-
-.PHONY: install-data-local uninstall-local
-
-SUFFIXES = .pl .sh
-
-dpkg-scansources.8: dpkg-scansources.pl
- pod2man --section=8 $^ > $@
-
-%: %.pl
- sed -e "s:^#![:space:]*/usr/bin/perl:#! $(perlpath):; \
- s:\$$dpkglibdir[[:space:]]*=[[:space:]]*['\"][^'\"]*['\"]:\$$dpkglibdir=\"$(pkglibdir)\":; \
- s:\$$version[[:space:]]*=[[:space:]]*['\"][^'\"]*[\"']:\$$version=\"$(VERSION)\":" \
- < $< > $@.new
- chmod 755 $@.new
- mv $@.new $@
-
-%: %.sh
- sed -e "s:version=\"[^\"]*\":version=\"$(VERSION)\":" \
- < $< > $@.new
- chmod 755 $@.new
- mv $@.new $@
-
-install-data-local: cl-debian
- $(mkinstalldirs) $(DESTDIR)$(altslocalstatedir) $(DESTDIR)$(altssysconfdir)
- $(INSTALL_DATA) $(srcdir)/README.alternatives $(DESTDIR)$(altssysconfdir)/README
- set -e; for f in $(LSMANL); do ln -sf $(mandir)/man1/dpkg-source.1 $(DESTDIR)$(mandir)/man1/$$f.1; done
- $(mkinstalldirs) $(DESTDIR)$(parsechangelogdir)
- $(INSTALL_PROGRAM) cl-debian $(DESTDIR)$(parsechangelogdir)/debian
-
-uninstall-local:
- $(RM) $(DESTDIR)$(parsechangelogdir)/debian
- -[ -e $(DESTDIR)$(parsechangelogdir) ] && rmdir $(DESTDIR)$(parsechangelogdir)
- set -e; for f in $(LSMANL); do $(RM) $(DESTDIR)$(mandir)/man1/$$f.1; done
- -[ -e $(DESTDIR)$(altssysconfdir) ] && rmdir $(DESTDIR)$(altssysconfdir)
- -[ -e $(DESTDIR)$(altslocalstatedir) ] && rmdir $(DESTDIR)$(altslocalstatedir)
-
-## End of file.
diff --git a/scripts/Makefile.in b/scripts/Makefile.in
new file mode 100644
index 000000000..a9b571a02
--- /dev/null
+++ b/scripts/Makefile.in
@@ -0,0 +1,107 @@
+VPATH = @srcdir@
+srcdir = @srcdir@
+top_srcdir = @top_srcdir@
+
+include ../Makefile.conf
+
+BIN_SCRIPTS = dpkg-name dpkg-source dpkg-genchanges \
+ dpkg-gencontrol dpkg-shlibdeps dpkg-buildpackage \
+ dpkg-parsechangelog dpkg-distaddfile 822-date \
+ dpkg-scanpackages dpkg-scansources dpkg-architecture
+
+SBIN_SCRIPTS = update-rc.d update-alternatives install-info \
+ dpkg-divert cleanup-info
+
+MAN1PAGES = dpkg-name.1 dpkg-source.1 822-date.1 dpkg-architecture.1
+MAN8PAGES = update-rc.d.8 update-alternatives.8 install-info.8 \
+ dpkg-scanpackages.8 dpkg-scansources.8
+
+CHANGELOG_PARSERS = cl-debian
+
+SCRIPTLIBS = controllib.pl
+
+LISPFILES = debian-changelog-mode.el
+
+GEN_MAN8PAGES = dpkg-scansources.8
+
+MAN_SOURCE_ALIASES = dpkg-gencontrol.1 dpkg-genchanges.1 dpkg-buildpackage.1 \
+ dpkg-distaddfile.1 dpkg-parsechangelog.1 dpkg-shlibdeps.1
+
+GENFILES = $(CHANGELOG_PARSERS) $(BIN_SCRIPTS) $(SBIN_SCRIPTS) $(GEN_MAN8PAGES)
+
+.PHONY: all
+all:: $(GENFILES)
+
+.PHONY: install
+install:: all install-program install-doc
+
+.PHONY: clean
+clean::
+ $(RM) $(GENFILES)
+
+.PHONY: cvsclean
+cvslean:: clean
+ $(RM) Makefile
+
+.PHONY: install-program
+install-program:
+ $(mkinstalldirs) $(DESTDIR)/$(bindir)
+ set -e ; for i in $(BIN_SCRIPTS) ; do \
+ if test -f $$i ; then d= ; else d="$(srcdir)/" ; fi ; \
+ $(INSTALL_SCRIPT) $$d$$i $(DESTDIR)/$(bindir) ; \
+ done
+ $(mkinstalldirs) $(DESTDIR)/$(sbindir)
+ set -e ; for i in $(SBIN_SCRIPTS) ; do \
+ if test -f $$i ; then d= ; else d="$(srcdir)/" ; fi ; \
+ $(INSTALL_SCRIPT) $$d$$i $(DESTDIR)/$(sbindir) ; \
+ done
+ $(mkinstalldirs) $(DESTDIR)/$(alternativesdir)
+ $(INSTALL_DATA) $(srcdir)/README.alternatives \
+ $(DESTDIR)/$(alternativesdir)/README
+ $(mkinstalldirs) $(DESTDIR)/$(parsechangelogdir)
+ set -e ; for i in $(CHANGELOG_PARSERS) ; do \
+ if test -f $$i ; then d= ; else d="$(srcdir)/" ; fi ; \
+ rn=`echo $$i | sed -e 's/^cl-//'` ; \
+ $(INSTALL_SCRIPT) $$d$$i $(DESTDIR)/$(parsechangelogdir)/$$rn ; \
+ done
+ $(mkinstalldirs) $(DESTDIR)/$(dpkglibdir)
+ set -e ; for i in $(SCRIPTLIBS) ; do \
+ if test -f $$i ; then d= ; else d="$(srcdir)/" ; fi ; \
+ $(INSTALL_DATA) $$d$$i $(DESTDIR)/$(dpkglibdir) ; \
+ done
+ $(mkinstalldirs) $(DESTDIR)/$(elispdir)
+ set -e ; for i in $(LISPFILES) ; do \
+ if test -f $$i ; then d= ; else d="$(srcdir)/" ; fi ; \
+ $(INSTALL_DATA) $$d$$i $(DESTDIR)/$(elispdir) ; \
+ done
+
+.PHONY: install-doc
+install-doc:
+ $(mkinstalldirs) $(DESTDIR)/$(man1dir)
+ set -e ; for i in $(MAN1PAGES) ; do \
+ if test -f $$i ; then d= ; else d="$(srcdir)/" ; fi ; \
+ $(INSTALL_DATA) $$d$$i $(DESTDIR)/$(man1dir) ; \
+ done
+ set -e ; for i in $(MAN_SOURCE_ALIASES) ; do \
+ echo ".so dpkg-source.1" > $(DESTDIR)$(man1dir)/$$i ; \
+ chmod 644 $(DESTDIR)$(man1dir)/$$i ; \
+ done
+ $(mkinstalldirs) $(DESTDIR)/$(man8dir)
+ set -e ; for i in $(MAN8PAGES) $(GEN_MAN8PAGES) ; do \
+ if test -f $$i ; then d= ; else d="$(srcdir)/" ; fi ; \
+ $(INSTALL_DATA) $$d$$i $(DESTDIR)/$(man8dir) ; \
+ done
+
+
+%.8: %.pl
+ pod2man --section=8 $^ > $@
+
+%: %.pl
+ $(SED) -e "s:^#![:space:]*/usr/bin/perl:#! $(perlpath):; \
+ s:\$$dpkglibdir[[:space:]]*=[[:space:]]*['\"][^'\"]*['\"]:\$$dpkglibdir=\"$(dpkglibdir)\":; \
+ s:\$$version[[:space:]]*=[[:space:]]*['\"][^'\"]*[\"']:\$$version=\"$(VERSION)\":" \
+ < $< > $@
+
+%: %.sh
+ $(SED) -e "s:version=\"[^\"]*\":version=\"$(VERSION)\":" \
+ < $< > $@