Fri Oct 25 00:41:37 2019 UTC ()
net/unif: Add comment about why update to 5.11.50 is on hold


(gdt)
diff -r1.12 -r1.13 pkgsrc/net/unifi/Makefile

cvs diff -r1.12 -r1.13 pkgsrc/net/unifi/Makefile (switch to unified diff)

--- pkgsrc/net/unifi/Makefile 2019/08/08 16:47:26 1.12
+++ pkgsrc/net/unifi/Makefile 2019/10/25 00:41:37 1.13
@@ -1,89 +1,92 @@ @@ -1,89 +1,92 @@
1# $NetBSD: Makefile,v 1.12 2019/08/08 16:47:26 gdt Exp $ 1# $NetBSD: Makefile,v 1.13 2019/10/25 00:41:37 gdt Exp $
2 2
 3# Update to 5.11.50 is on old because of crashing.
3DISTNAME= unifi-5.10.26 4DISTNAME= unifi-5.10.26
4CATEGORIES= net 5CATEGORIES= net
5MASTER_SITES= -http://dl.ubnt.com/unifi/${PKGVERSION_NOREV}/UniFi.unix.zip 6MASTER_SITES= -http://dl.ubnt.com/unifi/${PKGVERSION_NOREV}/UniFi.unix.zip
6EXTRACT_SUFX= .zip 7EXTRACT_SUFX= .zip
7 8
 9# Updates must be tested to not only build but actually function under
 10# at least NetBSD 8/amd64 with actual UBNT hardware.
8MAINTAINER= gdt@NetBSD.org 11MAINTAINER= gdt@NetBSD.org
9HOMEPAGE= https://www.ubnt.com/download/unifi/ 12HOMEPAGE= https://www.ubnt.com/download/unifi/
10# The content that belongs in NEWS are often in a blog. 13# The content that belongs in NEWS are often in a blog.
11#BLOGPAGE= https://community.ui.com/releases 14#BLOGPAGE= https://community.ui.com/releases
12COMMENT= Provisioning software for network products made by Ubiquiti 15COMMENT= Provisioning software for network products made by Ubiquiti
13LICENSE= ubiquiti-license 16LICENSE= ubiquiti-license
14 17
15# Bundled firmware images cannot be redistributed 18# Bundled firmware images cannot be redistributed
16RESTRICTED= No permission to redistribute 19RESTRICTED= No permission to redistribute
17NO_BIN_ON_CDROM= ${RESTRICTED} 20NO_BIN_ON_CDROM= ${RESTRICTED}
18NO_BIN_ON_FTP= ${RESTRICTED} 21NO_BIN_ON_FTP= ${RESTRICTED}
19NO_SRC_ON_CDROM= ${RESTRICTED} 22NO_SRC_ON_CDROM= ${RESTRICTED}
20NO_SRC_ON_FTP= ${RESTRICTED} 23NO_SRC_ON_FTP= ${RESTRICTED}
21 24
22DISTFILES= ${DEFAULT_DISTFILES} 25DISTFILES= ${DEFAULT_DISTFILES}
23EXTRACT_ONLY= ${DEFAULT_DISTFILES} 26EXTRACT_ONLY= ${DEFAULT_DISTFILES}
24 27
25# Unifi bundles snappy-java-1.0.5.jar, which contains native code. 28# Unifi bundles snappy-java-1.0.5.jar, which contains native code.
26# We can use the bundled snappy-java but we must recompile the native portion 29# We can use the bundled snappy-java but we must recompile the native portion
27# because it only ship linux binaries. The rcd script takes care of loading the 30# because it only ship linux binaries. The rcd script takes care of loading the
28# correct library. 31# correct library.
29SNAPPY_JAVA= snappy-java-1.0.5.4 32SNAPPY_JAVA= snappy-java-1.0.5.4
30SITES.${SNAPPY_JAVA}.tar.gz= -https://github.com/xerial/snappy-java/archive/${SNAPPY_JAVA:S/snappy-java-//}.tar.gz 33SITES.${SNAPPY_JAVA}.tar.gz= -https://github.com/xerial/snappy-java/archive/${SNAPPY_JAVA:S/snappy-java-//}.tar.gz
31DISTFILES+= ${SNAPPY_JAVA}.tar.gz 34DISTFILES+= ${SNAPPY_JAVA}.tar.gz
32EXTRACT_ONLY+= ${SNAPPY_JAVA}.tar.gz 35EXTRACT_ONLY+= ${SNAPPY_JAVA}.tar.gz
33 36
34SNAPPY= snappy-1.0.5 37SNAPPY= snappy-1.0.5
35SITES.${SNAPPY}.tar.gz= http://download.openpkg.org/components/cache/snappy/ \ 38SITES.${SNAPPY}.tar.gz= http://download.openpkg.org/components/cache/snappy/ \
36 http://ftp.NetBSD.org/pub/pkgsrc/distfiles/snappy-java10/ 39 http://ftp.NetBSD.org/pub/pkgsrc/distfiles/snappy-java10/
37DISTFILES+= ${SNAPPY}.tar.gz 40DISTFILES+= ${SNAPPY}.tar.gz
38EXTRACT_ONLY+= ${SNAPPY}.tar.gz 41EXTRACT_ONLY+= ${SNAPPY}.tar.gz
39 42
40CHECK_SHLIBS_SKIP= unifi/lib/native/* 43CHECK_SHLIBS_SKIP= unifi/lib/native/*
41INSTALLATION_DIRS= unifi 44INSTALLATION_DIRS= unifi
42 45
43# Emulated JDK doesn't work due to epoll issues. Also, would require 46# Emulated JDK doesn't work due to epoll issues. Also, would require
44# matching emulated native libraries, and we only compile actual 47# matching emulated native libraries, and we only compile actual
45# native libaries. 48# native libaries.
46PKG_JVMS_ACCEPTED= openjdk8 49PKG_JVMS_ACCEPTED= openjdk8
47PKGSRC_MAKE_ENV+= JAVA_HOME=${PKG_JAVA_HOME} 50PKGSRC_MAKE_ENV+= JAVA_HOME=${PKG_JAVA_HOME}
48USE_LANGUAGES= c c++ # for snappy JNI library 51USE_LANGUAGES= c c++ # for snappy JNI library
49USE_TOOLS+= gmake pax 52USE_TOOLS+= gmake pax
50WRKSRC= ${WRKDIR}/UniFi 53WRKSRC= ${WRKDIR}/UniFi
51 54
52# Upstream documents 3.4.15, but 3.4.4 actually works. Avoid mongodb4 because it 55# Upstream documents 3.4.15, but 3.4.4 actually works. Avoid mongodb4 because it
53# has a problematic license. 56# has a problematic license.
54DEPENDS+= mongodb>=3.4.4:../../databases/mongodb3 57DEPENDS+= mongodb>=3.4.4:../../databases/mongodb3
55 58
56FILES_SUBST+= UNIFI_USER=${UNIFI_USER:Q} UNIFI_GROUP=${UNIFI_GROUP:Q} 59FILES_SUBST+= UNIFI_USER=${UNIFI_USER:Q} UNIFI_GROUP=${UNIFI_GROUP:Q}
57FILES_SUBST+= JAVA=${PKG_JAVA_HOME}/bin/java 60FILES_SUBST+= JAVA=${PKG_JAVA_HOME}/bin/java
58RCD_SCRIPTS= unifi 61RCD_SCRIPTS= unifi
59UNIFI_USER?= unifi 62UNIFI_USER?= unifi
60UNIFI_GROUP?= unifi 63UNIFI_GROUP?= unifi
61PKG_USERS_VARS= UNIFI_USER 64PKG_USERS_VARS= UNIFI_USER
62PKG_GROUPS_VARS= UNIFI_GROUP 65PKG_GROUPS_VARS= UNIFI_GROUP
63PKG_GROUPS= ${UNIFI_GROUP} 66PKG_GROUPS= ${UNIFI_GROUP}
64PKG_USERS= ${UNIFI_USER}:${UNIFI_GROUP} 67PKG_USERS= ${UNIFI_USER}:${UNIFI_GROUP}
65 68
66.for d in data logs run work 69.for d in data logs run work
67OWN_DIRS_PERMS+= ${PREFIX}/unifi/${d} ${UNIFI_USER} ${UNIFI_GROUP} 0700 70OWN_DIRS_PERMS+= ${PREFIX}/unifi/${d} ${UNIFI_USER} ${UNIFI_GROUP} 0700
68.endfor 71.endfor
69 72
70.include "../../mk/bsd.prefs.mk" 73.include "../../mk/bsd.prefs.mk"
71 74
72post-extract: 75post-extract:
73# drop executable bit 76# drop executable bit
74 find ${WRKSRC} -type f -print | xargs chmod -x 77 find ${WRKSRC} -type f -print | xargs chmod -x
75 mkdir ${WRKDIR}/${SNAPPY_JAVA}/target 78 mkdir ${WRKDIR}/${SNAPPY_JAVA}/target
76 ln -s ${WRKDIR}/${SNAPPY} ${WRKDIR}/${SNAPPY_JAVA}/target 79 ln -s ${WRKDIR}/${SNAPPY} ${WRKDIR}/${SNAPPY_JAVA}/target
77 80
78do-build: 81do-build:
79# bundled mongod is a linux binary; replace with symlink to native binary 82# bundled mongod is a linux binary; replace with symlink to native binary
80 rm -f ${WRKSRC}/bin/mongod 83 rm -f ${WRKSRC}/bin/mongod
81 ln -s ${PREFIX}/bin/mongod ${WRKSRC}/bin/mongod 84 ln -s ${PREFIX}/bin/mongod ${WRKSRC}/bin/mongod
82 cd ${WRKDIR}/${SNAPPY_JAVA} && ${BUILD_MAKE_CMD} native 85 cd ${WRKDIR}/${SNAPPY_JAVA} && ${BUILD_MAKE_CMD} native
83 86
84do-install: 87do-install:
85 cd ${WRKSRC} && pax -rw . ${DESTDIR}${PREFIX}/unifi 88 cd ${WRKSRC} && pax -rw . ${DESTDIR}${PREFIX}/unifi
86 ${INSTALL_LIB} ${WRKDIR}/${SNAPPY_JAVA}/target/snappy-1.0.5-Default/libsnappyjava.so ${DESTDIR}${PREFIX}/unifi/lib 89 ${INSTALL_LIB} ${WRKDIR}/${SNAPPY_JAVA}/target/snappy-1.0.5-Default/libsnappyjava.so ${DESTDIR}${PREFIX}/unifi/lib
87 90
88.include "../../mk/java-vm.mk" 91.include "../../mk/java-vm.mk"
89.include "../../mk/bsd.pkg.mk" 92.include "../../mk/bsd.pkg.mk"