Fix CMake install path not taking environmental path
What is the bug
CMake install path needs to be defined explicitly and thus hard to cooperate with upperlayer repositories. Also see libfortran-support!103 (merged)
How do you fix it
Use $<INSTALL_PREFIX>
instead of ${CMAKE_INSTALL_PREFIX}
How urgent is the bugfix
-
I need it as soon as possible -
I can wait for a couple of days -
None of my current codes is directly affected
Mandatory steps before review
-
Gitlab CI passes (Hint: use make format
for linting) -
Bugfix is covered by additional unit tests -
Mark the merge request as ready by removing Draft:
Mandatory steps before merge
-
Reviewed by a maintainer -
Incorporate review suggestions -
Remember to edit the commit message and select the proper changelog category (feature/bugfix/other) -
Prior to merging, please remove any boilerplate from the MR description, retaining only the What is the bug and How do you fix it section to maintain
You are not supposed to merge this request by yourself, the maintainers of libiconmath take care of this action!
Merge request reports
Activity
added bug ready for review labels
requested review from @k202170
assigned to @b382190
- Resolved by Pradipta Samanta
I still have doubts regarding the necessity of this change. I was trying to implement the exact change you did here myself this morning. Before that, I was checking how it worked in
fortran-support
. I found it surprising that the change made infortran-support
did not change anything infortran-support-target.cmake
as Sergey suggested it would. As I found, it still has:set_target_properties(fortran-support::fortran-support PROPERTIES INTERFACE_INCLUDE_DIRECTORIES "\$<\$<COMPILE_LANGUAGE:Fortran>:/path/to/libfortran-support/include>" )
Could you check it yourself? Please also see if there is any change in the file
src/cmake_install.cmake
. For me, there is none, and it usesCMAKE_INSTALL_PREFIX
to install the library.
mentioned in commit 3c2365d9