Changeset View
Standalone View
security/softether-devel/Makefile
# $FreeBSD$ | # $FreeBSD$ | ||||
PORTNAME= softether-devel | PORTNAME= softether | ||||
PORTVERSION= 4.21.9613 | PORTVERSION= 4.27.9668 | ||||
PORTREVISION= 2 | |||||
CATEGORIES= security | CATEGORIES= security | ||||
MASTER_SITES= https://www.softether-download.com/files/softether/v4.27-9668-beta-2018.05.29-tree/Source_Code/ | |||||
mat: MASTER_SITES and DISTNAME both have `beta` in them, maybe the version should be:
```… | |||||
PKGNAMESUFFIX= -devel | |||||
DISTNAME= ${PORTNAME}-src-v4.27-9668-beta | |||||
MAINTAINER= hrs@FreeBSD.org | MAINTAINER= hrs@FreeBSD.org | ||||
COMMENT= Cross-platform Multi-protocol VPN Software | COMMENT= Softether VPN solution | ||||
LICENSE= GPLv2 | LICENSE= GPLv2 | ||||
LICENSE_FILE= ${WRKSRC}/LICENSE | LICENSE_FILE= ${WRKSRC}/LICENSE | ||||
ONLY_FOR_ARCHS= amd64 i386 | |||||
Not Done Inline ActionsYou should also set ONLY_FOR_ARCHS_REASON. mat: You should also set `ONLY_FOR_ARCHS_REASON`. | |||||
Not Done Inline ActionsIndeed but I don't know the reason. It is already defined in security/softether. meta: Indeed but I don't know the reason. It is already defined in security/softether. | |||||
CONFLICTS_INSTALL= softether | CONFLICTS_INSTALL= softether | ||||
USES= dos2unix gmake iconv localbase readline ssl | CPPFLAGS+= -I${LOCALBASE}/include | ||||
DOS2UNIX_FILES= src/Mayaqua/Network.c | LDFLAGS+= -L${LOCALBASE}/lib | ||||
USE_GITHUB= yes | |||||
GH_ACCOUNT= SoftEtherVPN | |||||
GH_PROJECT= SoftEtherVPN | |||||
GH_TAGNAME= 1e17c9b | |||||
ALL_TARGET= build | |||||
MAKE_ENV= STAGEDIR=${STAGEDIR} ICONV_LIB=${ICONV_LIB} | |||||
USE_RC_SUBR= vpnserver vpnclient vpnbridge | |||||
PORTDOCS= AUTHORS.TXT BUILD_UNIX.TXT ChangeLog README THIRD_PARTY.TXT \ | |||||
WARNING.TXT | |||||
PORTDOCS= AUTHORS.TXT ChangeLog LICENSE README THIRD_PARTY.TXT WARNING.TXT | |||||
Not Done Inline ActionsWrong place in the Makefile. See Chapter 15. Order of Variables in Port Makefiles. mat: Wrong place in the Makefile. See [[ https://www.freebsd.org/doc/en/books/porters… | |||||
OPTIONS_DEFINE= DOCS UNLOCK | OPTIONS_DEFINE= DOCS UNLOCK | ||||
# Use of some functions in Japan and China is restricted. | # Use of some functions in Japan and China is restricted. | ||||
# This option Unlocks regional lockout following functions: | # This option Unlocks regional lockout following functions: | ||||
# - RADIUS / NT Domain user authentication function | # - RADIUS / NT Domain user authentication function | ||||
# - RSA certificate user authentication function | # - RSA certificate user authentication function | ||||
# - Deep-inspect packet logging function | # - Deep-inspect packet logging function | ||||
# - Source IP address control list function | # - Source IP address control list function | ||||
# - syslog transfer function | # - syslog transfer function | ||||
UNLOCK_DESC= Unlock regional lockout (JP and CN) | UNLOCK_DESC= Unlock regional lockout (JP and CN) | ||||
UNLOCK_EXTRA_PATCHES= ${FILESDIR}/extra-patch-unrestrict-enterprise-functions | UNLOCK_EXTRA_PATCHES= ${FILESDIR}/extra-patch-unrestrict-enterprise-functions | ||||
USES= dos2unix gmake iconv:wchar_t localbase:ldflags ncurses \ | |||||
readline ssl | |||||
matUnsubmitted Not Done Inline ActionsWrong place in the Makefile. See Chapter 15. Order of Variables in Port Makefiles. mat: Wrong place in the Makefile. See [[ https://www.freebsd.org/doc/en/books/porters… | |||||
DOS2UNIX_FILES= AUTHORS.TXT ChangeLog LICENSE README THIRD_PARTY.TXT \ | |||||
WARNING.TXT src/Cedar/*.* src/Mayaqua/*.* | |||||
Not Done Inline ActionsThis could be simplified as: src/Cedar/* \ src/Mayaqua/* mat: This could be simplified as:
```
src/Cedar/* \
src/Mayaqua/*
``` | |||||
Not Done Inline ActionsIt fails to patch. This works: src/Cedar/*.* src/Mayaqua/*.* meta: It fails to patch. This works:
```
src/Cedar/*.* src/Mayaqua/*.*
``` | |||||
USE_RC_SUBR= softether_bridge softether_client softether_server | |||||
Not Done Inline ActionsIf you set this, you must say why it is unsafe in either the variable, or a comment. mat: If you set this, you must say why it is unsafe in either the variable, or a comment. | |||||
Not Done Inline ActionsMay be it can be removed. Confirmed it builds. meta: May be it can be removed. Confirmed it builds. | |||||
SUB_FILES= vpncmd | |||||
LOGDIR?= /var/log/softether | |||||
PLIST_SUB+= LOGDIR="${LOGDIR}" | |||||
matUnsubmitted Not Done Inline ActionsWhy +=? mat: Why `+=`? | |||||
metaAuthorUnsubmitted Not Done Inline ActionsPlease remember, I'm trying to keep -devel port newer than basic port. First of all, copy softether to softether-devel and then I did update. Can you focus on diff between softether and softether-devel port? Not on the previous revision of softether-devel. This port is based on security/softether, let's fix it first, and I'll copy it to softether-devel and update. meta: Please remember, I'm trying to keep -devel port newer than basic port. First of all, copy… | |||||
SUB_LIST= LOGDIR="${LOGDIR}" | |||||
# a pity the source directory has such a naming scheme, but well | |||||
WRKSRC= ${WRKDIR}/v4.27-9668 | |||||
ALL_TARGET= build | |||||
.include <bsd.port.options.mk> | |||||
post-patch: | post-patch: | ||||
${INSTALL_DATA} ${WRKSRC}/src/makefiles/freebsd_32bit.mak \ | # skip configure at all and copy the corresponding Makefile in place | ||||
${WRKSRC}/Makefile | .if ${ARCH} != "amd64" | ||||
@${CP} ${WRKSRC}/src/makefiles/freebsd_32bit.mak ${WRKSRC}/Makefile | |||||
.else | |||||
@${CP} ${WRKSRC}/src/makefiles/freebsd_64bit.mak ${WRKSRC}/Makefile | |||||
.endif | |||||
Not Done Inline ActionsPatching should happen in a post-patch target. mat: Patching should happen in a post-patch target. | |||||
Not Done Inline ActionsIndeed, thanks. meta: Indeed, thanks. | |||||
# pull in user specific CFLAGS and LDFLAGS | |||||
@${REINPLACE_CMD} -e "s|OPTIONS_COMPILE_RELEASE=|OPTIONS_COMPILE_RELEASE=${CFLAGS} |g" ${WRKSRC}/Makefile | |||||
@${REINPLACE_CMD} -e "s|OPTIONS_LINK_RELEASE=|OPTIONS_LINK_RELEASE=${LDFLAGS} |g" ${WRKSRC}/Makefile | |||||
post-install-DOCS-on: | # manually install to ${PREFIX}/libexec/softether, then the final install will copy scripts | ||||
# into ${PREFIX}/sbin | |||||
do-install: | |||||
${MKDIR} ${STAGEDIR}/${PREFIX}/libexec/softether | |||||
${INSTALL_SCRIPT} ${WRKSRC}/bin/vpnbridge/vpnbridge ${STAGEDIR}/${PREFIX}/libexec/${PORTNAME}/vpnbridge | |||||
${INSTALL_SCRIPT} ${WRKSRC}/bin/vpnclient/vpnclient ${STAGEDIR}/${PREFIX}/libexec/${PORTNAME}/vpnclient | |||||
${INSTALL_SCRIPT} ${WRKSRC}/bin/vpncmd/vpncmd ${STAGEDIR}/${PREFIX}/libexec/${PORTNAME}/vpncmd | |||||
${INSTALL_SCRIPT} ${WRKSRC}/bin/vpnserver/vpnserver ${STAGEDIR}/${PREFIX}/libexec/${PORTNAME}/vpnserver | |||||
${INSTALL_DATA} ${WRKSRC}/bin/vpnserver/hamcore.se2 ${STAGEDIR}/${PREFIX}/libexec/${PORTNAME}/hamcore.se2 | |||||
Not Done Inline ActionsYou already have do-install, no need to add a post-install, put everything in do-install. mat: You already have do-install, no need to add a post-install, put everything in do-install. | |||||
${INSTALL_SCRIPT} ${WRKDIR}/vpncmd ${STAGEDIR}/${PREFIX}/sbin/vpncmd | |||||
.for i in vpnbridge vpnclient vpncmd vpnserver | |||||
@${STRIP_CMD} ${STAGEDIR}${PREFIX}/libexec/${PORTNAME}/${i} | |||||
.endfor | |||||
@${MKDIR} ${STAGEDIR}${DOCSDIR} | @${MKDIR} ${STAGEDIR}${DOCSDIR} | ||||
cd ${WRKSRC} && \ | @${MKDIR} ${STAGEDIR}${LOGDIR} | ||||
${INSTALL_DATA} ${PORTDOCS} ${STAGEDIR}${DOCSDIR} | .for doc in ${PORTDOCS} | ||||
${INSTALL_DATA} ${WRKSRC}/${doc} ${STAGEDIR}${DOCSDIR} | |||||
.endfor | |||||
Not Done Inline ActionsAny reason to have removed the post-install-DOCS-on target? mat: Any reason to have removed the post-install-DOCS-on target? | |||||
Not Done Inline ActionsNo special reasons. First of all I syced softether-devel with softether. meta: No special reasons. First of all I syced softether-devel with softether.
And the updated… | |||||
.include <bsd.port.mk> | .include <bsd.port.mk> |
MASTER_SITES and DISTNAME both have beta in them, maybe the version should be:
or something, to respect the fact that it is beta.