Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 12 Apr 2021 00:34:48 GMT
From:      Matthias Andree <mandree@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: fd17965a3812 - main - graphics/osg: make compatible with OpenEXR/Imath 3.0
Message-ID:  <202104120034.13C0Ym0B092801@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by mandree:

URL: https://cgit.FreeBSD.org/ports/commit/?id=fd17965a38127d00b3270cec83e58154cdfd6964

commit fd17965a38127d00b3270cec83e58154cdfd6964
Author:     Matthias Andree <mandree@FreeBSD.org>
AuthorDate: 2021-04-11 22:30:02 +0000
Commit:     Matthias Andree <mandree@FreeBSD.org>
CommitDate: 2021-04-12 00:33:52 +0000

    graphics/osg: make compatible with OpenEXR/Imath 3.0
---
 graphics/osg/Makefile                              |  6 ++--
 .../osg/files/patch-CMakeModules_FindOpenEXR.cmake | 35 ++++++++++++++++++++++
 2 files changed, 39 insertions(+), 2 deletions(-)

diff --git a/graphics/osg/Makefile b/graphics/osg/Makefile
index 75f88d6778ec..214780322ddb 100644
--- a/graphics/osg/Makefile
+++ b/graphics/osg/Makefile
@@ -3,7 +3,7 @@
 PORTNAME=	osg
 PORTVERSION=	3.6.5
 DISTVERSIONPREFIX=	OpenSceneGraph-
-PORTREVISION=	19
+PORTREVISION=	20
 CATEGORIES=	graphics
 
 MAINTAINER=	amdmi3@FreeBSD.org
@@ -28,6 +28,8 @@ USE_GL=		gl
 USE_XORG=	x11
 USE_LDCONFIG=	yes
 
+CFLAGS+=	-I${LOCALBASE}/include/Imath -DInt64=uint64_t
+
 PLIST_SUB=	OSG_VERSION=${PORTVERSION} \
 		OSG_SHLIBVER=161 \
 		OPENTHREADS_VERSION=3.3.1 \
@@ -87,7 +89,7 @@ LUA_VARS_OFF=		FORCE_IGNORE+="Lua51 Lua52"
 NVTT_LIB_DEPENDS=	libnvtt.so:graphics/nvidia-texture-tools
 NVTT_VARS=		FORCE_REQUIRE+=NVTT
 NVTT_VARS_OFF=		FORCE_IGNORE+=NVTT
-OPENEXR_LIB_DEPENDS=	libIlmImf.so:graphics/openexr
+OPENEXR_LIB_DEPENDS=	libOpenEXR.so:graphics/openexr libImath.so:math/Imath
 OPENEXR_VARS=		FORCE_REQUIRE+=OpenEXR
 OPENEXR_VARS_OFF=	FORCE_IGNORE+=OpenEXR
 PDF_LIB_DEPENDS=	libpoppler-glib.so:graphics/poppler-glib
diff --git a/graphics/osg/files/patch-CMakeModules_FindOpenEXR.cmake b/graphics/osg/files/patch-CMakeModules_FindOpenEXR.cmake
new file mode 100644
index 000000000000..17951fdb2561
--- /dev/null
+++ b/graphics/osg/files/patch-CMakeModules_FindOpenEXR.cmake
@@ -0,0 +1,35 @@
+--- CMakeModules/FindOpenEXR.cmake.orig	2021-04-11 22:06:00 UTC
++++ CMakeModules/FindOpenEXR.cmake
+@@ -25,7 +25,7 @@ FIND_PATH(OPENEXR_INCLUDE_DIR OpenEXR/ImfIO.h
+ )
+ 
+ # Macro to find exr libraries (deduplicating search paths)
+-# example: OPENEXR_FIND_VAR(OPENEXR_IlmImf_LIBRARY IlmImf)
++# example: OPENEXR_FIND_VAR(OPENEXR_OpenEXR_LIBRARY OpenEXR)
+ MACRO(OPENEXR_FIND_VAR varname libname)
+     FIND_LIBRARY( ${varname}
+         NAMES ${libname} ${libname}-2_1 ${libname}-2_2
+@@ -45,17 +45,17 @@ MACRO(OPENEXR_FIND_VAR varname libname)
+ ENDMACRO(OPENEXR_FIND_VAR)
+ 
+ # Macro to find exr libraries (and debug versions)
+-# example: OPENEXR_FIND(IlmImf)
++# example: OPENEXR_FIND(OpenEXR)
+ MACRO(OPENEXR_FIND libname)
+     OPENEXR_FIND_VAR(OPENEXR_${libname}_LIBRARY ${libname})
+     OPENEXR_FIND_VAR(OPENEXR_${libname}_LIBRARY_DEBUG ${libname}d)
+ ENDMACRO(OPENEXR_FIND)
+ 
+-OPENEXR_FIND(IlmImf)
++OPENEXR_FIND(OpenEXR)
+ 
+ SET(OPENEXR_FOUND "NO")
+-IF(OPENEXR_INCLUDE_DIR AND OPENEXR_IlmImf_LIBRARY)
+-    SET(OPENEXR_LIBRARIES ${OPENEXR_IlmImf_LIBRARY} )
+-    SET(OPENEXR_LIBRARIES_VARS OPENEXR_IlmImf_LIBRARY )
++IF(OPENEXR_INCLUDE_DIR AND OPENEXR_OpenEXR_LIBRARY)
++    SET(OPENEXR_LIBRARIES ${OPENEXR_OpenEXR_LIBRARY} )
++    SET(OPENEXR_LIBRARIES_VARS OPENEXR_OpenEXR_LIBRARY )
+     SET(OPENEXR_FOUND "YES")
+-ENDIF(OPENEXR_INCLUDE_DIR AND OPENEXR_IlmImf_LIBRARY)
++ENDIF(OPENEXR_INCLUDE_DIR AND OPENEXR_OpenEXR_LIBRARY)



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