pkgsrc-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
DESTDIR support for www/apache22
Please review following patch to add DESTDIR support to www/apache22.
Index: Makefile
===================================================================
RCS file: /cvsroot/pkgsrc/www/apache22/Makefile,v
retrieving revision 1.26
diff -u -r1.26 Makefile
--- Makefile 12 Jun 2008 14:12:19 -0000 1.26
+++ Makefile 15 Jun 2008 02:55:49 -0000
@@ -9,6 +9,8 @@
HOMEPAGE= http://httpd.apache.org/
COMMENT= Apache HTTP (Web) server, version 2
+PKG_DESTDIR_SUPPORT= user-destdir
+
CONFLICTS= apache-{,*ssl}-[0-9]* apache6-[0-9]*
BUILD_DEFS+= IPV6_READY
@@ -222,11 +224,11 @@
pre-install:
cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} \
- ${MAKE_PROGRAM} install-conf sysconfdir="${EGDIR}"
+ ${MAKE_PROGRAM} install-conf sysconfdir="${EGDIR}"
${INSTALL_MAKE_FLAGS}
post-install:
- ${LN} -sf ${LOCALBASE}/libexec/apr/libtool ${PREFIX}/share/httpd/build
- cd ${EGDIR} && \
+ ${LN} -sf ${LOCALBASE}/libexec/apr/libtool
${DESTDIR}${PREFIX}/share/httpd/build
+ cd ${DESTDIR}${EGDIR} && \
for file in \
httpd.conf \
extra/httpd-ssl.conf; \
@@ -245,25 +247,25 @@
${MV} -f $${file}.new $${file}; \
done
- ${LN} -sf ${SBINDIR}/envvars-std ${SBINDIR}/envvars
+ ${LN} -sf ${SBINDIR}/envvars-std ${DESTDIR}${SBINDIR}/envvars
- ${INSTALL_SCRIPT} ${WRKDIR}/mkcert ${PREFIX}/sbin
+ ${INSTALL_SCRIPT} ${WRKDIR}/mkcert ${DESTDIR}${PREFIX}/sbin
for file in ${FIX_PERMS}; do \
- ${CHOWN} ${BINOWN}:${BINGRP} ${PREFIX}/sbin/$$file && \
- ${CHMOD} ${BINMODE} ${PREFIX}/sbin/$$file; \
+ ${CHOWN} ${BINOWN}:${BINGRP} ${DESTDIR}${PREFIX}/sbin/$$file &&
\
+ ${CHMOD} ${BINMODE} ${DESTDIR}${PREFIX}/sbin/$$file; \
done
- ${CHOWN} -R ${BINOWN}:${BINGRP} ${PREFIX}/share/httpd
- ${CHOWN} -R ${BINOWN}:${BINGRP} ${PREFIX}/include/httpd
- ${CHOWN} -R ${BINOWN}:${BINGRP} ${PREFIX}/lib/httpd
- ${CHOWN} ${BINOWN}:${BINGRP} ${PREFIX}/libexec/cgi-bin/test-cgi
- ${CHOWN} ${BINOWN}:${BINGRP} ${PREFIX}/libexec/cgi-bin/printenv
+ ${CHOWN} -R ${BINOWN}:${BINGRP} ${DESTDIR}${PREFIX}/share/httpd
+ ${CHOWN} -R ${BINOWN}:${BINGRP} ${DESTDIR}${PREFIX}/include/httpd
+ ${CHOWN} -R ${BINOWN}:${BINGRP} ${DESTDIR}${PREFIX}/lib/httpd
+ ${CHOWN} ${BINOWN}:${BINGRP}
${DESTDIR}${PREFIX}/libexec/cgi-bin/test-cgi
+ ${CHOWN} ${BINOWN}:${BINGRP}
${DESTDIR}${PREFIX}/libexec/cgi-bin/printenv
for file in ${FIX_MAN_PERMS}; do \
- ${CHOWN} ${MANOWN}:${MANGRP} ${PREFIX}/${PKGMANDIR}/$$file; \
+ ${CHOWN} ${MANOWN}:${MANGRP}
${DESTDIR}${PREFIX}/${PKGMANDIR}/$$file; \
done
- [ ! -f ${PREFIX}/sbin/suexec ] || ${CHMOD} -w ${PREFIX}/sbin/suexec
+ [ ! -f ${PREFIX}/sbin/suexec ] || ${CHMOD} -w
${DESTDIR}${PREFIX}/sbin/suexec
.include "../../mk/bsd.pkg.mk"
Index: options.mk
===================================================================
RCS file: /cvsroot/pkgsrc/www/apache22/options.mk,v
retrieving revision 1.3
diff -u -r1.3 options.mk
--- options.mk 12 Apr 2008 22:43:13 -0000 1.3
+++ options.mk 15 Jun 2008 02:55:49 -0000
@@ -8,6 +8,7 @@
PLIST_VARS+= suexec
.if !empty(PKG_OPTIONS:Msuexec)
PKG_USERS_VARS+= APACHE_USER
+PKG_GROUPS_VARS+= APACHE_GROUP
BUILD_DEFS+= VARBASE APACHE_SUEXEC_PATH
BUILD_DEFS+= APACHE_SUEXEC_DOCROOT APACHE_SUEXEC_LOGFILE
@@ -25,4 +26,5 @@
CONFIGURE_ARGS+= ${APACHE_SUEXEC_CONFIGURE_ARGS:M--with-suexec-*}
BUILD_DEFS+= APACHE_SUEXEC_CONFIGURE_ARGS
PLIST.suexec= yes
+SPECIAL_PERMS+= sbin/suexec ${ROOT_USER} ${APACHE_GROUP} 4510
.endif
--
"Of course I love NetBSD":-)
OBATA Akio / obache%NetBSD.org@localhost
Home |
Main Index |
Thread Index |
Old Index