Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LuxCore needs to link with libOpenImageIO_Util starting with 2.3 #559

Open
hobbes1069 opened this issue Oct 5, 2021 · 0 comments
Open

Comments

@hobbes1069
Copy link

There was some redundant code in both the main and _Util library which was removed from the main library as of 2.3.0. Now LuxCore needs to link with the _Util library.

The following inelegant patch fixed the build for Fedora. Since I only built OIIO 2.3 in Fedora Rawhide I didn't need to do any version testing.

Index: LuxCore-luxcorerender_v2.5/cmake/Packages/FindOpenImageIO.cmake
===================================================================
--- LuxCore-luxcorerender_v2.5.orig/cmake/Packages/FindOpenImageIO.cmake
+++ LuxCore-luxcorerender_v2.5/cmake/Packages/FindOpenImageIO.cmake
@@ -55,6 +55,15 @@ FIND_LIBRARY(OPENIMAGEIO_LIBRARY
     lib64 lib x64/Release/lib
   )
 
+FIND_LIBRARY(OPENIMAGEIO_UTIL_LIBRARY
+  NAMES
+    OpenImageIO_Util
+  HINTS
+    ${_openimageio_SEARCH_DIRS}
+  PATH_SUFFIXES
+    lib64 lib x64/Release/lib
+  )
+
 # handle the QUIETLY and REQUIRED arguments and set OPENIMAGEIO_FOUND to TRUE if 
 # all listed variables are TRUE
 INCLUDE(FindPackageHandleStandardArgs)
@@ -62,7 +71,7 @@ FIND_PACKAGE_HANDLE_STANDARD_ARGS(OpenIm
     OPENIMAGEIO_LIBRARY OPENIMAGEIO_INCLUDE_DIR)
 
 IF(OPENIMAGEIO_FOUND)
-  SET(OPENIMAGEIO_LIBRARIES ${OPENIMAGEIO_LIBRARY})
+  SET(OPENIMAGEIO_LIBRARIES ${OPENIMAGEIO_LIBRARY} ${OPENIMAGEIO_UTIL_LIBRARY})
   SET(OPENIMAGEIO_INCLUDE_DIRS ${OPENIMAGEIO_INCLUDE_DIR})
 ENDIF(OPENIMAGEIO_FOUND)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant