Skip to content

Commit

Permalink
Try to disable more PyImath
Browse files Browse the repository at this point in the history
  • Loading branch information
Simran-B committed Mar 10, 2023
1 parent cf41a4a commit dd37e40
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 2 deletions.
3 changes: 2 additions & 1 deletion docker/ci-olive/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,8 @@ COPY scripts/build_olive.sh /tmp/

# HACK: The ASWF Imath is compiled with Python support that we ignore to avoid an error:
# set_property could not find TARGET Imath::PyImath_Python3_9.
COPY scripts/DisableImathPythonRelease.patch /tmp/
COPY scripts/DisableImathPython.patch scripts/DisableImathPythonRelease.patch /tmp/
RUN patch -u /usr/local/lib64/cmake/Imath/ImathTargets.cmake /tmp/DisableImathPython.patch
RUN patch -u /usr/local/lib64/cmake/Imath/ImathTargets-release.cmake /tmp/DisableImathPythonRelease.patch

RUN curl --location "https://github.com/probonopd/linuxdeployqt/releases/download/7/linuxdeployqt-7-x86_64.AppImage" \
Expand Down
35 changes: 35 additions & 0 deletions docker/scripts/DisableImathPython.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
--- ImathTargets.cmake 2022-05-25 22:12:51.000000000 +0000
+++ ImathTargets.cmake 2023-03-10 11:53:26.509209000 +0000
@@ -16,7 +16,7 @@
set(_targetsDefined)
set(_targetsNotDefined)
set(_expectedTargets)
-foreach(_expectedTarget Imath::ImathConfig Imath::Imath Imath::PyImathConfig Imath::PyImath_Python3_9)
+foreach(_expectedTarget Imath::ImathConfig Imath::Imath) # Imath::PyImathConfig Imath::PyImath_Python3_9
list(APPEND _expectedTargets ${_expectedTarget})
if(NOT TARGET ${_expectedTarget})
list(APPEND _targetsNotDefined ${_expectedTarget})
@@ -67,16 +67,16 @@
)

# Create imported target Imath::PyImathConfig
-add_library(Imath::PyImathConfig INTERFACE IMPORTED)
+#add_library(Imath::PyImathConfig INTERFACE IMPORTED)

# Create imported target Imath::PyImath_Python3_9
-add_library(Imath::PyImath_Python3_9 SHARED IMPORTED)
+#add_library(Imath::PyImath_Python3_9 SHARED IMPORTED)

-set_target_properties(Imath::PyImath_Python3_9 PROPERTIES
- INTERFACE_COMPILE_FEATURES "cxx_std_14"
- INTERFACE_INCLUDE_DIRECTORIES "/usr/local/include"
- INTERFACE_LINK_LIBRARIES "Imath::Imath"
-)
+#set_target_properties(Imath::PyImath_Python3_9 PROPERTIES
+# INTERFACE_COMPILE_FEATURES "cxx_std_14"
+# INTERFACE_INCLUDE_DIRECTORIES "/usr/local/include"
+# INTERFACE_LINK_LIBRARIES "Imath::Imath"
+#)

if(CMAKE_VERSION VERSION_LESS 3.0.0)
message(FATAL_ERROR "This file relies on consumers using CMake 3.0.0 or greater.")
2 changes: 1 addition & 1 deletion docker/scripts/DisableImathPythonRelease.patch
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
--- ImathTargets-release.cmake 2022-05-25 22:12:51.000000000 +0000
+++ rel.cmake 2022-12-10 21:25:53.362472000 +0000
+++ ImathTargets-release.cmake 2022-12-10 21:25:53.362472000 +0000
@@ -15,16 +15,17 @@
list(APPEND _IMPORT_CHECK_TARGETS Imath::Imath )
list(APPEND _IMPORT_CHECK_FILES_FOR_Imath::Imath "${_IMPORT_PREFIX}/lib64/libImath-3_1.so.29.4.0" )
Expand Down

0 comments on commit dd37e40

Please sign in to comment.