-- Found OpenGL: /usr/lib64/libOpenGL.so CMake Error at /usr/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:281 (message): find_package_check_version(): Cannot be used outside a 'Find Module' Call Stack (most recent call first): /usr/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:530 (find_package_check_version) ------------------------------------------------------------------- This is an unstable amd64 chroot image at a tinderbox (==build bot) name: 17.1_desktop_plasma-20201108-130033 ------------------------------------------------------------------- gcc-config -l: [1] x86_64-pc-linux-gnu-8.3.1 [2] x86_64-pc-linux-gnu-10.2.0 * clang version 11.0.0 Target: x86_64-pc-linux-gnu Thread model: posix InstalledDir: /usr/lib/llvm/11/bin /usr/lib/llvm/11 11.0.0 Available Python interpreters, in order of preference: [1] python3.7 [2] python3.9 (fallback) [3] python3.8 (fallback) [4] python2.7 (fallback) [5] pypy3 (fallback) Available Ruby profiles: [1] ruby25 (with Rubygems) [2] ruby26 (with Rubygems) [3] ruby27 (with Rubygems) * Available Rust versions: [1] rust-1.47.0 * The following VMs are available for generation-2: *) AdoptOpenJDK 8.272_p10 [openjdk-bin-8] Available Java Virtual Machines: [1] openjdk-bin-8 system-vm The Glorious Glasgow Haskell Compilation System, version 8.8.4 timestamp(s) of HEAD at this tinderbox image: /var/db/repos/gentoo Fri Nov 20 07:35:32 AM UTC 2020 emerge -qpvO media-gfx/openvdb [ebuild N ] media-gfx/openvdb-7.1.0-r1 USE="abi7-compat -abi6-compat -doc -numpy -python -static-libs -test -utils" CPU_FLAGS_X86="avx sse4_2" PYTHON_SINGLE_TARGET="python3_7 -python3_6 -python3_8 -python3_9"
Created attachment 673468 [details] emerge-info.txt
Created attachment 673471 [details] CMakeError.log
Created attachment 673474 [details] CMakeOutput.log
Created attachment 673477 [details] emerge-history.txt
Created attachment 673480 [details] environment
Created attachment 673483 [details] etc.portage.tbz2
Created attachment 673486 [details] logs.tbz2
Created attachment 673489 [details] media-gfx:openvdb-7.1.0-r1:20201120-083304.log
Created attachment 673492 [details] temp.tbz2
This is likely because of CMake 3.19. Downgrading to CMake 3.18.5 can be a temporary workaround while the CMakeFiles of openvdb are fixed.
The interesting part (for the bug summary) is probably: find_package_check_version(): Cannot be used outside a 'Find Module'
CMake identified it as an issue in their code: https://gitlab.kitware.com/cmake/cmake/-/issues/21505 They merged a fix to Modules/FindPackageHandleStandardArgs.cmake: https://gitlab.kitware.com/cmake/cmake/-/commit/14ecf9c2f6edfae4033d9311f79d79d0d07fc1cf I dropped the patch in /etc/portage/patches/dev-util/cmake-3.19.1/cmake-3.19.1-fix-FindPackageHandleStandardArgs-14ecf9c2f6edfae4033d9311f79d79d0d07fc1cf.patch, reemerged dev-util/cmake-3.19.1, emerged media-gfx/openvdb-7.0.0-r1. I confirm it fixes the issue.
Thank you for your effort in tracking down the issue with this bug. I will test this tonight and submit a PR.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=814b6b0d056d858c629720ca1a97400688d2542f commit 814b6b0d056d858c629720ca1a97400688d2542f Author: Adrian Grigo <agrigo2001@yahoo.com.au> AuthorDate: 2020-12-08 03:19:22 +0000 Commit: Andreas Sturmlechner <asturm@gentoo.org> CommitDate: 2020-12-12 17:58:23 +0000 dev-util/cmake: Backport FPHSA fix Changes to Find Package Handle Standard Args in 3.19.0 result in an error when compiling openvdb-7.1.0. This is a known problem in cmake and the fix has been merged into 3.19.2 upstream. See https://gitlab.kitware.com/cmake/cmake/-/issues/21505 To produce the bug: emerge dev-util/cmake-3.19.0 or 3.19.1 (the bug not exist in <= 3.18) emerge media-gfx/openvdb-7.1.0-r1 Compilation fails with find_package_check_version(): Cannot be used outside a 'Find Module' To fix the bug: Apply the patch provided in this bug fix to cmake, then repeat the above steps and compilation of openvdb succeeds. The patch ensures that the CMAKE_FPHSA_PACKAGE_NAME package is made available outside find_package. Thanks to Dennis Schridde for finding the upstream fix, produced by Marc Chevrier. * committer-comment: use Gentoo bug ref; git format-patch 14ecf9c2f Signed-off-by: Adrian Grigo <agrigo2001@yahoo.com.au> Closes: https://bugs.gentoo.org/755743 Package-Manager: Portage-3.0.9, Repoman-3.0.2 Closes: https://github.com/gentoo/gentoo/pull/18560 Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org> dev-util/cmake/cmake-3.19.1-r1.ebuild | 1 + ...ake-3.19.1-use-FPHSA-outside-find_package.patch | 40 ++++++++++++++++++++++ 2 files changed, 41 insertions(+)