From 43c725ceb0f7aed19cf038dc60aa390a696cb929 Mon Sep 17 00:00:00 2001 From: Klaatu Date: Mon, 22 Jun 2015 18:30:24 +0700 Subject: graphics/luxrender: Updated for version 1.4 + new maintainer. Signed-off-by: Willy Sudiarto Raharjo --- graphics/luxrender/README | 45 ++++- graphics/luxrender/application-x-lux.svg | 306 +++++++++++++++++++++++++++++++ graphics/luxrender/doinst.sh | 4 + graphics/luxrender/luxrender.SlackBuild | 163 ++++++---------- graphics/luxrender/luxrender.desktop | 9 + graphics/luxrender/luxrender.info | 20 +- graphics/luxrender/luxrender.svg | 252 +++++++++++++++++++++++++ graphics/luxrender/mime-lux.xml | 12 ++ 8 files changed, 694 insertions(+), 117 deletions(-) create mode 100644 graphics/luxrender/application-x-lux.svg create mode 100644 graphics/luxrender/luxrender.desktop create mode 100644 graphics/luxrender/luxrender.svg create mode 100644 graphics/luxrender/mime-lux.xml diff --git a/graphics/luxrender/README b/graphics/luxrender/README index cc6d31e58a..f6edc0cd74 100644 --- a/graphics/luxrender/README +++ b/graphics/luxrender/README @@ -1,4 +1,43 @@ +LuxRender +========= + LuxRender is a physically based and unbiased rendering engine. -Based on state of the art algorithms, LuxRender simulates the flow -of light according to physical equations, thus producing realistic -images of photographic quality. +Based on state of the art algorithms, LuxRender simulates the flow of light according +to physical equations, thus producing realistic images of photographic quality. +It is fully-featured, with a command line application as well as a GUI, widespread +render farm support, instancing, volumetrics, motion blur, and more. + +This package supports 64-bit systems only, because it installs the pre-compiled LuxRender +package. It is possible to install LuxRender on 32-bit system, but it requires building from source. + + +Optional Depencencies: +------------ +opencl-headers +cudatoolkit +nvidia-driver + +Install Options: +---------------- +To install without OpenCL support, launch this script like this: + +$ OPENCL=no ./luxrender.SlackBuild + +Blender Plugin +-------------- +By default, this SlackBuild: +1. Attempts to auto-detect where your Blender install is by grepping /var/log/packages +2. Attempts to install the Blender plugin to that location + +If you do not want it to attempt to do this, do: + +$ BLENDER=no ./luxrender.SlackBuild + +The Blender plugin will be copied to /usr/share/luxrender-VERSION + +If you do have Blender, but in a different path than the SlackBuild.org path,, or not +listed in /var/log/packages for some reason, then you can hardcode the path: + +$ BLENDER=/path/to/blender/scripts ./luxrender.SlackBuild + +IMPORTANT: Point to your Blender **scripts** directory. diff --git a/graphics/luxrender/application-x-lux.svg b/graphics/luxrender/application-x-lux.svg new file mode 100644 index 0000000000..2c1da03832 --- /dev/null +++ b/graphics/luxrender/application-x-lux.svg @@ -0,0 +1,306 @@ + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/graphics/luxrender/doinst.sh b/graphics/luxrender/doinst.sh index 7f740b456f..de6fed18f6 100644 --- a/graphics/luxrender/doinst.sh +++ b/graphics/luxrender/doinst.sh @@ -1,3 +1,7 @@ +if [ -x /usr/bin/xdg-mime ]; then + /usr/bin/xdg-mime install /usr/doc/luxrender-1.4/mime-lux.xml +fi + if [ -x /usr/bin/update-desktop-database ]; then /usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1 fi diff --git a/graphics/luxrender/luxrender.SlackBuild b/graphics/luxrender/luxrender.SlackBuild index 8203283da2..504fce5cfd 100644 --- a/graphics/luxrender/luxrender.SlackBuild +++ b/graphics/luxrender/luxrender.SlackBuild @@ -2,7 +2,9 @@ # Slackware build script for luxrender -# Copyright 2013 Giorgio Peron Campodarsego, PD, Italy giorgio.peron@gmail.com +# Copyright 2013 Giorgio Peron Campodarsego, PD, Italy +# Copyright 2015 Klaatu Wellington, NZ +# # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -23,17 +25,27 @@ # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. PRGNAM=luxrender -VERSION=${VERSION:-1.3.1} +SHORT=lux +VERSION=${VERSION:-1.4} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} -SRCVERSION=lux-d0b0e20c47cc -LUXRAYSRCVERSION=luxrays-7459cd8a9583 + +if [ -z $OPENCL ]; then + OPENCL="-OpenCL" +else + OPENCL="" +fi if [ -z "$ARCH" ]; then case "$( uname -m )" in - i?86) ARCH=i486 ;; - arm*) ARCH=arm ;; - *) ARCH=$( uname -m ) ;; + i?86) echo "32 bit builds not supported." && exit 1 + ;; + arm*) ARCH=arm + LIBDIRSUFFIX="" + ;; + *) ARCH=$( uname -m ) + LIBDIRSUFFIX="64" + ;; esac fi @@ -56,18 +68,14 @@ else LIBDIRSUFFIX="" fi -set -e +set -e rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT cd $TMP -rm -rf $PRGNAM-$VERSION -rm -rf $LUXRAYSRCVERSION -rm -rf $SRCVERSION -tar xvjf $CWD/$SRCVERSION.tar.bz2 -tar xvjf $CWD/$LUXRAYSRCVERSION.tar.bz2 - -cd $TMP/$LUXRAYSRCVERSION +rm -rf $SHORT-$VERSION +tar xvjf $CWD/$SHORT-v"$VERSION"-x86_64-sse2"$OPENCL".tar.bz2 +cd $SHORT-v"$VERSION"-$(uname -m)-sse2"$OPENCL" chown -R root:root . find -L . \ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ @@ -75,103 +83,50 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; -# fix some make files -sed -i \ - -e "/project(LuxRays)/ a\ -SET(BUILD_LUXMARK on)" \ - -e "/project(LuxRays)/ a\ -set(OPENGL_INCLUDE_DIR /usr/include/GL)" \ - CMakeLists.txt -sed -i \ - -e "/# Lookup user provide path first/ a\ -SET(OPENCL_ROOT /usr/share)" \ - -e "s:PATHS \$ENV{ATISTREAMSDKROOT}:PATHS \${OPENCL_ROOT} \$ENV{ATISTREAMSDKROOT}:" \ - cmake/Packages/FindOpenCL.cmake - -# luxmark moc files -cd samples/luxmark -moc aboutdialog.h -o moc_aboutdialog.cxx -moc hardwaretree.h -o moc_hardwaretree.cxx -moc luxmarkapp.h -o moc_luxmarkapp.cxx -moc mainwindow.h -o moc_mainwindow.cxx -moc resultdialog.h -o moc_resultdialog.cxx -moc submitdialog.h -o moc_submitdialog.cxx -cd - - -cmake \ - -DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \ - -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \ - -DCMAKE_BUILD_TYPE=Release . - -# compile luxrays -make luxrays -make slg4 -make luxmark - # manual installation -mkdir -p $PKG/usr/share/$PRGNAM/resources $PKG/usr/share/$PRGNAM/scenes -cp bin/* $PKG/usr/share/$PRGNAM -cp -r samples/luxmark/resources $PKG/usr/share/$PRGNAM -cp -r scenes $PKG/usr/share/$PRGNAM -cp -r samples/luxmark/scenes $PKG/usr/share/$PRGNAM - -mkdir -p $PKG/usr/bin -cat > $PKG/usr/bin/luxmark << EOF -#!/bin/sh -cd /usr/share/luxrender -./luxmark >/dev/null 2>&1 -EOF -chmod +x $PKG/usr/bin/luxmark -cat > $PKG/usr/bin/slg4 << EOF -#!/bin/sh -cd /usr/share/luxrender -./slg4 >/dev/null 2>&1 -EOF +mkdir -p $PKG/usr/bin/ +cp luxconsole $PKG/usr/bin/ +cp lux*r $PKG/usr/bin/ +cp slg4 $PKG/usr/bin/ chmod +x $PKG/usr/bin/slg4 +mkdir -p $PKG/usr/lib"$LIBDIRSUFFIX" +cp *.so $PKG/usr/lib"$LIBDIRSUFFIX" -cd $TMP/$SRCVERSION -chown -R root:root . -find -L . \ - \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ - -o -perm 511 \) -exec chmod 755 {} \; -o \ - \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ - -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; - -# # fix some make files -sed -i \ - -e "/########################## Find LuxRays ##########################/ a\ -SET(LuxRays_HOME $TMP/$LUXRAYSRCVERSION)" \ - -e "s:PATHS ../luxrays/include:PATHS \${LuxRays_HOME}/include:" \ - -e "s:/usr/src/opencl-sdk:/usr/share/cuda:" \ - cmake/Dependencies.cmake -sed -i \ - -e "s:-Wall -fPIC -DHAVE_PTHREAD_H:-Wall -fPIC -DHAVE_PTHREAD_H -l png14:" \ - -e "s:E} -fvisibility=hidden -fvisibility-inlines-hidden:E} -fvisibility=hidden -fvisibility-inlines-hidden -lpthread:" \ - -e "s:#SET(CMAKE_VERBOSE_MAKEFILE:SET(CMAKE_VERBOSE_MAKEFILE:g" \ - -e "/SET(CMAKE_VERBOSE_MAKEFILE true)/ a\ -SET(CMAKE_CXX_FLAGS_RELEASE \"-lpthread\")" \ - CMakeLists.txt - -cmake . - -# compile luxrender -make luxrender -make install DESTDIR=$PKG - -# /usr/local? no, thanks -cp -r $PKG/usr/local/* $PKG/usr -rm -rf $PKG/usr/local - -# copy pylux.so -cp pylux.so $PKG/usr/lib$LIBDIRSUFFIX/ - -# Strip binaries and libraries. find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true +# are we using default SBo location of blender? +if [ -z $BLENDER ]; then + BLENDER=$(egrep '^opt\/blender\/2\....?\/scripts\/$' /var/log/packages/blender-*_SBo 2> /dev/null) || BLENDER="no" +fi + +if [ X"$BLENDER" != "Xno" ]; then + mkdir -p $PKG/$BLENDER + unzip luxblend/luxblend.zip -d $PKG/$BLENDER/addons/ + unzip luxblend/luxblend-presets.zip -d $PKG/$BLENDER/presets/ +else + mkdir -p $PKG/usr/share/$PRGNAM-$VERSION/luxblend + cp luxblend/luxblend.zip $PKG/usr/share/$PRGNAM-$VERSION/luxblend + cp luxblend/luxblend-presets.zip $PKG/usr/share/$PRGNAM-$VERSION/luxblend +fi + +mkdir -p $PKG/usr/share/applications +mkdir -p $PKG/usr/share/$PRGNAM-$VERSION +cp -r examples $PKG/usr/share/$PRGNAM-$VERSION +cp $CWD/$PRGNAM.desktop $PKG/usr/share/applications + +#icons +mkdir -p $PKG/usr/share/icons/hicolor/scalable/mimetypes +cp $CWD/application-x-lux.svg $PKG/usr/share/icons/hicolor/scalable/mimetypes +cp $CWD/luxrender.svg $PKG/usr/share/icons/hicolor/scalable/apps + +#mimetypes +mkdir -p $PKG/usr/share/mime/application/ + mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION -cp -a AUTHORS.txt COPYING.txt $PKG/usr/doc/$PRGNAM-$VERSION +cp README $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild +cat $CWD/mime-"$SHORT".xml > $PKG/usr/doc/$PRGNAM-$VERSION/mime-"$SHORT".xml mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc diff --git a/graphics/luxrender/luxrender.desktop b/graphics/luxrender/luxrender.desktop new file mode 100644 index 0000000000..d8a6bc053c --- /dev/null +++ b/graphics/luxrender/luxrender.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Name=Lux +GenericName=Lux Renderer +Comment=LuxRender unbiased rendering system +Exec=luxrender +Icon=/usr/share/pixmaps/luxrender.svg +Terminal=false +Type=Application +Categories=Application;Graphics;3DGraphics diff --git a/graphics/luxrender/luxrender.info b/graphics/luxrender/luxrender.info index 6ca0ac80d7..f8298447e3 100644 --- a/graphics/luxrender/luxrender.info +++ b/graphics/luxrender/luxrender.info @@ -1,12 +1,12 @@ PRGNAM="luxrender" -VERSION="1.3.1" +VERSION="1.4" HOMEPAGE="http://www.luxrender.net/" -DOWNLOAD="http://src.luxrender.net/luxrays/archive/7459cd8a9583.tar.bz2 \ - http://src.luxrender.net/lux/archive/d0b0e20c47cc.tar.bz2" -MD5SUM="4dc151e3cf6d1da8ce5d78146a60382a \ - 79eb38569540b6be7091aee5768c9d96" -DOWNLOAD_x86_64="" -MD5SUM_x86_64="" -REQUIRES="cudatoolkit nvidia-driver opencl-headers FreeImage" -MAINTAINER="Giorgio Peron" -EMAIL="giorgio.peron@gmail.com" +DOWNLOAD="UNSUPPORTED" +MD5SUM="" +DOWNLOAD_x86_64="http://www.luxrender.net/release/luxrender/1.4/linux/64/lux-v1.4-x86_64-sse2-OpenCL.tar.bz2 \ + http://www.luxrender.net/release/luxrender/1.4/linux/64/lux-v1.4-x86_64-sse2.tar.bz2" +MD5SUM_x86_64="6635929c033c55c4300c8fc928fa1647 \ + ec37591dd3efca4c0ab2051bcc9e64e1" +REQUIRES="FreeImage" +MAINTAINER="Klaatu" +EMAIL="klaatu@member.fsf.org" diff --git a/graphics/luxrender/luxrender.svg b/graphics/luxrender/luxrender.svg new file mode 100644 index 0000000000..9d8cb65ba0 --- /dev/null +++ b/graphics/luxrender/luxrender.svg @@ -0,0 +1,252 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/graphics/luxrender/mime-lux.xml b/graphics/luxrender/mime-lux.xml new file mode 100644 index 0000000000..3843873ab8 --- /dev/null +++ b/graphics/luxrender/mime-lux.xml @@ -0,0 +1,12 @@ + + + +LuxRender File + + + + + + + -- cgit v1.2.3