diff options
author | bartus | 2020-07-30 09:13:49 +0200 |
---|---|---|
committer | bartus | 2020-07-30 09:13:49 +0200 |
commit | a4e00af0ccdc784dd6dd923664ae3906da414c44 (patch) | |
tree | abb2a81646d74da0751ced53d21bb79cf4740bf2 | |
parent | 941e7c7da37ed5cb3a10a9c8eb8fbd6e3ee87cc4 (diff) | |
download | aur-a4e00af0ccdc784dd6dd923664ae3906da414c44.tar.gz |
Pop version to 20.05 (for blender{,-develop)-git)
-rw-r--r-- | .SRCINFO | 14 | ||||
-rw-r--r-- | PKGBUILD | 17 | ||||
-rw-r--r-- | blender.patch | 109 | ||||
-rw-r--r-- | boost_python2.patch | 74 |
4 files changed, 96 insertions, 118 deletions
@@ -1,22 +1,26 @@ pkgbase = usd pkgdesc = 3D VFX pipeline interchange file format. - pkgver = 19.11 - pkgrel = 2 + pkgver = 20.05 + pkgrel = 1 url = https://www.openusd.org arch = x86_64 license = Apache - makedepends = python2 + makedepends = python2-jinja + makedepends = python2-pyside-tools makedepends = boost makedepends = cmake makedepends = git makedepends = intel-tbb makedepends = ninja + depends = python2 + depends = python2-opengl + depends = python2-pyside depends = boost-libs depends = glew depends = openexr depends = opensubdiv - provides = usd=19.11 - source = git+https://github.com/PixarAnimationStudios/USD.git#tag=v19.11 + provides = usd=20.05 + source = git+https://github.com/PixarAnimationStudios/USD.git#tag=v20.05 source = boost_python2.patch source = blender.patch sha256sums = SKIP @@ -5,7 +5,7 @@ [[ -v TRAVIS ]] && DISABLE_PYTHON=1 # Configuration. -_ver="v19.11" #switch to last blender supported version, latest is "v20.02" +_ver="v20.05" #switch to last blender supported version, latest is "v20.08" _fragment="#tag=$_ver" if ((DISABLE_PYTHON)); then _CMAKE_FLAGS+=( "-DPXR_ENABLE_PYTHON_SUPPORT:BOOL=OFF" ) @@ -14,12 +14,11 @@ else _CMAKE_FLAGS+=( -DPXR_PYTHON_SHEBANG:STRING="/usr/bin/python2" ) eval "depends+=( python2{,-opengl,-pyside} )" eval "makedepends+=( python2-{jinja,pyside-tools} )" -: fi pkgname=usd pkgver=${_ver#v} -pkgrel=2 +pkgrel=1 pkgdesc="3D VFX pipeline interchange file format." arch=('x86_64') url="https://www.openusd.org" @@ -31,8 +30,8 @@ source=("git+https://github.com/PixarAnimationStudios/USD.git${_fragment}" "boost_python2.patch" "blender.patch") sha256sums=('SKIP' - 'dec16bd0270c9d682f34c555e38812ea010bee88907a02d6ce60f3f319b21425' - 'a4b92e59eb6330109f65d1b168ad0c4b1292c5317f579dcbf0594df22ffbc587') + '2f595ce72b9fb33e6da7db97b02be11fe6262e31b83b0e59232ee8713afed97e' + '95a4934ae8154e1650a024b09ed3237ba7d9411ada089a4b6337cbba9312705a') prepare() { git -C USD apply -v "${srcdir}"/{boost_python2,blender}.patch @@ -47,10 +46,14 @@ build() { -DCMAKE_INSTALL_PREFIX:PATH=/usr -DPXR_BUILD_TESTS:BOOL=OFF -DPXR_BUILD_MONOLITHIC:BOOL=ON # Required by blender-2.83 - ) + -DBoost_NO_BOOST_CMAKE=ON # Fix boost overwriting boost_python27 with boost_python + -DPXR_SET_INTERNAL_NAMESPACE=usdBlender + -DBUILD_SHARED_LIBS=ON + -DCMAKE_DEBUG_POSTFIX=_d + ) cmake -S USD -B build -G Ninja "${_CMAKE_FLAGS[@]}" # shellcheck disable=SC2046 - ninja -C build $([ -v MAKEFLAGS ] || echo -j1) + ninja -C build ${MAKEFLAGS:--j1} } #check() { diff --git a/blender.patch b/blender.patch index 6302f13796b8..fe767829a70a 100644 --- a/blender.patch +++ b/blender.patch @@ -1,14 +1,3 @@ -diff -x .git -ur usd.orig/cmake/defaults/Options.cmake external_usd/cmake/defaults/Options.cmake ---- usd.orig/cmake/defaults/Options.cmake 2019-10-24 22:39:53.000000000 +0200 -+++ external_usd/cmake/defaults/Options.cmake 2019-11-28 13:00:33.197957712 +0100 -@@ -25,6 +25,7 @@ - option(PXR_VALIDATE_GENERATED_CODE "Validate script generated code" OFF) - option(PXR_HEADLESS_TEST_MODE "Disallow GUI based tests, useful for running under headless CI systems." OFF) - option(PXR_BUILD_TESTS "Build tests" ON) -+option(PXR_BUILD_USD_TOOLS "Build commandline tools" ON) - option(PXR_BUILD_IMAGING "Build imaging components" ON) - option(PXR_BUILD_EMBREE_PLUGIN "Build embree imaging plugin" OFF) - option(PXR_BUILD_OPENIMAGEIO_PLUGIN "Build OpenImageIO plugin" OFF) diff -x .git -ur usd.orig/cmake/defaults/Packages.cmake external_usd/cmake/defaults/Packages.cmake --- usd.orig/cmake/defaults/Packages.cmake 2019-10-24 22:39:53.000000000 +0200 +++ external_usd/cmake/defaults/Packages.cmake 2019-11-28 13:00:33.185957483 +0100 @@ -21,11 +10,11 @@ diff -x .git -ur usd.orig/cmake/defaults/Packages.cmake external_usd/cmake/defau add_definitions(${TBB_DEFINITIONS}) # --math -diff -x .git -ur usd.orig/pxr/base/lib/plug/initConfig.cpp external_usd/pxr/base/lib/plug/initConfig.cpp ---- usd.orig/pxr/base/lib/plug/initConfig.cpp 2019-10-24 22:39:53.000000000 +0200 -+++ external_usd/pxr/base/lib/plug/initConfig.cpp 2019-12-11 11:00:37.643323127 +0100 -@@ -69,8 +69,38 @@ - +diff -x .git -ur usd.orig/pxr/base/plug/initConfig.cpp external_usd/pxr/base/plug/initConfig.cpp +--- usd.orig/pxr/base/plug/initConfig.cpp.orig 2020-06-12 17:20:07.478199779 +0200 ++++ external_usd/pxr/base/plug/initConfig.cpp 2020-06-12 17:25:28.648588552 +0200 +@@ -69,10 +69,40 @@ + ARCH_CONSTRUCTOR(Plug_InitConfig, 2, void) { + /* The contents of this constructor have been moved to usd_initialise_plugin_path(...) */ @@ -50,7 +39,9 @@ diff -x .git -ur usd.orig/pxr/base/lib/plug/initConfig.cpp external_usd/pxr/base +usd_initialise_plugin_path(const char *datafiles_usd_path) +{ std::vector<std::string> result; - + + std::vector<std::string> debugMessages; + + // Add Blender-specific paths. They MUST end in a slash, or symlinks will not be treated as directory. + if (datafiles_usd_path != NULL && datafiles_usd_path[0] != '\0') { + std::string datafiles_usd_path_str(datafiles_usd_path); @@ -60,14 +51,14 @@ diff -x .git -ur usd.orig/pxr/base/lib/plug/initConfig.cpp external_usd/pxr/base + result.push_back(datafiles_usd_path_str); + } + - // Determine the absolute path to the Plug shared library. - // Any relative paths specified in the plugin search path will be - // anchored to this directory, to allow for relocatability. -@@ -94,9 +124,24 @@ - _AppendPathList(&result, installLocation, sharedLibPath); + // Determine the absolute path to the Plug shared library. Any relative + // paths specified in the plugin search path will be anchored to this + // directory, to allow for relocatability. Note that this can fail when pxr +@@ -114,9 +144,24 @@ + _AppendPathList(&result, installLocation, binaryPath); #endif // PXR_INSTALL_LOCATION - -- Plug_SetPaths(result); + +- Plug_SetPaths(result, debugMessages); -} + if (!TfGetenv("PXR_PATH_DEBUG").empty()) { + printf("USD Plugin paths: (%zu in total):\n", result.size()); @@ -75,10 +66,10 @@ diff -x .git -ur usd.orig/pxr/base/lib/plug/initConfig.cpp external_usd/pxr/base + printf(" %s\n", path.c_str()); + } + } - -+ Plug_SetPaths(result); + ++ Plug_SetPaths(result, debugMessages); } - + PXR_NAMESPACE_CLOSE_SCOPE + +/* Workaround to make it possible to pass a path at runtime to USD. */ @@ -90,37 +81,6 @@ diff -x .git -ur usd.orig/pxr/base/lib/plug/initConfig.cpp external_usd/pxr/base + PXR_NS::usd_initialise_plugin_path(datafiles_usd_path); +} +} -diff -x .git -ur usd.orig/pxr/usd/CMakeLists.txt external_usd/pxr/usd/CMakeLists.txt ---- usd.orig/pxr/usd/CMakeLists.txt 2019-10-24 22:39:53.000000000 +0200 -+++ external_usd/pxr/usd/CMakeLists.txt 2019-11-28 13:00:33.197957712 +0100 -@@ -1,6 +1,5 @@ - set(DIRS - lib -- bin - plugin - ) - -@@ -8,3 +7,8 @@ - add_subdirectory(${d}) - endforeach() - -+if (PXR_BUILD_USD_TOOLS) -+ add_subdirectory(bin) -+else() -+ message(STATUS "Skipping commandline tools because PXR_BUILD_USD_TOOLS=OFF") -+endif() -diff -Naur external_usd_orig/pxr/base/lib/tf/preprocessorUtils.h external_usd/pxr/base/lib/tf/preprocessorUtils.h ---- external_usd_orig/pxr/base/lib/tf/preprocessorUtils.h 2019-10-24 14:39:53 -0600 -+++ external_usd/pxr/base/lib/tf/preprocessorUtils.h 2020-01-14 09:30:18 -0700 -@@ -189,7 +189,7 @@ - /// Exapnds to 1 if the argument is a tuple, and 0 otherwise. - /// \ingroup group_tf_Preprocessor - /// \hideinitializer --#if defined(ARCH_OS_WINDOWS) -+#if defined(ARCH_COMPILER_MSVC) - #define TF_PP_IS_TUPLE(sequence) \ - BOOST_VMD_IS_TUPLE(sequence) - #else diff -Naur external_usd_base/cmake/macros/Public.cmake external_usd/cmake/macros/Public.cmake --- external_usd_base/cmake/macros/Public.cmake 2019-10-24 14:39:53 -0600 +++ external_usd/cmake/macros/Public.cmake 2020-01-11 13:33:29 -0700 @@ -137,3 +97,36 @@ diff -Naur external_usd_base/cmake/macros/Public.cmake external_usd/cmake/macros endforeach() foreach(lib ${PXR_OBJECT_LIBS}) set(objects "${objects};\$<TARGET_OBJECTS:${lib}>") + +diff --git a/pxr/base/arch/align.h b/pxr/base/arch/align.h +index f3cabf4..ebc8a69 100644 +--- a/pxr/base/arch/align.h ++++ b/pxr/base/arch/align.h +@@ -77,7 +77,11 @@ ArchAlignMemory(void *base) + /// The size of a CPU cache line on the current processor architecture in bytes. + /// + /// \hideinitializer ++#if defined(ARCH_OS_DARWIN) && defined(ARCH_CPU_ARM) ++#define ARCH_CACHE_LINE_SIZE 128 ++#else + #define ARCH_CACHE_LINE_SIZE 64 ++#endif + + ///@} + +diff --git a/pxr/base/arch/math.h b/pxr/base/arch/math.h +index 3e66c37..64a052c 100644 +--- a/pxr/base/arch/math.h ++++ b/pxr/base/arch/math.h +@@ -42,7 +42,7 @@ PXR_NAMESPACE_OPEN_SCOPE + /// \addtogroup group_arch_Math + ///@{ + +-#if defined (ARCH_CPU_INTEL) || defined(doxygen) ++#if defined (ARCH_CPU_INTEL) || defined(ARCH_CPU_ARM) || defined(doxygen) + + /// This is the smallest value e such that 1+e^2 == 1, using floats. + /// True for all IEEE754 chipsets. + + + diff --git a/boost_python2.patch b/boost_python2.patch index 82692cf28742..4b5506353cee 100644 --- a/boost_python2.patch +++ b/boost_python2.patch @@ -1,30 +1,8 @@ -diff --git a/cmake/defaults/Packages.cmake b/cmake/defaults/Packages.cmake -index 9be215b36..031c64ab0 100644 ---- a/cmake/defaults/Packages.cmake -+++ b/cmake/defaults/Packages.cmake -@@ -43,12 +43,16 @@ if(PXR_ENABLE_PYTHON_SUPPORT) - find_package(PythonLibs 2.7 REQUIRED) - - # --Boost -+ # replace 'python' with 'python27' as boost>=1.67 require python version suffix -+ # https://cmake.org/cmake/help/v3.15/module/FindBoost.html - find_package(Boost - COMPONENTS - program_options -- python -+ python27 - REQUIRED - ) -+ # fix rest of code expecting 'Boost_PYTHON_LIBRARY' -+ set(Boost_PYTHON_LIBRARY "${Boost_PYTHON27_LIBRARY}") - - # --Jinja2 - find_package(Jinja2) diff --git a/cmake/macros/Private.cmake b/cmake/macros/Private.cmake -index 32274b3f4..d6ee46b51 100644 +index 6d97fe82e..feffd80c9 100644 --- a/cmake/macros/Private.cmake +++ b/cmake/macros/Private.cmake -@@ -120,7 +120,7 @@ function(_install_python LIBRARY_NAME) +@@ -118,7 +118,7 @@ function(_install_python LIBRARY_NAME) ${ARGN} ) @@ -33,7 +11,7 @@ index 32274b3f4..d6ee46b51 100644 _get_python_module_name(${LIBRARY_NAME} LIBRARY_INSTALLNAME) set(files_copied "") -@@ -268,7 +268,7 @@ function(_install_pyside_ui_files LIBRARY_NAME) +@@ -266,7 +266,7 @@ function(_install_pyside_ui_files LIBRARY_NAME) FOLDER "${folder}" ) @@ -42,7 +20,7 @@ index 32274b3f4..d6ee46b51 100644 _get_python_module_name(${LIBRARY_NAME} LIBRARY_INSTALLNAME) install( -@@ -947,7 +947,7 @@ function(_pxr_python_module NAME) +@@ -953,7 +953,7 @@ function(_pxr_python_module NAME) # 'from pxr import X'. Additionally, python libraries always install # into the default lib install, not into the third_party subdirectory # or similar. @@ -52,49 +30,49 @@ index 32274b3f4..d6ee46b51 100644 # Python modules need to be able to access their corresponding # wrapped library and the install lib directory. diff --git a/cmake/macros/Public.cmake b/cmake/macros/Public.cmake -index ed9ae9a31..f9c023f44 100644 +index 0e05c5f37..0342e7b7a 100644 --- a/cmake/macros/Public.cmake +++ b/cmake/macros/Public.cmake -@@ -350,7 +350,7 @@ function(pxr_setup_python) +@@ -362,7 +362,7 @@ function(pxr_setup_python) string(REPLACE ";" ", " pyModulesStr "${converted}") # Install a pxr __init__.py with an appropriate __all__ - _get_install_dir(lib/python/pxr installPrefix) -+ _get_install_dir(lib/python2.7/site-packages/pxr installPrefix) ++ _get_install_dir(lib/python2.7/pxr installPrefix) file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/generated_modules_init.py" "__all__ = [${pyModulesStr}]\n") -@@ -391,7 +391,7 @@ function (pxr_create_test_module MODULE_NAME) +@@ -409,7 +409,7 @@ function (pxr_create_test_module MODULE_NAME) RENAME __init__.py DESTINATION - tests/${tm_INSTALL_PREFIX}/lib/python/${MODULE_NAME} -+ tests/${tm_INSTALL_PREFIX}/lib/python2.7/site-packages/pxr/${MODULE_NAME} ++ tests/${tm_INSTALL_PREFIX}/lib/python2.7/${MODULE_NAME} ) endif() if (EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/${plugInfoFile}") -@@ -401,7 +401,7 @@ function (pxr_create_test_module MODULE_NAME) +@@ -419,7 +419,7 @@ function (pxr_create_test_module MODULE_NAME) RENAME plugInfo.json DESTINATION - tests/${tm_INSTALL_PREFIX}/lib/python/${MODULE_NAME} -+ tests/${tm_INSTALL_PREFIX}/lib/python2.7/site-packages/pxr/${MODULE_NAME} ++ tests/${tm_INSTALL_PREFIX}/lib/python2.7/${MODULE_NAME} ) endif() endfunction() # pxr_create_test_module -@@ -704,7 +704,7 @@ function(pxr_register_test TEST_NAME) - # Ensure that Python imports the Python files built by this build. - # On Windows convert backslash to slash and don't change semicolons - # to colons. -- set(_testPythonPath "${CMAKE_INSTALL_PREFIX}/lib/python;$ENV{PYTHONPATH}") -+ set(_testPythonPath "${CMAKE_INSTALL_PREFIX}/lib/python2.7/site-packages/pxr;$ENV{PYTHONPATH}") - if(WIN32) - string(REGEX REPLACE "\\\\" "/" _testPythonPath "${_testPythonPath}") - else() -diff --git a/pxr/base/lib/plug/testPlug.py b/pxr/base/lib/plug/testPlug.py +@@ -763,7 +763,7 @@ function(pxr_register_test TEST_NAME) + # Ensure that Python imports the Python files built by this build. + # On Windows convert backslash to slash and don't change semicolons + # to colons. +- set(_testPythonPath "${CMAKE_INSTALL_PREFIX}/lib/python;$ENV{PYTHONPATH}") ++ set(_testPythonPath "${CMAKE_INSTALL_PREFIX}/lib/python2.7;$ENV{PYTHONPATH}") + if(WIN32) + string(REGEX REPLACE "\\\\" "/" _testPythonPath "${_testPythonPath}") + else() +diff --git a/pxr/base/plug/testPlug.py b/pxr/base/plug/testPlug.py index 377e66632..776a1317a 100644 ---- a/pxr/base/lib/plug/testPlug.py -+++ b/pxr/base/lib/plug/testPlug.py +--- a/pxr/base/plug/testPlug.py ++++ b/pxr/base/plug/testPlug.py @@ -32,7 +32,7 @@ from pxr import Plug, Tf, Gf # Test plugins are installed relative to this script testRoot = os.path.join(os.path.dirname(__file__), 'PlugPlugins') @@ -104,10 +82,10 @@ index 377e66632..776a1317a 100644 testPluginsDsoSearch = testPluginsDso + '/*/Resources/' testPluginsPythonSearch = testPluginsPython + '/**/' -diff --git a/pxr/usdImaging/lib/usdviewq/CMakeLists.txt b/pxr/usdImaging/lib/usdviewq/CMakeLists.txt +diff --git a/pxr/usdImaging/usdviewq/CMakeLists.txt b/pxr/usdImaging/usdviewq/CMakeLists.txt index 66c5b2091..91c878bf3 100644 ---- a/pxr/usdImaging/lib/usdviewq/CMakeLists.txt -+++ b/pxr/usdImaging/lib/usdviewq/CMakeLists.txt +--- a/pxr/usdImaging/usdviewq/CMakeLists.txt ++++ b/pxr/usdImaging/usdviewq/CMakeLists.txt @@ -80,7 +80,7 @@ pxr_library(usdviewq install(DIRECTORY |