Bug 361805 - cmake project manager should call cmake without any arguments on imported pre-existing build directories (and maybe not auto-call at all)
Summary: cmake project manager should call cmake without any arguments on imported pre...
Status: RESOLVED WORKSFORME
Alias: None
Product: kdevelop
Classification: Applications
Component: Build tools: CMake (show other bugs)
Version: git master
Platform: Compiled Sources All
: NOR normal
Target Milestone: ---
Assignee: kdevelop-bugs-null
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-04-15 10:31 UTC by RJVB
Modified: 2022-11-25 05:22 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description RJVB 2016-04-15 10:31:42 UTC
The CMake project manager can import pre-existing/configured build directories. It will then disable the fields of the wizard that would otherwise allow to specific the install prefix, build type and other, additional cmake arguments.

That is fine, but at least the build type remains set and is given to cmake if that command is executed automatically. That is not necessary in the best case and should not happen in the worst case (when the build is under control of an external configure/build system and the IDE is only used for navigating and editing the source).

It should also be possible to select an environment profile in the importer wizard.

Ensuring that the external configure system generates and maintains a compile_commands.json file will limit automatic invocation of cmake, but apparently not eliminated it completely. There should probably be a control for disabling that feature so that the user can decide is s/he prefers to work with potentially out-of-date project information in the IDE or have an IDE with up-to-date information on a potentially misconfigured project. There could be a visual indication when the project information is supposedly out of date, though.


Reproducible: Always

Steps to Reproduce:
1. prepare a cmake-based project with a pre-configured build directory
2. Import a new project in KDevelop; select the project's CMakeLists.txt file
3. Point the importer wizard to the pre-configured build directory without touching any of the other fields


Actual Results:  
Under certain conditions cmake will be called with at least KDevelop's default CMAKE_BUILD_TYPE passed as an argument

Expected Results:  
If cmake is called at all it in this kind of scenario, should be called without arguments, and with the appropriate environment (if that is not the current environment).
Comment 1 Anton Anikin 2016-10-07 02:36:19 UTC
Hi.

Today I push this patch: 
https://quickgit.kde.org/?p=kdevelop.git&a=commit&h=81f8d15884578c7ba0cb2dbcb330b828b75dcaa1

It seems that it fixes some of your remarks, test it please.
Comment 2 RJVB 2016-10-07 11:40:29 UTC
Will do, but probably not before next week.
Comment 3 Justin Zobel 2022-10-26 03:07:09 UTC
Thank you for reporting this bug in KDE software. As it has been a while since this issue was reported, can we please ask you to see if you can reproduce the issue with a recent software version?

If you can reproduce the issue, please change the status to "REPORTED" when replying. Thank you!
Comment 4 Bug Janitor Service 2022-11-10 05:12:01 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 5 Bug Janitor Service 2022-11-25 05:22:17 UTC
This bug has been in NEEDSINFO status with no change for at least
30 days. The bug is now closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!