diff options
author | Ray Molenkamp <github@lazydodo.com> | 2020-11-30 00:01:33 +0300 |
---|---|---|
committer | Ray Molenkamp <github@lazydodo.com> | 2020-11-30 00:01:33 +0300 |
commit | dca9aa0053f7d711c1b42a4f2042827a1e286bea (patch) | |
tree | 89ff74b5ec88860a51bc94dfa319dfb32ac3e860 /build_files/build_environment | |
parent | 176324aa5cfcf0703dfae296028bc3aef1ff5f14 (diff) |
Deps: PugiXML 1.10
This separates out PugiXML that was previously
bundled by OIIO.
As this linux/mac libs are not available
this commit only contains the builder and windows
changes, and the option to enable pugixml is
guarded by a platform if, this can be removed
once all platforms have committed the svn libs.
For details see D8628
Diffstat (limited to 'build_files/build_environment')
-rw-r--r-- | build_files/build_environment/CMakeLists.txt | 6 | ||||
-rw-r--r-- | build_files/build_environment/cmake/harvest.cmake | 2 | ||||
-rw-r--r-- | build_files/build_environment/cmake/openimageio.cmake | 4 | ||||
-rw-r--r-- | build_files/build_environment/cmake/osl.cmake | 18 | ||||
-rw-r--r-- | build_files/build_environment/cmake/pugixml.cmake | 4 |
5 files changed, 12 insertions, 22 deletions
diff --git a/build_files/build_environment/CMakeLists.txt b/build_files/build_environment/CMakeLists.txt index 0bc85f20c16..dfbb0e824a0 100644 --- a/build_files/build_environment/CMakeLists.txt +++ b/build_files/build_environment/CMakeLists.txt @@ -94,11 +94,7 @@ include(cmake/usd.cmake) include(cmake/potrace.cmake) # Boost needs to be included after python.cmake due to the PYTHON_BINARY variable being needed. include(cmake/boost.cmake) -if(UNIX) - # Rely on PugiXML compiled with OpenImageIO -else() - include(cmake/pugixml.cmake) -endif() +include(cmake/pugixml.cmake) if((NOT APPLE) OR ("${CMAKE_OSX_ARCHITECTURES}" STREQUAL "x86_64")) include(cmake/ispc.cmake) include(cmake/openimagedenoise.cmake) diff --git a/build_files/build_environment/cmake/harvest.cmake b/build_files/build_environment/cmake/harvest.cmake index 1c5354aeb42..0f9b67a3d44 100644 --- a/build_files/build_environment/cmake/harvest.cmake +++ b/build_files/build_environment/cmake/harvest.cmake @@ -156,6 +156,8 @@ harvest(osl/lib osl/lib "*.a") harvest(osl/shaders osl/shaders "*.h") harvest(png/include png/include "*.h") harvest(png/lib png/lib "*.a") +harvest(pugixml/include pugixml/include "*.hpp") +harvest(pugixml/lib pugixml/lib "*.a") harvest(python/bin python/bin "python${PYTHON_SHORT_VERSION}m") harvest(python/include python/include "*h") harvest(python/lib python/lib "*") diff --git a/build_files/build_environment/cmake/openimageio.cmake b/build_files/build_environment/cmake/openimageio.cmake index 4254d923de1..50fd67eca8e 100644 --- a/build_files/build_environment/cmake/openimageio.cmake +++ b/build_files/build_environment/cmake/openimageio.cmake @@ -112,6 +112,9 @@ set(OPENIMAGEIO_EXTRA_ARGS -DOPENEXR_IEX_LIBRARY=${LIBDIR}/openexr/lib/${LIBPREFIX}Iex${OPENEXR_VERSION_POSTFIX}${LIBEXT} -DOPENEXR_ILMIMF_LIBRARY=${LIBDIR}/openexr/lib/${LIBPREFIX}IlmImf${OPENEXR_VERSION_POSTFIX}${LIBEXT} -DSTOP_ON_WARNING=OFF + -DUSE_EXTERNAL_PUGIXML=ON + -DPUGIXML_LIBRARY=${LIBDIR}/pugixml/lib/${LIBPREFIX}pugixml${LIBEXT} + -DPUGIXML_INCLUDE_DIR=${LIBDIR}/pugixml/include/ ${WEBP_FLAGS} ${OIIO_SIMD_FLAGS} ) @@ -134,6 +137,7 @@ add_dependencies( external_jpeg external_boost external_tiff + external_pugixml external_openjpeg${OPENJPEG_POSTFIX} ${WEBP_DEP} ) diff --git a/build_files/build_environment/cmake/osl.cmake b/build_files/build_environment/cmake/osl.cmake index db70b2937b8..118657461fe 100644 --- a/build_files/build_environment/cmake/osl.cmake +++ b/build_files/build_environment/cmake/osl.cmake @@ -78,14 +78,10 @@ set(OSL_EXTRA_ARGS -DINSTALL_DOCS=OFF ${OSL_SIMD_FLAGS} -DPARTIO_LIBRARIES= + -DPUGIXML_HOME=${LIBDIR}/pugixml ) -if(WIN32) - set(OSL_EXTRA_ARGS - ${OSL_EXTRA_ARGS} - -DPUGIXML_HOME=${LIBDIR}/pugixml - ) -elseif(APPLE) +if(APPLE) # Make symbol hiding consistent with OIIO which defaults to OFF, # avoids linker warnings on macOS set(OSL_EXTRA_ARGS @@ -114,17 +110,9 @@ add_dependencies( external_zlib external_flexbison external_openimageio + external_pugixml ) -if(UNIX) - # Rely on PugiXML compiled with OpenImageIO -else() - add_dependencies( - external_osl - external_pugixml - ) -endif() - if(WIN32) if(BUILD_MODE STREQUAL Release) ExternalProject_Add_Step(external_osl after_install diff --git a/build_files/build_environment/cmake/pugixml.cmake b/build_files/build_environment/cmake/pugixml.cmake index 4e0bd0eafcf..1f93723e936 100644 --- a/build_files/build_environment/cmake/pugixml.cmake +++ b/build_files/build_environment/cmake/pugixml.cmake @@ -30,13 +30,13 @@ ExternalProject_Add(external_pugixml if(WIN32) if(BUILD_MODE STREQUAL Release) ExternalProject_Add_Step(external_pugixml after_install - COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/pugixml/lib/pugixml.lib ${HARVEST_TARGET}/osl/lib/pugixml.lib + COMMAND ${CMAKE_COMMAND} -E copy_directory ${LIBDIR}/pugixml ${HARVEST_TARGET}/pugixml DEPENDEES install ) endif() if(BUILD_MODE STREQUAL Debug) ExternalProject_Add_Step(external_pugixml after_install - COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/pugixml/lib/pugixml.lib ${HARVEST_TARGET}/osl/lib/pugixml_d.lib + COMMAND ${CMAKE_COMMAND} -E copy ${LIBDIR}/pugixml/lib/pugixml.lib ${HARVEST_TARGET}/pugixml/lib/pugixml_d.lib DEPENDEES install ) endif() |