diff options
author | Munechika SUMIKAWA <sumikawa@FreeBSD.org> | 2009-04-22 06:01:39 +0000 |
---|---|---|
committer | Munechika SUMIKAWA <sumikawa@FreeBSD.org> | 2009-04-22 06:01:39 +0000 |
commit | ecec028843255b51ba9bb2026f9f7a48a4baa518 (patch) | |
tree | f03116ae94d0cc7499e0489c0c41e6b25035a60f /security/openssh-portable | |
parent | 01824de4de41740a6612614139d5eba7f8901dc8 (diff) | |
download | ports-ecec028843255b51ba9bb2026f9f7a48a4baa518.tar.gz ports-ecec028843255b51ba9bb2026f9f7a48a4baa518.zip |
Notes
Diffstat (limited to 'security/openssh-portable')
-rw-r--r-- | security/openssh-portable/Makefile | 13 | ||||
-rw-r--r-- | security/openssh-portable/pkg-plist | 5 |
2 files changed, 6 insertions, 12 deletions
diff --git a/security/openssh-portable/Makefile b/security/openssh-portable/Makefile index 9bba74cd98fa..07ca4fd37ab6 100644 --- a/security/openssh-portable/Makefile +++ b/security/openssh-portable/Makefile @@ -177,11 +177,14 @@ SUB_FILES+= openssh PLIST_SUB+= NOTBASE="@comment " PLIST_SUB+= BASE="" PLIST_SUB+= BASEPREFIX="${PREFIX}" +PLIST_SUB+= ERASEEMPTY="@comment " .else .if exists(/var/empty) EMPTYDIR= /var/empty +PLIST_SUB+= ERASEEMPTY="@comment " .else EMPTYDIR= ${PREFIX}/empty +PLIST_SUB+= ERASEEMPTY="" .endif ETCSSH= ${PREFIX}/etc/ssh USE_RC_SUBR= openssh @@ -204,13 +207,8 @@ post-extract: post-patch: @${REINPLACE_CMD} -e 's|-ldes|-lcrypto|g' ${WRKSRC}/configure -.if defined(WITH_OVERWRITE_BASE) @${REINPLACE_CMD} -e 's|%%PREFIX%%|${LOCALBASE}|' \ -e 's|%%RC_SCRIPT_NAME%%|${RC_SCRIPT_NAME}|' ${WRKSRC}/sshd.8 -.else - @${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|' \ - -e 's|%%RC_SCRIPT_NAME%%|${RC_SCRIPT_NAME}|' ${WRKSRC}/sshd.8 -.endif @${REINPLACE_CMD} -E -e 's|SSH_VERSION|TMP_SSH_VERSION|' \ -e 's|.*SSH_RELEASE.*||' ${WRKSRC}/version.h @${ECHO_CMD} '#define FREEBSD_PORT_VERSION " FreeBSD-${PKGNAME}"' >> \ @@ -225,11 +223,7 @@ post-patch: .endif pre-su-install: -.if defined(WITH_OVERWRITE_BASE) @${MKDIR} ${EMPTYDIR} -.else - @${MKDIR} ${PREFIX}/empty -.endif if ! pw groupshow sshd; then pw groupadd sshd -g 22; fi if ! pw usershow sshd; then pw useradd sshd -g sshd -u 22 \ -h - -d ${EMPTYDIR} -s /nonexistent -c "sshd privilege separation"; fi @@ -249,6 +243,7 @@ post-install: .if defined(WITH_OVERWRITE_BASE) @${ECHO_CMD} "===> Installing rc.d startup script(s)" @${ECHO_CMD} "@cwd ${LOCALBASE}" >> ${TMPPLIST} + @${MKDIR} ${LOCALBASE}/etc/rc.d @${INSTALL_SCRIPT} ${WRKDIR}/openssh ${LOCALBASE}/etc/rc.d/${RC_SCRIPT_NAME} @${ECHO_CMD} "etc/rc.d/${RC_SCRIPT_NAME}" >> ${TMPPLIST} @${ECHO_CMD} "@cwd ${PREFIX}" >> ${TMPPLIST} diff --git a/security/openssh-portable/pkg-plist b/security/openssh-portable/pkg-plist index 0a523674b9e3..75f2e7046725 100644 --- a/security/openssh-portable/pkg-plist +++ b/security/openssh-portable/pkg-plist @@ -23,8 +23,7 @@ sbin/sshd share/Ssh.bin libexec/sftp-server libexec/ssh-keysign -%%NOTBASE%%@exec mkdir -p %D/empty -%%NOTBASE%%@dirrm empty -%%BASE%%@exec if [ ! -d %%EMPTYDIR%% ]; then mkdir -p %%EMPTYDIR%% ; fi +@exec if [ ! -d %%EMPTYDIR%% ]; then mkdir -p %%EMPTYDIR%% ; fi +%%ERASEEMPTY%%@dirrm empty @exec if ! pw groupshow sshd 2>/dev/null; then pw groupadd sshd -g 22; fi @exec if ! pw usershow sshd 2>/dev/null; then pw useradd sshd -g sshd -u 22 -h - -d %%EMPTYDIR%% -s /nonexistent -c "sshd privilege separation"; fi |