Skip to content

Commit

Permalink
[OpenColorIO] Fix OpenColorIO v2.0.1 can't be find_package (#19725)
Browse files Browse the repository at this point in the history
* fix that opencolorio v2.0.1 can't be `find_package`, reference the master branch of opencolorio to generate `OpenColorIOTargets`

* run `vcpkg x-add-version --all`

* fix the `OpenColorIO` for linux

* vcpkg x-add-version --all

* patch for `OpenColorIOConfig.cmake` by AcademySoftwareFoundation/OpenColorIO#1397

* vcpkg x-add-version --all
  • Loading branch information
jixingcn authored Aug 26, 2021
1 parent 383060f commit 17818aa
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 2 deletions.
13 changes: 12 additions & 1 deletion ports/opencolorio/portfile.cmake
Original file line number Diff line number Diff line change
@@ -1,13 +1,20 @@

vcpkg_download_distfile(config_patch_path
URLS https://patch-diff.githubusercontent.com/raw/AcademySoftwareFoundation/OpenColorIO/pull/1397.diff
FILENAME AcademySoftwareFoundation-OpenColorIO-b8e18214b.diff
SHA512 34a1afb79521e43138b8a695817a9eaf6c0de8cc1d85b4640967d0ad531287a4beb41660d461067cb67103fb3ee90e11bc50e1426a0d1ae6050f3ca434dd2f3d
)

vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO AcademySoftwareFoundation/OpenColorIO
REF 0645fdd6b5279ab94851af0c56919ff9800e0c38 # v2.0.1
SHA512 51568e21eaf863747f67fbcffa7f42ba32f5892e8295dac6c9deb0f6205f57c231ea34ce028d84915e4be2f2773e362b74eaf057c2e4cf3ad4b60bf13a0b73db
HEAD_REF master
PATCHES
${config_patch_path}
fix-pystring-name.patch
use-find-openxer.patch
use-find-openexr.patch
)

vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
Expand All @@ -31,12 +38,16 @@ vcpkg_cmake_configure(

vcpkg_cmake_install()

vcpkg_fixup_cmake_targets(CONFIG_PATH "lib/cmake/OpenColorIO")

vcpkg_copy_pdbs()

# Clean redundant files
file(REMOVE_RECURSE
${CURRENT_PACKAGES_DIR}/debug/include
${CURRENT_PACKAGES_DIR}/debug/share
${CURRENT_PACKAGES_DIR}/debug/OpenColorIOConfig.cmake
${CURRENT_PACKAGES_DIR}/OpenColorIOConfig.cmake
)
if (OCIO_BUILD_APPS)
vcpkg_copy_tools(
Expand Down
File renamed without changes.
1 change: 1 addition & 0 deletions ports/opencolorio/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"name": "opencolorio",
"version-semver": "2.0.1",
"port-version": 1,
"description": "OpenColorIO (OCIO) is a complete color management solution geared towards motion picture production with an emphasis on visual effects and computer animation. OCIO provides a straightforward and consistent user experience across all supporting applications while allowing for sophisticated back-end configuration options suitable for high-end production usage. OCIO is compatible with the Academy Color Encoding Specification (ACES) and is LUT-format agnostic, supporting many popular formats.",
"homepage": "https://opencolorio.org/",
"dependencies": [
Expand Down
2 changes: 1 addition & 1 deletion versions/baseline.json
Original file line number Diff line number Diff line change
Expand Up @@ -4614,7 +4614,7 @@
},
"opencolorio": {
"baseline": "2.0.1",
"port-version": 0
"port-version": 1
},
"opencolorio-tools": {
"baseline": "1.1.1",
Expand Down
5 changes: 5 additions & 0 deletions versions/o-/opencolorio.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "1cb605cb4249c89ebab09079982d8f2b4b249716",
"version-semver": "2.0.1",
"port-version": 1
},
{
"git-tree": "3f0f60f376d80012eb0c3bd17ce51e3788070fe4",
"version-semver": "2.0.1",
Expand Down

0 comments on commit 17818aa

Please sign in to comment.