On 2025-12-03 8:50 AM, Cristian Le via devel wrote:
Afaict from the logs the missing `CMAKE_SIZEOF_VOID_P` was the problem that eventually led to not looking in `/usr/lib64`.


You clearly understand cmake better than I do. :)

Let me see if I follow what you're suggesting...

One failing case is that LDFLAGS is set by RPM, and the spec calls:

  %cmake -DCMAKE_CXX_FLAGS="-Wno-deprecated-declarations" -DCMAKE_MODULE_PATH=/usr/lib64/cmake/aws-c-common

One successful case calls the same command, but LDFLAGS is not set. In the successful case, cmake can determine CMAKE_SIZEOF_VOID_P because g++ works, but in the failing case it can't determine the size because g++ can't create working binaries.

In both cases, the strace data shows that cmake checks "access("/usr/aws-c-common-config.cmake")". In the failing case, just after checking that path, cmake attempts "openat(.. "/usr/lib/cmake"..) and then does not check for the file under the CMAKE_MODULE_PATH specified on the command line, which was /usr/lib64/cmake/aws-c-common. But in the successful case, cmake attempts "openat(.. "/usr/lib64/cmake"..)" and then checks the prefix specified on the command line.

Is it reasonable to conclude that cmake is normalizing the path given on the command line from /usr/lib64/cmake/aws-c-common to /usr/lib64/cmake/aws-c-common for some reason (possibly because it can't determine the sizeof void*)? I can't think of another reason why it would not check the path given as a command line argument.

I don't see where or why it might normalize the path, but again, I don't know a whole lot about cmake.

--
_______________________________________________
devel mailing list -- [email protected]
To unsubscribe send an email to [email protected]
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/[email protected]
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue

Reply via email to