1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-22 00:35:15 +00:00

- Convert to USES=kmod

- Add stage support
- Remove some steps from distribution Makefile already done by USES=kmod
- Specify license as 'BSD2CLAUSE' instead of just 'BSD'
- Allow packaging as user
- Simplify inclusions

Approved by:	hrs (maintainer)
This commit is contained in:
Rene Ladan 2014-02-10 23:35:59 +00:00
parent 80bd1cee02
commit fed840f224
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=343713
2 changed files with 32 additions and 29 deletions

View File

@ -3,23 +3,23 @@
PORTNAME= acroreadwrapper
PORTVERSION= 0.0.20130208
CATEGORIES= print kld
CATEGORIES= print
MASTER_SITES= http://people.allbsd.org/~hrs/FreeBSD/
DISTNAME= linux_adobe_kmod-${PORTVERSION:E}
MAINTAINER= hrs@FreeBSD.org
COMMENT= Wrapper for Adobe Reader
LICENSE= BSD
LICENSE= BSD2CLAUSE
USES= kmod uidfix
RUN_DEPENDS= ${LOCALBASE}/lib/linux-libgtkembedmoz/libgtkembedmoz.so:${PORTSDIR}/www/linux-libgtkembedmoz
SSP_UNSAFE= kernel module does not support ssp
ONLY_FOR_ARCHS= amd64 i386
PLIST_FILES= bin/acroread8 bin/acroread9 bin/acroread \
${KMODDIR}/linux_adobe.ko
PLIST_DIRS= ${KMODDIR}
${RELKMODDIR}/linux_adobe.ko
PLIST_DIRS= ${RELKMODDIR}
SUB_FILES= acroread
SUB_LIST= ACROBASE8=${ACROBASE8} \
ACROBASE9=${ACROBASE9} \
@ -28,36 +28,21 @@ SUB_LIST= ACROBASE8=${ACROBASE8} \
LINUXBASE=${LINUXBASE} \
LINUXSH=${LINUXBASE}/bin/sh \
PLUGINDIR=${PLUGINDIR} \
KMODDIR=${KMODDIR}
KMODDIR=${RELKMODDIR}
USE_RC_SUBR= linux_adobe
NO_STAGE= yes
.include <bsd.port.pre.mk>
MAKE_ENV= KMODDIR=${KMODDIR} SYSDIR=${SRC_BASE}/sys DESTDIR=${PREFIX}/
MAKE_ENV= DESTDIR=${PREFIX}/
ADOBEBASE= Adobe
ACROBASE8= ${ADOBEBASE}/Reader8
ACROBASE9= ${ADOBEBASE}/Reader9
PLUGINDIR= lib/npapi/linux-acroread
KMODDIR= libexec/linux_adobe
KERNCONF?= GENERIC
# Use the first component of ${KERNCONF}.
.for K in ${KERNCONF}
_KERNCONF?=$K
.endfor
.if !exists(${SRC_BASE}/sys/${ARCH}/conf/${_KERNCONF})
IGNORE= requires kernel source to be installed
.endif
KMODDIR= ${PREFIX}/libexec/linux_adobe
RELKMODDIR= libexec/linux_adobe
post-install:
${INSTALL_KLD} ${WRKSRC}/linux_adobe.ko \
${PREFIX}/libexec/linux_adobe/linux_adobe.ko
${INSTALL_SCRIPT} ${WRKDIR}/acroread ${PREFIX}/bin/acroread
cd ${PREFIX}/bin && ${LN} -s -f acroread acroread8
cd ${PREFIX}/bin && ${LN} -s -f acroread acroread9
${INSTALL_SCRIPT} ${WRKDIR}/acroread ${STAGEDIR}${PREFIX}/bin/acroread
cd ${STAGEDIR}${PREFIX}/bin && ${LN} -s -f acroread acroread8
cd ${STAGEDIR}${PREFIX}/bin && ${LN} -s -f acroread acroread9
.include <bsd.port.post.mk>
.include <bsd.port.mk>

View File

@ -0,0 +1,18 @@
--- Makefile.orig 2014-02-10 12:12:19.000000000 +0100
+++ Makefile 2014-02-10 12:12:55.000000000 +0100
@@ -2,15 +2,11 @@
KMOD= linux_adobe
SRCS= linux_adobe.c
-NO_XREF= yes
.if ${MACHINE_ARCH} == "amd64"
CFLAGS+=-DCOMPAT_FREEBSD32 -DCOMPAT_LINUX32
.endif
-beforeinstall:
- mkdir -p ${DESTDIR}${KMODDIR}
-
CLEANFILES= linux_adobe_kmod-*.tar.gz
cleandist:
rm -rf linux_adobe_kmod-*