Since this change, all (subsequent) CMake commands (after "%cmake")
MUST be used with the builddir argument ( "-B %{__cmake_builddir}" ).
I use in my packages "cmake -LAH" from time to time, to verify that
all CMake arguments (-D...) were passed and processed correctly, since
the processing logic behind each such argument can be quite
complicated.
Now (with the new CMake behaviour), when you call "cmake -LAH" after
you used the "%cmake", it will create a *new* cache, in the current
(that usually mean source) directory, *with incorrect values* and show
you that values instead of the correct ones (from the correct
builddir).
That was a nice quantum physic problem - since the new incorrect cache
was only created when you wanted to observe it :)
I'd like to anyone after me to not get caught by this (probably
correct, but not intuitive) behaviour.
I'd like to have the "%{__cmake_builddir}" and "%_vpath_builddir"
more
visible, than hidden behind "See the Defining source and build
directories for more information".
I was on that page several times but I haven't clicked that link since
I was looking how to *get* the patch of the builddir, instead of
defining it.
I'd submit a PR, but unfortunately no good idea how to reword the
sentence has passed my mind yet.
--
Michal Schorm
Software Engineer
Core Services - Databases Team
Red Hat
--
On Tue, Aug 4, 2020 at 9:37 AM Igor Raits
<ignatenkobrain(a)fedoraproject.org> wrote:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512
On Mon, 2020-08-03 at 22:14 -0500, Richard Shaw wrote:
> Sometimes you need to get into the build directory, in my case for
> OpenColorIO I use help2man to generate some of the man pages.
>
> I had to rely on the power of Google/Gmail to find Neal's response to
> one
> of my earlier emails to find the answer again...
https://docs.fedoraproject.org/en-US/packaging-guidelines/CMake/
%__cmake_in_source_build
Controls whether builds are done in-source (when defined) or out-
of-source (when undefined). See the Defining source and build
directories for more information.
Links to:
https://docs.fedoraproject.org/en-US/packaging-guidelines/vpath/
Feel free to submit a PR to make it more visible.
>
> %{_vpath_builddir}
>
> But that begs the question, now that we have updated %cmake, and new
> %cmake_build & %cmake_install, why is it %_vpath_builddir and not
> %_cmake_builddir?
>
> Thanks,
> Richard
> _______________________________________________
> devel mailing list -- devel(a)lists.fedoraproject.org
> To unsubscribe send an email to devel-leave(a)lists.fedoraproject.org
> 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/devel@lists.fedoraproject.org
- --
Igor Raits <ignatenkobrain(a)fedoraproject.org>
-----BEGIN PGP SIGNATURE-----
iQIzBAEBCgAdFiEEcwgJ58gsbV5f5dMcEV1auJxcHh4FAl8pECIACgkQEV1auJxc
Hh4L7Q/+M7N/MJg0od9JZ2ri3Kcd7dtzd7WzU6X6/MPtoTtnTYd5AlJQM8zZYrfj
jLFM6Hd9JdhReUodTeXYMzcuIRctjFNJv3ycI7E7pF5XvkQc6rnie6e/NwrUyCUG
b0/I4F4RUpHQfAbR/Pa05lbBfFb1pN0jCoXsc77dLWLZ//FefBYEVYTdzc44mKhx
TMOX8MPapBlu6P4XITajcI/cXMwecqgSfGPmiGwz2aqn9Ec4415khsKhjhT6CnaA
IkgLGPHZwrO1WwZXnOR+TLR6QBpGyna3xLOCE7VskH+WmsYgd6UGTm+t86BFbBDl
hThVdjK4I+uV0SU7qVq+NqtOIQRd014aKBGJpl1pmadjJhvBApJgZyC8e83OiOLm
FC1OziylaOsYvJuUIZzBG7VMyFNM4J7YR8CKD4r0CLkvkCTT0Re0jzxmXzvZzQd+
mmAsvehjIHPG0SDti8521l22dN7pvkvVO0OAfb0XDXKAdQaIQnosZyEi2G3Q4w1j
kRNLyKsIvLdHaXMqqQ/6T/O5zkaSdM7vdD54HebdzcR3iVqy3TyaI8TmMsSlA0jz
DfSd5/+W/dIen6lBOAwVO6R935Y9LCt5IdD5Szbs75wAJNOyRLnwHj2I8beNHxVi
iaUNm4KdaKxupzqwiQ9EPpClssNdkgEi2HQi/q3B+PXSu57RrOI=
=ZYgX
-----END PGP SIGNATURE-----
_______________________________________________
devel mailing list -- devel(a)lists.fedoraproject.org
To unsubscribe send an email to devel-leave(a)lists.fedoraproject.org
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/devel@lists.fedoraproject.org