diff options
author | rillig <rillig@pkgsrc.org> | 2006-02-17 23:52:18 +0000 |
---|---|---|
committer | rillig <rillig@pkgsrc.org> | 2006-02-17 23:52:18 +0000 |
commit | 5f107757b321f2f7ef5efffd19486c4a6c5d16f2 (patch) | |
tree | 78a98b12b835bd78ef58601a1edb8534c73618ef /archivers/rar | |
parent | 60d1ee3fbc070ae193aa6e74d393b716fd0e4add (diff) | |
download | pkgsrc-5f107757b321f2f7ef5efffd19486c4a6c5d16f2.tar.gz |
Fixed pkglint warnings. If no kernel image can be found, try to build the
package without.
Diffstat (limited to 'archivers/rar')
-rw-r--r-- | archivers/rar/Makefile | 57 |
1 files changed, 30 insertions, 27 deletions
diff --git a/archivers/rar/Makefile b/archivers/rar/Makefile index 7635f561925..cb2ee1279d5 100644 --- a/archivers/rar/Makefile +++ b/archivers/rar/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.40 2005/04/11 21:44:50 tv Exp $ +# $NetBSD: Makefile,v 1.41 2006/02/17 23:52:18 rillig Exp $ DISTNAME= rarbsd PKGNAME= rar-2.02 @@ -20,40 +20,43 @@ WRKSRC= ${WRKDIR} EXTRACT_CMD= ${DOWNLOADED_DISTFILE} >/dev/null pre-extract: - @if [ -z "$$KERNEL" ]; then \ - KERNEL=`env "PATH=${PATH}:/sbin:/usr/sbin" sysctl -n machdep.booted_kernel` ;\ - fi ;\ - if (${NM} /$$KERNEL | ${GREP} -q compat_12 && \ - ${NM} /$$KERNEL | ${GREP} -q exec_nomid && \ - ${NM} /$$KERNEL | ${GREP} -q exec_aout); then ${TRUE}; \ - else \ - ${ECHO} "****************************************************************";\ - ${ECHO} Make can not proceed! In order to extract \(and run\); \ - ${ECHO} this package, you must have have booted from a kernel; \ - ${ECHO} with options COMPAT_NOMID and COMPAT_12 \(and EXEC_AOUT, if ELF\).; \ - ${ECHO} "****************************************************************";\ - ${FALSE}; \ + ${_PKG_SILENT}${_PKG_DEBUG} set -e; set -u; \ + if [ -z "$${KERNEL-}" ]; then \ + KERNEL=/`env PATH="$${PATH}:/sbin:/usr/sbin" sysctl -n machdep.booted_kernel`; \ + fi; \ + if [ ! -f "$$KERNEL" ]; then \ + ${ECHO} "No kernel image found. Let's try without."; \ + elif (${NM} "$$KERNEL" | ${GREP} -q compat_12 && \ + ${NM} "$$KERNEL" | ${GREP} -q exec_nomid && \ + ${NM} "$$KERNEL" | ${GREP} -q exec_aout); then \ + ${TRUE}; \ + else \ + ${ECHO} "Make can not proceed! In order to extract (and run)"; \ + ${ECHO} "this package, you must have have booted from a kernel"; \ + ${ECHO} "with options COMPAT_NOMID and COMPAT_12 (and EXEC_AOUT, if ELF)."; \ + ${FALSE}; \ fi - @${CHMOD} a+x ${DISTDIR}/${DISTFILES} + @${CHMOD} a+x ${DISTDIR:Q}/${DISTFILES:Q} do-build: - cd ${WRKSRC} && \ - for i in *.Txt *.Lst; do \ - ${TR} -d '\015' < $$i > $$i.tmp; \ - ${MV} $$i.tmp $$i; \ - done + ${_PKG_SILENT}${_PKG_DEBUG} set -e; set -u; \ + cd ${WRKSRC:Q}; \ + for i in *.Txt *.Lst; do \ + ${TR} -d '\015' < "$$i" > "$$i".tmp; \ + ${MV} "$$i".tmp "$$i"; \ + done do-install: - ${INSTALL_DATA_DIR} ${PREFIX}/share/doc/rar ${PREFIX}/share/rar - cd ${WRKSRC} && \ - ${INSTALL_SCRIPT} rar ${PREFIX}/bin/rar && \ + ${INSTALL_DATA_DIR} ${PREFIX:Q}/share/doc/rar ${PREFIX:Q}/share/rar + cd ${WRKSRC:Q} && \ + ${INSTALL_SCRIPT} rar ${PREFIX:Q}/bin/rar && \ ${INSTALL_MAN} Rar.Txt Rar_FAQ.txt TechNote.Txt \ - License.Txt Internet.Txt ${PREFIX}/share/doc/rar && \ + License.Txt Internet.Txt ${PREFIX:Q}/share/doc/rar && \ ${INSTALL_DATA} RarFiles.Lst \ - ${PREFIX}/share/rar/rarfiles.lst && \ + ${PREFIX:Q}/share/rar/rarfiles.lst && \ ${INSTALL_DATA} default.sfx \ - ${PREFIX}/share/rar/default.sfx && \ + ${PREFIX:Q}/share/rar/default.sfx && \ ${INSTALL_DATA} Dos.SFX \ - ${PREFIX}/share/rar/dos.sfx + ${PREFIX:Q}/share/rar/dos.sfx .include "../../mk/bsd.pkg.mk" |