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

find_package(OpenColorIO) broken under cmake 3.29.1 #1964

Open
ggarra13 opened this issue Apr 10, 2024 · 3 comments
Open

find_package(OpenColorIO) broken under cmake 3.29.1 #1964

ggarra13 opened this issue Apr 10, 2024 · 3 comments
Labels
Build Issue Issues related to build or environment problems on any platform.

Comments

@ggarra13
Copy link

With the recent update of cmake to v3.29.1 (v3.29 was okay before) of GitHub Actions, OpenColorIO started failing not finding its dependencies:

CMake Warning (dev) at /opt/homebrew/Cellar/cmake/3.29.1/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:438 (message):
  The package name passed to `find_package_handle_standard_args` (EXPAT) does
  not match the name of the calling package (expat).  This can lead to
  problems in calling code that expects `find_package` result variables
  (e.g., `_FOUND`) to follow a certain pattern.
Call Stack (most recent call first):
  /opt/homebrew/Cellar/cmake/3.29.1/share/cmake/Modules/Findexpat.cmake:114 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  /opt/homebrew/Cellar/cmake/3.29.1/share/cmake/Modules/CMakeFindDependencyMacro.cmake:76 (find_package)
  build/install/lib/cmake/OpenColorIO/OpenColorIOConfig.cmake:33 (find_dependency)
  CMakeLists.txt:163 (find_package)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Found EXPAT: /Users/runner/work/tlRender/tlRender/build/install/lib/libexpat.a (found version "2.5.0")
CMake Error at CMakeLists.txt:163 (find_package):
  Found package configuration file:

    /Users/runner/work/tlRender/tlRender/build/install/lib/cmake/OpenColorIO/OpenColorIOConfig.cmake

  but it set OpenColorIO_FOUND to FALSE so package "OpenColorIO" is
  considered to be NOT FOUND.  Reason given by package:

  OpenColorIO could not be found because dependency expat could not be found.

-- Configuring incomplete, errors occurred!

On macOS it fails on expat. On Linux it fails with pystring.

@tamaskenezlego
Copy link

I've just found the same issue with building Qt on GitHub. It's failing there with cmake 3.29.1 while 3.29.2 on my machine works fine. The problem seems to be in the configure_package_config_file module, the code it generates for @PACKAGE_INIT@ is broken.

@ggarra13
Copy link
Author

I reported the bug to Kitware. That's why they released 3.29.2. Have to wait until Github Actions updates to 3.29.2.

@tamaskenezlego
Copy link

Github runners have been updated now.

@carolalynn carolalynn added the Build Issue Issues related to build or environment problems on any platform. label Apr 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Build Issue Issues related to build or environment problems on any platform.
Projects
None yet
Development

No branches or pull requests

3 participants