Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 4 Aug 2013 17:15:11 GMT
From:      Natacha Porté <natbsd@instinctive.eu>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/181020: graphics/luxrender update to 1.2.1
Message-ID:  <201308041715.r74HFBTu044468@oldred.freebsd.org>
Resent-Message-ID: <201308041720.r74HK0wn002578@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         181020
>Category:       ports
>Synopsis:       graphics/luxrender update to 1.2.1
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          update
>Submitter-Id:   current-users
>Arrival-Date:   Sun Aug 04 17:20:00 UTC 2013
>Closed-Date:
>Last-Modified:
>Originator:     Natacha Porté
>Release:        9.1
>Organization:
>Environment:
FreeBSD yulai 9.1-RELEASE FreeBSD 9.1-RELEASE #0 r243825: Tue Dec  4 09:23:10 UTC 2012     root@farrell.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC  amd64

>Description:
There has been a lot of changes to LuxRender since 0.7.1, so I approached this update as a new port.

It requires LuxRays library from an external port, whose addition request is PR ports/181019.
>How-To-Repeat:

>Fix:


Patch attached with submission follows:

diff -Naur luxrender.orig/Makefile luxrender/Makefile
--- luxrender.orig/Makefile	2013-08-04 13:50:53.054146983 +0200
+++ luxrender/Makefile	2013-08-04 18:34:13.396147321 +0200
@@ -2,11 +2,9 @@
 # $FreeBSD: graphics/luxrender/Makefile 314960 2013-03-22 20:06:14Z makc $
 
 PORTNAME=	luxrender
-PORTVERSION=	0.7.1
-PORTREVISION=	4
+PORTVERSION=	1.2.1
 CATEGORIES=	graphics
-MASTER_SITES=	http://src.luxrender.net/lux/archive/ \
-		http://freebsd.nsu.ru/distfiles/luxrender/
+MASTER_SITES=	http://src.luxrender.net/lux/archive/
 DISTNAME=	${HG_NODEID}
 DIST_SUBDIR=	${PORTNAME}
 
@@ -15,30 +13,30 @@
 
 LICENSE=	GPLv3
 
-ONLY_FOR_ARCHS=	i386 amd64
-BROKEN=		does not build with boost-1.48.0
-
-BUILD_DEPENDS=	${LOCALBASE}/lib/libfreeimage.a:${PORTSDIR}/graphics/freeimage
+BUILD_DEPENDS=	${LOCALBASE}/lib/libluxrays.a:${PORTSDIR}/graphics/luxrays
 LIB_DEPENDS=	boost_thread:${PORTSDIR}/devel/boost-libs \
+		boost_python:${PORTSDIR}/devel/boost-python-libs \
+		freeimage:${PORTSDIR}/graphics/freeimage \
 		png15:${PORTSDIR}/graphics/png \
-		IlmImf:${PORTSDIR}/graphics/OpenEXR \
+		IlmImf:${PORTSDIR}/graphics/OpenEXR
 
-HG_NODEID=	9206b3ba7011
+HG_NODEID=	3066b2161439
 
 USE_BZIP2=	yes
 USES=		bison cmake
 WRKSRC=		${WRKDIR}/lux-${HG_NODEID}
 MAKE_JOBS_SAFE=	yes
 
+CMAKE_ARGS=	-DLUXRAYS_DISABLE_OPENCL:BOOL=ON
+
 DESKTOP_ENTRIES="LuxRender" "${COMMENT}" \
 		"${PREFIX}/share/pixmaps/luxrender.svg" "${PORTNAME}" \
 		"Graphics;3DGraphics;" false
 
-OPTIONS_DEFINE=		QT4 WX
+OPTIONS_DEFINE=		QT4
 OPTIONS_DEFAULT=	QT4
 
 QT4_DESC=		Qt4-enabled GUI executable
-WX_DESC=		wxWidgets-enabled GUI executable
 
 .include <bsd.port.options.mk>
 
@@ -47,19 +45,4 @@
 PLIST_FILES+=	bin/luxrender
 .endif
 
-.if ${PORT_OPTIONS:MWX}
-USE_WX=		2.8+
-PLIST_FILES+=	bin/luxrenderwx
-.endif
-
-post-patch:
-# Prevent appending `64' suffix to `lib' directory on amd64, do not install
-# vendor .desktop file, disable build of Python extension for now
-	@${REINPLACE_CMD} -e '/LIB_SUFFIX 64/d ; /luxrender\.desktop/d ; \
-		89,95d ; 803,837d' ${WRKSRC}/CMakeLists.txt
-# Adjust for libpng 1.4 new API
-	@${REINPLACE_CMD} -e \
-		's|png_set_gray_1_2_4_to_8|png_set_expand_gray_1_2_4_to_8|' \
-		-e 's|int_p_NULL|NULL|g' ${WRKSRC}/core/external/cimg.h
-
 .include <bsd.port.mk>
diff -Naur luxrender.orig/distinfo luxrender/distinfo
--- luxrender.orig/distinfo	2013-08-04 13:50:53.054146983 +0200
+++ luxrender/distinfo	2013-08-04 13:51:58.485146866 +0200
@@ -1,2 +1,2 @@
-SHA256 (luxrender/9206b3ba7011.tar.bz2) = 8af12fbebf29e62f3203b02fe28a11304f7d48f23f87e7a053c804149cbfcc56
-SIZE (luxrender/9206b3ba7011.tar.bz2) = 1998376
+SHA256 (luxrender/3066b2161439.tar.bz2) = 7788f2754400791643148b0536de10be75cf85e2201616182700db71d11ba8ae
+SIZE (luxrender/3066b2161439.tar.bz2) = 2473927
diff -Naur luxrender.orig/files/patch-CMakeLists.txt luxrender/files/patch-CMakeLists.txt
--- luxrender.orig/files/patch-CMakeLists.txt	2013-08-04 13:50:53.054146983 +0200
+++ luxrender/files/patch-CMakeLists.txt	2013-08-04 17:41:06.608146772 +0200
@@ -1,56 +1,20 @@
---- CMakeLists.txt.orig
-+++ CMakeLists.txt
-@@ -842,18 +841,6 @@
+--- CMakeLists.txt.orig	2013-08-04 16:56:47.933146631 +0200
++++ CMakeLists.txt	2013-08-04 17:40:59.757146596 +0200
+@@ -180,7 +180,7 @@
+ 	STRING(REGEX MATCH "(x86_64-*)|(X86_64-*)|(AMD64-*)|(amd64-*)" _mach_x86_64 ${MACHINE})
+ 	IF (_mach_x86_64)
+ 		SET(ARCH_X86_64 1)
+-		SET(LIB_SUFFIX 64)
++#		SET(LIB_SUFFIX 64)
+ 		#jromang - Hack to avoid boost bug on x64  Ubuntu 8.10 and Fedora 10 (http://www.luxrender.net/mantis/view.php?id=433)
+ 		ADD_DEFINITIONS(-DBOOST_NO_INTRINSIC_INT64_T)
+ 	ENDIF (_mach_x86_64)
+@@ -398,7 +398,7 @@
+ 	SET(CMAKE_BUILD_WITH_INSTALL_RPATH TRUE)
+ 	SET(CMAKE_INSTALL_RPATH "$ORIGIN")
+ ENDIF(APPLE)
+-SET(LUX_LIBRARY_DEPENDS ${LUXRAYS_LIBRARY} ${OPENCL_LIBRARIES} ${OPENGL_LIBRARY} ${FREEIMAGE_LIBRARIES} ${Boost_LIBRARIES} ${SYS_LIBRARIES})
++SET(LUX_LIBRARY_DEPENDS ${LUXRAYS_LIBRARY} ${OPENCL_LIBRARIES} ${OPENGL_LIBRARY} ${FREEIMAGE_LIBRARIES} ${OPENEXR_LIBRARIES} ${Boost_LIBRARIES} ${SYS_LIBRARIES})
  
  #############################################################################
  #############################################################################
--###########################      Find OpenGL       ##########################
--#############################################################################
--#############################################################################
--SET(OPENGL_LIBRARY ${CMAKE_ROOT}/Modules/FindOpenGL.cmake)
--INCLUDE(${CMAKE_ROOT}/Modules/FindOpenGL.cmake)
--
--MESSAGE(STATUS "OpenGL include directory: " ${OPENGL_INCLUDE_DIR})
--
--INCLUDE_DIRECTORIES(SYSTEM ${OPENGL_INCLUDE_DIR})
--
--#############################################################################
--#############################################################################
- ######################### wxWidgets LIBRARIES SETUP #########################
- #############################################################################
- #############################################################################
-@@ -864,6 +851,11 @@
- FIND_PACKAGE(wxWidgets)
- 
- IF(wxWidgets_FOUND)
-+	SET(OPENGL_LIBRARY ${CMAKE_ROOT}/Modules/FindOpenGL.cmake)
-+	INCLUDE(${CMAKE_ROOT}/Modules/FindOpenGL.cmake)
-+	MESSAGE(STATUS "OpenGL include directory: " ${OPENGL_INCLUDE_DIR})
-+	INCLUDE_DIRECTORIES(SYSTEM ${OPENGL_INCLUDE_DIR})
-+
- 	# Include wxWidgets macros
- 	INCLUDE(${wxWidgets_USE_FILE})
- 	MESSAGE( STATUS "wxWidgets include directory: " ${wxWidgets_INCLUDE_DIRS} )
-@@ -955,16 +947,14 @@
- 
- #############################################################################
- 
--#Install target
-+#Install targets
- IF(wxWidgets_FOUND)
--	INSTALL(TARGETS luxrender luxrenderwx luxconsole luxmerger
--      	  RUNTIME DESTINATION bin
--	)
--ELSE(wxWidgets_FOUND)
--	INSTALL(TARGETS luxrender luxconsole luxmerger
--      	  RUNTIME DESTINATION bin
--	)
-+	INSTALL(TARGETS luxrenderwx RUNTIME DESTINATION bin)
- ENDIF(wxWidgets_FOUND)
-+IF(QT4_FOUND)
-+	INSTALL(TARGETS luxrender RUNTIME DESTINATION bin)
-+ENDIF(QT4_FOUND)
-+INSTALL(TARGETS luxconsole luxmerger RUNTIME DESTINATION bin)
- 
- #Install API/Library
- INSTALL(FILES ${CMAKE_SOURCE_DIR}/core/api.h DESTINATION include/luxrender/)
diff -Naur luxrender.orig/files/patch-core-osfunc.h luxrender/files/patch-core-osfunc.h
--- luxrender.orig/files/patch-core-osfunc.h	1970-01-01 01:00:00.000000000 +0100
+++ luxrender/files/patch-core-osfunc.h	2013-08-04 14:46:06.198147419 +0200
@@ -0,0 +1,20 @@
+--- core/osfunc.h.orig	2013-08-04 14:43:46.534147955 +0200
++++ core/osfunc.h	2013-08-04 14:44:36.228149058 +0200
+@@ -30,7 +30,7 @@
+ #include <istream>
+ #include <ostream>
+ 
+-#if defined(__linux__) || defined(__APPLE__) || defined(__CYGWIN__)
++#if defined(__linux__) || defined(__APPLE__) || defined(__CYGWIN__) || defined(__FreeBSD__)
+ #include <stddef.h>
+ #include <sys/time.h>
+ #elif defined (WIN32)
+@@ -85,7 +85,7 @@
+ 		std::basic_istream<char> &is);
+ 
+ inline double osWallClockTime() {
+-#if defined(__linux__) || defined(__APPLE__) || defined(__CYGWIN__)
++#if defined(__linux__) || defined(__APPLE__) || defined(__CYGWIN__) || defined(__FreeBSD__)
+ 	struct timeval t;
+ 	gettimeofday(&t, NULL);
+ 
diff -Naur luxrender.orig/files/patch-shapes-mikktspace-weldmesh.c luxrender/files/patch-shapes-mikktspace-weldmesh.c
--- luxrender.orig/files/patch-shapes-mikktspace-weldmesh.c	1970-01-01 01:00:00.000000000 +0100
+++ luxrender/files/patch-shapes-mikktspace-weldmesh.c	2013-08-04 14:59:00.546146910 +0200
@@ -0,0 +1,18 @@
+--- shapes/mikktspace/weldmesh.c.orig	2013-08-04 14:58:10.866146688 +0200
++++ shapes/mikktspace/weldmesh.c	2013-08-04 14:58:27.792146864 +0200
+@@ -23,7 +23,7 @@
+ #include <string.h>
+ #include <assert.h>
+ 
+-#ifdef __APPLE__
++#if defined(__APPLE__) || defined(__FreeBSD__)
+ #include <stdlib.h>  /* OSX gets its malloc stuff through here */
+ #else
+ #include <malloc.h> 
+@@ -191,4 +191,4 @@
+ 			MergeVertsFast(piCurNrUniqueVertices, piRemapTable, pfVertexDataOut, piVertexIDs,
+ 						   pfVertexDataIn, iNrVerticesIn, iFloatsPerVert, iL, iR_in, iChannelNum);	// weld all right of (or equal to) fSep
+ 	}
+-}
+\ No newline at end of file
++}
diff -Naur luxrender.orig/pkg-plist luxrender/pkg-plist
--- luxrender.orig/pkg-plist	2013-08-04 13:50:53.054146983 +0200
+++ luxrender/pkg-plist	2013-08-04 17:55:54.281148474 +0200
@@ -2,5 +2,5 @@
 bin/luxmerger
 include/luxrender/api.h
 @dirrm include/luxrender
-lib/liblux.a
+lib/liblux.so
 share/pixmaps/luxrender.svg


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201308041715.r74HFBTu044468>