75 lines
2.4 KiB
Makefile
75 lines
2.4 KiB
Makefile
# Created by: Mia <mia-rain@tuta.io>
|
|
|
|
PORTNAME= lwjgl3
|
|
DISTVERSION= 3.2.4.alpha2
|
|
CATEGORIES= games java
|
|
MASTER_SITES= https://github.com/JetBrains/kotlin/releases/download/v1.3.61/:compiler https://kurt.mosiejcz.uk/pub/distfiles/:maven
|
|
DISTFILES+= kotlin-compiler-1.3.61.zip:compiler lwjgl3-maven-20210208.tar.gz:maven
|
|
# these maven libaraies are pulled from openbsd; their original source is https://www.lwjgl.org/customize with mode:maven
|
|
# however 3.2.4* is an unoffical release and modifications may have been made to the maven libs
|
|
EXTRACT_ONLY= ${DISTNAME}.tar.gz
|
|
|
|
MAINTAINER= mia-rain@tuta.io
|
|
COMMENT= Lightweight Java Game Library v3
|
|
|
|
LICENSE= BSD3CLAUSE
|
|
|
|
ONLY_FOR_ARCHS= amd64 powerpc64 powerpc64le
|
|
|
|
BROKEN_i386= ld: error: undefined symbol: __stack_smash_handler # openbsd reports this error, however I am unable to test it
|
|
|
|
BUILD_DEPENDS= ant:devel/apache-ant \
|
|
unzip:archivers/unzip \
|
|
ant:devel/apache-ant \
|
|
${PREFIX}/libdata/pkgconfig/bullet.pc:devel/bullet \
|
|
${PREFIX}/include/dynload.h:devel/dyncall\
|
|
${PREFIX}/libdata/pkgconfig/liblz4.pc:archivers/liblz4
|
|
LIB_DEPENDS= libopenal.so:audio/openal-soft \
|
|
libopus.so:audio/opus \
|
|
liblmdb.so:databases/lmdb \
|
|
libglfw.so:graphics/glfw \
|
|
libassimp.so:multimedia/assimp \
|
|
libxxhash.so:devel/xxhash \
|
|
libgtk-3.so:x11-toolkits/gtk30
|
|
|
|
USES= dos2unix xorg
|
|
USE_GITHUB= yes
|
|
|
|
GH_ACCOUNT= kmosiejczuk
|
|
GH_TAGNAME= 3b9d8ce
|
|
GH_PROJECT= ${PORTNAME}
|
|
|
|
DOS2UNIX_REGEX= .*.[^jp][^an][^rg]$
|
|
USE_JAVA= yes
|
|
USE_ANT= yes
|
|
USE_XORG= xcursor xrandr xxf86vm
|
|
MAKE_ENV+= LWJGL_BUILD_OFFLINE=true
|
|
ALL_TARGET= compile-templates generate compile release
|
|
|
|
JAVA_VERSION= 8
|
|
# LWJGL3 calls for 10+ however bindings /fails/ to compile on newer than 8
|
|
# lang/rhino might fix this
|
|
|
|
LWJGL3_HOME= ${JAVASHAREDIR}/lwjgl3
|
|
|
|
.include <bsd.port.pre.mk>
|
|
|
|
post-extract:
|
|
${MKDIR} ${WRKSRC}/bin/libs
|
|
${LOCALBASE}/bin/unzip -oq -d ${WRKSRC}/bin/libs/ \
|
|
${DISTDIR}/kotlin-compiler-1.3.61.zip
|
|
${TAR} -C ${WRKSRC}/bin/libs -zxf \
|
|
${DISTDIR}/lwjgl3-maven-20210208.tar.gz
|
|
do-install:
|
|
${SETENV} ${MAKE_ENV} LWJGL_BUILD_OFFLINE=true
|
|
${RM} ${WRKSRC}/bin/RELEASE/lwjgl*/lwjgl-*-sources.jar
|
|
${MKDIR} ${STAGEDIR}/${LWJGL3_HOME}
|
|
for x in ${WRKSRC}/bin/RELEASE/lwjgl*/*.jar; do \
|
|
${INSTALL_DATA} $$x ${STAGEDIR}/${LWJGL3_HOME}/; \
|
|
done
|
|
for x in ${WRKSRC}/bin/RELEASE/lwjgl*/*license.txt; do \
|
|
${INSTALL_DATA} $$x ${STAGEDIR}/${LWJGL3_HOME}/; \
|
|
done
|
|
|
|
.include <bsd.port.post.mk>
|