blob: a4823e8da8103aeabae326adc737de6bd30b4616 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
|
# Created by: Alexey Dokuchaev <danfe@FreeBSD.org>
# $FreeBSD$
PORTNAME= luxrender
DISTVERSION= 1.4
CATEGORIES= graphics
MASTER_SITES= https://bitbucket.org/luxrender/lux/get/ \
https://bitbucket.org/luxrender/luxrays/get/:lr
DISTFILES= v${DISTVERSION:C/[.-]//g}${EXTRACT_SUFX} \
${PORTNAME}_v${DISTVERSION:S/-//}${EXTRACT_SUFX}:lr
DIST_SUBDIR= ${PORTNAME}
MAINTAINER= danfe@FreeBSD.org
COMMENT= Physically based and unbiased rendering system
LICENSE= GPLv3
LIB_DEPENDS= libboost_python.so:${PORTSDIR}/devel/boost-python-libs \
libfftw3.so:${PORTSDIR}/math/fftw3 \
libfreeimage.so:${PORTSDIR}/graphics/freeimage \
libOpenImageIO.so:${PORTSDIR}/graphics/openimageio
ONLY_FOR_ARCHS= i386 amd64
ONLY_FOR_ARCHS_REASON= uses SSE instructions
USES= bison cmake execinfo python:version tar:bzip2
USE_GL= glut glew
WRKSRC= ${WRKDIR}/luxrender-lux-${LUX_REV}
LUXRAYS_WRKSRC= ${WRKDIR}/luxrender-luxrays-${LUXRAYS_REV}
CMAKE_ARGS= -DLUXCORE_INCLUDE_DIRS:PATH="${LUXRAYS_WRKSRC}/include" \
-DLUXCORE_LIBRARY:STRING="${LUXRAYS_WRKSRC}/lib/libluxcore.a" \
-DLUXRAYS_INCLUDE_DIRS:PATH="${LUXRAYS_WRKSRC}/include" \
-DLUXRAYS_LIBRARY:STRING="${LUXRAYS_WRKSRC}/lib/libluxrays.a" \
-DSLG_INCLUDE_DIRS:PATH="${LUXRAYS_WRKSRC}/include" \
-DSLG_LIBRARY:PATH="${LUXRAYS_WRKSRC}/lib/libsmallluxgpu.a" \
-DLUXRAYS_DISABLE_OPENCL:BOOL=ON
LUX_REV= dfd211d6faa0
LUXRAYS_REV= 7c7127ee1fa4
OPTIONS_DEFINE= X11
OPTIONS_DEFAULT= X11
X11_DESC= Build GUI executable (requires Qt 4)
X11_USE= QT4=moc_build,qmake_build,rcc_build,uic_build,corelib,gui
X11_PLIST_FILES= bin/luxrender
post-patch:
@${REINPLACE_CMD} -e 's/__APPLE__/__FreeBSD__/' \
${LUXRAYS_WRKSRC}/samples/smallluxgpu4/smallluxgpu.h \
${WRKSRC}/core/osfunc.h \
${WRKSRC}/shapes/mikktspace/weldmesh.c
@${REINPLACE_CMD} -e '/^set(Boost_USE_STATIC_LIBS/s,ON,OFF,' \
${LUXRAYS_WRKSRC}/cmake/Dependencies.cmake
# Avoid picking up Python 3.x bits if they're installed
@${REINPLACE_CMD} -e 's,PythonLibs,& ${PYTHON_VER} EXACT REQUIRED,' \
${LUXRAYS_WRKSRC}/cmake/Dependencies.cmake \
${WRKSRC}/cmake/pylux.cmake
pre-configure:
cd ${LUXRAYS_WRKSRC} && ${SETENV} ${CONFIGURE_ENV} ${CMAKE_BIN} \
${CMAKE_ARGS} .
${SETENV} ${MAKE_ENV} ${MAKE_CMD} ${MAKE_FLAGS} ${MAKEFILE} \
${_MAKE_JOBS} ${MAKE_ARGS} -C ${LUXRAYS_WRKSRC}
.include <bsd.port.mk>
|