mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-04-16 19:16:42 +02:00
144 lines
5.8 KiB
Diff
144 lines
5.8 KiB
Diff
--- a/Makefile
|
|
+++ b/Makefile
|
|
@@ -1,3 +1,4 @@
|
|
+PREFIX=/usr
|
|
MUNGE=xargs perl -i.bak -ne ' \
|
|
print $$_."\# This file was preprocessed, do not edit!\n" \
|
|
if m:^\#!/usr/bin/perl:; \
|
|
@@ -24,60 +25,64 @@
|
|
|
|
# Anything that goes in the debconf-utils package.
|
|
install-utils:
|
|
- install -d $(prefix)/usr/bin
|
|
+ install -d $(DESTDIR)$(PREFIX)/bin
|
|
find . -maxdepth 1 -perm /100 -type f -name 'debconf-*' | grep -v debconf-set-selections | grep -v debconf-show | grep -v debconf-copydb | grep -v debconf-communicate | grep -v debconf-apt-progress | grep -v debconf-escape | \
|
|
- xargs -i install {} $(prefix)/usr/bin
|
|
+ xargs -i install {} $(DESTDIR)$(PREFIX)/bin
|
|
+
|
|
+# Installs only english man pages
|
|
+install-doc:
|
|
+ $(MAKE) -C doc PREFIX=$(PREFIX) DESTDIR=$(DESTDIR) install
|
|
|
|
# Anything that goes in the debconf-i18n package.
|
|
install-i18n:
|
|
- $(MAKE) -C po install
|
|
+ $(MAKE) -C po PREFIX=$(PREFIX) DESTDIR=$(DESTDIR) install
|
|
|
|
PERL := perl
|
|
PERL_VENDORLIB := $(shell $(PERL) -MConfig -e 'print $$Config{vendorlib}')
|
|
|
|
# The Python 3 package.
|
|
install-python3:
|
|
- install -d $(prefix)/usr/lib/python3/dist-packages
|
|
- install -m 0644 debconf.py $(prefix)/usr/lib/python3/dist-packages/
|
|
+ install -d $(DESTDIR)$(PREFIX)/lib/python3/dist-packages
|
|
+ install -m 0644 debconf.py $(DESTDIR)$(PREFIX)/lib/python3/dist-packages/
|
|
|
|
# Install all else.
|
|
install-rest:
|
|
- install -d $(prefix)/etc \
|
|
- $(prefix)/var/cache/debconf \
|
|
- $(prefix)/usr/share/debconf \
|
|
- $(prefix)/usr/share/pixmaps
|
|
- install -m 0644 debconf.conf $(prefix)/etc/
|
|
- install -m 0644 debian-logo.png $(prefix)/usr/share/pixmaps/
|
|
+ install -d $(DESTDIR)/etc \
|
|
+ $(DESTDIR)/var/cache/debconf \
|
|
+ $(DESTDIR)$(PREFIX)/share/debconf \
|
|
+ $(DESTDIR)$(PREFIX)/share/pixmaps
|
|
+ install -m 0644 debconf.conf $(DESTDIR)/etc/
|
|
+ install -m 0644 debian-logo.png $(DESTDIR)$(PREFIX)/share/pixmaps/
|
|
# This one is the ultimate backup copy.
|
|
- grep -v '^#' debconf.conf > $(prefix)/usr/share/debconf/debconf.conf
|
|
+ grep -v '^#' debconf.conf > $(DESTDIR)$(PREFIX)/share/debconf/debconf.conf
|
|
# Make module directories.
|
|
find Debconf -type d |grep -v CVS | \
|
|
- xargs -i install -d $(prefix)/$(PERL_VENDORLIB)/{}
|
|
+ xargs -i install -d $(DESTDIR)/$(PERL_VENDORLIB)/{}
|
|
# Install modules.
|
|
find Debconf -type f -name '*.pm' |grep -v CVS | \
|
|
- xargs -i install -m 0644 {} $(prefix)/$(PERL_VENDORLIB)/{}
|
|
+ xargs -i install -m 0644 {} $(DESTDIR)/$(PERL_VENDORLIB)/{}
|
|
# Special case for back-compatability.
|
|
- install -d $(prefix)/$(PERL_VENDORLIB)/Debian/DebConf/Client
|
|
+ install -d $(DESTDIR)/$(PERL_VENDORLIB)/Debian/DebConf/Client
|
|
cp Debconf/Client/ConfModule.stub \
|
|
- $(prefix)/$(PERL_VENDORLIB)/Debian/DebConf/Client/ConfModule.pm
|
|
+ $(DESTDIR)/$(PERL_VENDORLIB)/Debian/DebConf/Client/ConfModule.pm
|
|
# Other libs and helper stuff.
|
|
- install -m 0644 confmodule.sh confmodule $(prefix)/usr/share/debconf/
|
|
- install frontend $(prefix)/usr/share/debconf/
|
|
- install -m 0755 fix_db.pl $(prefix)/usr/share/debconf/
|
|
+ install -m 0644 confmodule.sh confmodule $(DESTDIR)$(PREFIX)/share/debconf/
|
|
+ install frontend $(DESTDIR)$(PREFIX)/share/debconf/
|
|
+ install -m 0755 fix_db.pl $(DESTDIR)$(PREFIX)/share/debconf/
|
|
# Install essential programs.
|
|
- install -d $(prefix)/usr/sbin $(prefix)/usr/bin
|
|
+ install -d $(DESTDIR)$(PREFIX)/sbin $(DESTDIR)$(PREFIX)/bin
|
|
find . -maxdepth 1 -perm /100 -type f -name 'dpkg-*' | \
|
|
- xargs -i install {} $(prefix)/usr/sbin
|
|
+ xargs -i install {} $(DESTDIR)$(PREFIX)/sbin
|
|
find . -maxdepth 1 -perm /100 -type f -name debconf -or -name debconf-show -or -name debconf-copydb -or -name debconf-communicate -or -name debconf-set-selections -or -name debconf-apt-progress -or -name debconf-escape | \
|
|
- xargs -i install {} $(prefix)/usr/bin
|
|
+ xargs -i install {} $(DESTDIR)$(PREFIX)/bin
|
|
# Now strip all pod documentation from all .pm files and scripts.
|
|
- find $(prefix)/$(PERL_VENDORLIB)/ $(prefix)/usr/sbin \
|
|
- $(prefix)/usr/share/debconf/frontend \
|
|
- $(prefix)/usr/share/debconf/*.pl $(prefix)/usr/bin \
|
|
+ find $(DESTDIR)/$(PERL_VENDORLIB)/ $(DESTDIR)$(PREFIX)/sbin \
|
|
+ $(DESTDIR)$(PREFIX)/share/debconf/frontend \
|
|
+ $(DESTDIR)$(PREFIX)/share/debconf/*.pl $(DESTDIR)$(PREFIX)/bin \
|
|
-name '*.pl' -or -name '*.pm' -or -name 'dpkg-*' -or \
|
|
-name 'debconf-*' -or -name 'frontend' | \
|
|
grep -v Client/ConfModule | $(MUNGE)
|
|
- find $(prefix) -name '*.bak' | xargs rm -f
|
|
+ find $(DESTDIR) -name '*.bak' | xargs rm -f
|
|
|
|
demo:
|
|
PERL5LIB=. ./frontend samples/demo
|
|
|
|
--- a/po/Makefile
|
|
+++ b/po/Makefile
|
|
@@ -4,14 +4,15 @@
|
|
|
|
POFILES=$(wildcard *.po)
|
|
MOFILES=$(POFILES:.po=.mo)
|
|
+PREFIX=/usr
|
|
|
|
all: debconf.pot $(MOFILES)
|
|
|
|
install: all
|
|
for file in $(MOFILES); do \
|
|
lang=`echo $$file | sed 's/\.mo//'`; \
|
|
- install -d $(prefix)/usr/share/locale/$$lang/LC_MESSAGES/; \
|
|
- install -m 0644 $$file $(prefix)/usr/share/locale/$$lang/LC_MESSAGES/debconf.mo; \
|
|
+ install -d $(DESTDIR)$(PREFIX)/share/locale/$$lang/LC_MESSAGES/; \
|
|
+ install -m 0644 $$file $(DESTDIR)$(PREFIX)/share/locale/$$lang/LC_MESSAGES/debconf.mo; \
|
|
done
|
|
|
|
debconf.pot: $(POTFILES)
|
|
|
|
--- a/doc/Makefile
|
|
+++ b/doc/Makefile
|
|
@@ -1,6 +1,7 @@
|
|
all: manpages
|
|
./graph.pl `find .. -name \*.pm` > hierarchy.txt
|
|
|
|
+PREFIX=/usr
|
|
pod2man=pod2man -c Debconf -r '' --utf8
|
|
manpages:
|
|
cd man && po4a po4a/po4a.cfg
|
|
@@ -18,6 +19,13 @@
|
|
xargs -i sh -c "cd .. ; $(pod2man) --section=1 {} > doc/man/gen/{}.1"
|
|
find .. -maxdepth 1 -perm /100 -type f -name 'dpkg-*' -printf '%P\n' | \
|
|
xargs -i sh -c "cd .. ; $(pod2man) --section=8 {} > doc/man/gen/{}.8"
|
|
+
|
|
+install:
|
|
+ install -d $(DESTDIR)$(PREFIX)/share/man/man1 $(DESTDIR)$(PREFIX)/share/man/man3 $(DESTDIR)$(PREFIX)/share/man/man8
|
|
+
|
|
+ for num in 1 3 8; do \
|
|
+ find man/gen/ -type f ! -name "*.*.*" -name "*.$$num" -exec cp --target-directory=$(DESTDIR)$(PREFIX)/share/man/man$$num/ {} +; \
|
|
+ done
|
|
|
|
clean:
|
|
cd man && po4a --rm-translations po4a/po4a.cfg
|