# Development

**URL:** https://discourse.cmake.org/c/development/9.md?page=20

[Latest](https://discourse.cmake.org/latest.md) · [Categories](https://discourse.cmake.org/categories.md) · [Tags](https://discourse.cmake.org/tags.md)

**Page:** 21

---

## [Visual Studio Android support with recent NDK](https://discourse.cmake.org/t/visual-studio-android-support-with-recent-ndk/2441)

<div class="topic-metadata">

**Author:** [@craig.scott](https://discourse.cmake.org/u/craig.scott)\
**Replies:** 1\
**Last updated:** [January 4, 2021, 6:09pm UTC](https://discourse.cmake.org/t/visual-studio-android-support-with-recent-ndk/2441 "2021-01-04T18:09:10Z")

</div>

Has anyone attempted to use the new Visual Studio NDK support with a NDK more recent than what comes with Visual Studio (which is ancient r16)? I’ve been trying to get this working for a while now and with the changes ma…

---

## [Please put CMakeCache.txt into invalid state when compiler not found](https://discourse.cmake.org/t/please-put-cmakecache-txt-into-invalid-state-when-compiler-not-found/1564)

<div class="topic-metadata">

**Author:** [@Juan\_Sanchez](https://discourse.cmake.org/u/Juan_Sanchez)\
**Replies:** 1\
**Last updated:** [December 30, 2020, 8:05pm UTC](https://discourse.cmake.org/t/please-put-cmakecache-txt-into-invalid-state-when-compiler-not-found/1564 "2020-12-30T20:05:10Z")

</div>

Using the CMake generator with Makefiles on macOS and Linux: If the compiler is not available and the generator fails, a CMakeCache.txt is written with empty compiler flags. When I run cmake a second time, with the com…

---

## [cmake gives current working directory cannot establish error](https://discourse.cmake.org/t/cmake-gives-current-working-directory-cannot-establish-error/2319)

<div class="topic-metadata">

**Author:** [@jalpan](https://discourse.cmake.org/u/jalpan)\
**Replies:** 8\
**Last updated:** [December 18, 2020, 10:55am UTC](https://discourse.cmake.org/t/cmake-gives-current-working-directory-cannot-establish-error/2319 "2020-12-18T10:55:58Z")

</div>

while executing cmake command it gives me the following error “Current working directory cannot be established.” I have executed cmake command from the shell script. rm -rf build && mkdir -p build && cd build && cma…

---

## [Why is mark\_as\_advanced() considered a scripting command](https://discourse.cmake.org/t/why-is-mark-as-advanced-considered-a-scripting-command/2387)

<div class="topic-metadata">

**Author:** [@craig.scott](https://discourse.cmake.org/u/craig.scott)\
**Replies:** 1\
**Last updated:** [December 17, 2020, 12:44pm UTC](https://discourse.cmake.org/t/why-is-mark-as-advanced-considered-a-scripting-command/2387 "2020-12-17T12:44:16Z")

</div>

I’m wondering why the mark\_as\_advanced() command is considered a scripting command. It’s sole purpose is for marking cache variables as advanced or not, but cache variables only make sense for projects. Does this command…

---

## [Allow to manually set dependencies for some targets](https://discourse.cmake.org/t/allow-to-manually-set-dependencies-for-some-targets/2355)

<div class="topic-metadata">

**Author:** [@james\_brown](https://discourse.cmake.org/u/james_brown)\
**Replies:** 6\
**Last updated:** [December 17, 2020, 12:21am UTC](https://discourse.cmake.org/t/allow-to-manually-set-dependencies-for-some-targets/2355 "2020-12-17T00:21:56Z")

</div>

Hi, I would like to know if CMake provide a way of fixing dependencies for a particular targets. The use-case is to build once, analyze result’s real dependencies with a custom script(linker map or dwarf+nm, gcc -M), a…

---

## [Proposal/RFC: "Since" annotations in CMake documentation](https://discourse.cmake.org/t/proposal-rfc-since-annotations-in-cmake-documentation/960)

<div class="topic-metadata">

**Author:** [@ferdnyc](https://discourse.cmake.org/u/ferdnyc)\
**Replies:** 6\
**Last updated:** [December 15, 2020, 2:06pm UTC](https://discourse.cmake.org/t/proposal-rfc-since-annotations-in-cmake-documentation/960 "2020-12-15T14:06:42Z")

</div>

(I waffled over what section to post this in, before settling on this one. apologies if I got that wrong.) If, like me, you’re involved in a project that requires build-system compatibility with a wide range of CMake ve…

---

## [Version range support write\_basic\_config\_version\_file() may be too restrictive](https://discourse.cmake.org/t/version-range-support-write-basic-config-version-file-may-be-too-restrictive/2347)

<div class="topic-metadata">

**Author:** [@craig.scott](https://discourse.cmake.org/u/craig.scott)\
**Replies:** 5\
**Last updated:** [December 12, 2020, 1:19pm UTC](https://discourse.cmake.org/t/version-range-support-write-basic-config-version-file-may-be-too-restrictive/2347 "2020-12-12T13:19:11Z")

</div>

@marc.chevrier When we added the support for version ranges in MR 5226, using any compatibility mode other than AnyNewerVersion generates an author warning when any sort of version range is given to a find\_package() call…

---

## [Feature Request: Add env\_file option to CMake Command Mode](https://discourse.cmake.org/t/feature-request-add-env-file-option-to-cmake-command-mode/2344)

<div class="topic-metadata">

**Author:** [@WhoBrokeTheBuild](https://discourse.cmake.org/u/WhoBrokeTheBuild)\
**Replies:** 5\
**Last updated:** [December 11, 2020, 2:29pm UTC](https://discourse.cmake.org/t/feature-request-add-env-file-option-to-cmake-command-mode/2344 "2020-12-11T14:29:46Z")

</div>

Hello! I propose adding a new option to cmake -E that takes a file of environment variables to set, much like cmake -E env. Example: .env THIS=THAT MY\_PATH=/path/to/thing DEBUG\_MODE=yes cmake -E env\_file .env my\_com…

---

## [execute\_proces() interaction between COMMAND\_ERROR\_IS\_FATAL and TIMEOUT](https://discourse.cmake.org/t/execute-proces-interaction-between-command-error-is-fatal-and-timeout/2303)

<div class="topic-metadata">

**Author:** [@craig.scott](https://discourse.cmake.org/u/craig.scott)\
**Replies:** 5\
**Last updated:** [December 7, 2020, 4:57pm UTC](https://discourse.cmake.org/t/execute-proces-interaction-between-command-error-is-fatal-and-timeout/2303 "2020-12-07T16:57:15Z")

</div>

CMake 3.19 added a new COMMAND\_ERROR\_IS\_FATAL option to the execute\_process() command. The goal as originally stated in the issue was to be able to replace code like this: execute\_process(COMMAND foo RESULT\_VARIABLE \_re…

---

## [Contribution to the Pelles C Module](https://discourse.cmake.org/t/contribution-to-the-pelles-c-module/2268)

<div class="topic-metadata">

**Author:** [@clin1234](https://discourse.cmake.org/u/clin1234)\
**Replies:** 2\
**Last updated:** [December 1, 2020, 5:39pm UTC](https://discourse.cmake.org/t/contribution-to-the-pelles-c-module/2268 "2020-12-01T17:39:26Z")

</div>

My name is Charlie Lin, and I intend to contribute and maintain support for the Pelles C toolchain.

---

## [Setup a custom preprocessor: using without wrapper function and dependencies](https://discourse.cmake.org/t/setup-a-custom-preprocessor-using-without-wrapper-function-and-dependencies/2272)

<div class="topic-metadata">

**Author:** [@dev-zero](https://discourse.cmake.org/u/dev-zero)\
**Replies:** 1\
**Last updated:** [December 1, 2020, 8:27am UTC](https://discourse.cmake.org/t/setup-a-custom-preprocessor-using-without-wrapper-function-and-dependencies/2272 "2020-12-01T08:27:07Z")

</div>

We are using CMake for a larger Fortran-based project in which we are also employing the Fypp preprocessor. To implement this I added a function ADD\_FYPP\_SOURCES which takes the files, defines a custom command and retur…

---

## [Status of CMake debugger](https://discourse.cmake.org/t/status-of-cmake-debugger/567)

<div class="topic-metadata">

**Author:** [@ben](https://discourse.cmake.org/u/ben)\
**Replies:** 12\
**Last updated:** [November 25, 2020, 8:16pm UTC](https://discourse.cmake.org/t/status-of-cmake-debugger/567 "2020-11-25T20:16:11Z")

</div>

I see that a 2 year old closed MR attempted to add a debugger mode to CMake but was never merged. Have there been any activity to add a debugger to CMake since then (~2 years ago)? If the approach in the closed MR still …

---

## [Automatic call of cleandead ninja tool](https://discourse.cmake.org/t/automatic-call-of-cleandead-ninja-tool/2180)

<div class="topic-metadata">

**Author:** [@trmagma](https://discourse.cmake.org/u/trmagma)\
**Replies:** 4\
**Last updated:** [November 25, 2020, 5:07pm UTC](https://discourse.cmake.org/t/automatic-call-of-cleandead-ninja-tool/2180 "2020-11-25T17:07:04Z")

</div>

Hello, we have some problems with the automatic call of the “cleandead” tool of ninja. If a target file to be removed is read-only (which might be required), ninja failed to delete the file. This results that the cmake-…

---

## [Why fixtures are forced to be tests?](https://discourse.cmake.org/t/why-fixtures-are-forced-to-be-tests/2194)

<div class="topic-metadata">

**Author:** [@james\_brown](https://discourse.cmake.org/u/james_brown)\
**Replies:** 7\
**Last updated:** [November 18, 2020, 7:30pm UTC](https://discourse.cmake.org/t/why-fixtures-are-forced-to-be-tests/2194 "2020-11-18T19:30:48Z")

</div>

Hi, I am here to understand why you made fixtures doomed to be tests. I would also like to be pointed on a solution that avoid drawbacks I get now. My usecase I need to make my tests to touch a file automatically when t…

---

## [Consider calling initProp("Fortran\_VISIBILITY\_PRESET")](https://discourse.cmake.org/t/consider-calling-initprop-fortran-visibility-preset/1771)

<div class="topic-metadata">

**Author:** [@coldfix](https://discourse.cmake.org/u/coldfix)\
**Replies:** 2\
**Last updated:** [November 15, 2020, 2:42pm UTC](https://discourse.cmake.org/t/consider-calling-initprop-fortran-visibility-preset/1771 "2020-11-15T14:42:26Z")

</div>

Hi, I noticed that the CMAKE\_Fortran\_VISIBILITY\_PRESET behaves somewhat different than the same flag for other languages in that it cannot be specified from the cmake command line: cmake . -DCMAKE\_Fortran\_VISIBILITY\_PR…

---

## [Support for embedding data in a manner equivalent to xxd](https://discourse.cmake.org/t/support-for-embedding-data-in-a-manner-equivalent-to-xxd/2121)

<div class="topic-metadata">

**Author:** [@rleigh](https://discourse.cmake.org/u/rleigh)\
**Replies:** 12\
**Last updated:** [November 14, 2020, 4:22pm UTC](https://discourse.cmake.org/t/support-for-embedding-data-in-a-manner-equivalent-to-xxd/2121 "2020-11-14T16:22:32Z")

</div>

The xxd command can convert any input file to a form which can be included into a C source file or compiled directly: % echo "Sample data" \> test % xxd -i test unsigned char test\[\] = { 0x53, 0x61, 0x6d, 0x70, 0x6c, 0…

---

## [Feature Request: Implement Levenshtein distance for tracking Cmake bugs.](https://discourse.cmake.org/t/feature-request-implement-levenshtein-distance-for-tracking-cmake-bugs/2175)

<div class="topic-metadata">

**Author:** [@Qasim](https://discourse.cmake.org/u/Qasim)\
**Replies:** 1\
**Last updated:** [November 14, 2020, 10:15am UTC](https://discourse.cmake.org/t/feature-request-implement-levenshtein-distance-for-tracking-cmake-bugs/2175 "2020-11-14T10:15:33Z")

</div>

Hey there, I’ve been using CMake a lot for my projects, and recently came across the following error messages from Cmake while trying to compile it. Now, notice where it says, “did you mean ‘update\_enter’.” This is m…

---

## [Cmake gitlab has over 3000 issues](https://discourse.cmake.org/t/cmake-gitlab-has-over-3000-issues/2166)

<div class="topic-metadata">

**Author:** [@anon45792294](https://discourse.cmake.org/u/anon45792294)\
**Replies:** 2\
**Last updated:** [November 12, 2020, 3:41pm UTC](https://discourse.cmake.org/t/cmake-gitlab-has-over-3000-issues/2166 "2020-11-12T15:41:45Z")

</div>

Currently the gitlab has over 3000 issues. I’m new to trying to contribute to big open source projects. But is something like this okay? I mean some of these issues were created +10 years ago.

---

## [Setting default install permissions globally](https://discourse.cmake.org/t/setting-default-install-permissions-globally/1598)

<div class="topic-metadata">

**Author:** [@globberwops](https://discourse.cmake.org/u/globberwops)\
**Replies:** 2\
**Last updated:** [November 11, 2020, 5:27pm UTC](https://discourse.cmake.org/t/setting-default-install-permissions-globally/1598 "2020-11-11T17:27:14Z")

</div>

I would like to be able to set global default install permissions, so I don’t have to either rewrite each and every install(...) command, or override it with a custom install(...) command in my project. There already is…

---

## [Feature Request - looping through properties](https://discourse.cmake.org/t/feature-request-looping-through-properties/1284)

<div class="topic-metadata">

**Author:** [@hex](https://discourse.cmake.org/u/hex)\
**Replies:** 6\
**Last updated:** [November 9, 2020, 9:49pm UTC](https://discourse.cmake.org/t/feature-request-looping-through-properties/1284 "2020-11-09T21:49:24Z")

</div>

it would be really useful when the foreach would not enter NOTFOUND lists. Currently with every list I receive from get\_property I need to check if the property is set. If a property is not set \<var\>-NOTFOUND is receive…

---

## [TestBigEndian: Performance](https://discourse.cmake.org/t/testbigendian-performance/1248)

<div class="topic-metadata">

**Author:** [@YMba9g8j9CJp0wLoQf5y](https://discourse.cmake.org/u/YMba9g8j9CJp0wLoQf5y)\
**Replies:** 11\
**Last updated:** [November 9, 2020, 1:24pm UTC](https://discourse.cmake.org/t/testbigendian-performance/1248 "2020-11-09T13:24:49Z")

</div>

TestBigEndian has performance problems. TestBigEndian re-does a lot of work for no good reason. If you have multiple projects checking for Endianness this can add up and eat at the configuration time. The main reason …

---

## [CPACK\_PRE\_BUILD\_SCRIPTS duplicates CPACK\_INSTALL\_SCRIPTS](https://discourse.cmake.org/t/cpack-pre-build-scripts-duplicates-cpack-install-scripts/2105)

<div class="topic-metadata">

**Author:** [@craig.scott](https://discourse.cmake.org/u/craig.scott)\
**Replies:** 2\
**Last updated:** [November 4, 2020, 11:33am UTC](https://discourse.cmake.org/t/cpack-pre-build-scripts-duplicates-cpack-install-scripts/2105 "2020-11-04T11:33:31Z")

</div>

While cleaning up the docs for the new CPACK\_PRE\_BUILD\_SCRIPTS, CPACK\_POST\_BUILD\_SCRIPTS and CPACK\_PACKAGE\_FILES variables added by !4846, I noticed that we already have CPACK\_INSTALL\_SCRIPTS. This seems to already provi…

---

## [Boost::process target doesn't exist (for thread linking)](https://discourse.cmake.org/t/boost-process-target-doesnt-exist-for-thread-linking/2113)

<div class="topic-metadata">

**Author:** [@syyyr](https://discourse.cmake.org/u/syyyr)\
**Replies:** 6\
**Last updated:** [November 4, 2020, 10:48am UTC](https://discourse.cmake.org/t/boost-process-target-doesnt-exist-for-thread-linking/2113 "2020-11-04T10:48:13Z")

</div>

Hi, I had some problems with linking Boost.Process. Linking with the Boost::boost target after using find\_package(Boost) gave me linking errors about threads. After some discussion on IRC, the problem is that Boost being…

---

## [CPACK\_INSTALL\_SCRIPTS executed without the files being present](https://discourse.cmake.org/t/cpack-install-scripts-executed-without-the-files-being-present/1822)

<div class="topic-metadata">

**Author:** [@mistaZ](https://discourse.cmake.org/u/mistaZ)\
**Replies:** 1\
**Last updated:** [November 2, 2020, 3:55am UTC](https://discourse.cmake.org/t/cpack-install-scripts-executed-without-the-files-being-present/1822 "2020-11-02T03:55:39Z")

</div>

I’m trying to make a .msi installation package using CMake, CPack, and Wix. The issue is I’m trying to sign the executables and DLLs that are going to be installed. SET( CPACK\_INSTALL\_SCRIPTS "${CMAKE\_CURRENT\_LIST\_DIR}/…

---

## [Inconsistent behavior of cmake\_path() subcommands taking a variable name instead of a string](https://discourse.cmake.org/t/inconsistent-behavior-of-cmake-path-subcommands-taking-a-variable-name-instead-of-a-string/2062)

<div class="topic-metadata">

**Author:** [@craig.scott](https://discourse.cmake.org/u/craig.scott)\
**Replies:** 3\
**Last updated:** [November 1, 2020, 11:52am UTC](https://discourse.cmake.org/t/inconsistent-behavior-of-cmake-path-subcommands-taking-a-variable-name-instead-of-a-string/2062 "2020-11-01T11:52:28Z")

</div>

@marc.chevrier First up, sorry I didn’t get a chance to look at the original merge request for this feature when it was up for review. I should have caught this earlier, but am only just now getting to take a close look …

---

## [Adding GLES Support to FindOpenGL](https://discourse.cmake.org/t/adding-gles-support-to-findopengl/2087)

<div class="topic-metadata">

**Author:** [@warisb](https://discourse.cmake.org/u/warisb)\
**Replies:** 1\
**Last updated:** [October 29, 2020, 1:48pm UTC](https://discourse.cmake.org/t/adding-gles-support-to-findopengl/2087 "2020-10-29T13:48:38Z")

</div>

Hi there, please bear with me as this is my first post. I would like to discuss this particular comment in the FindOpenGL.cmake file For EGL targets the client must rely on GLVND support on the user’s system. Linking …

---

## [Cmake configuration and generate is extremely slow for VS 2017](https://discourse.cmake.org/t/cmake-configuration-and-generate-is-extremely-slow-for-vs-2017/2036)

<div class="topic-metadata">

**Author:** [@satya\_ranjan\_Rout](https://discourse.cmake.org/u/satya_ranjan_Rout)\
**Replies:** 7\
**Last updated:** [October 29, 2020, 1:25pm UTC](https://discourse.cmake.org/t/cmake-configuration-and-generate-is-extremely-slow-for-vs-2017/2036 "2020-10-29T13:25:50Z")

</div>

We update our visual studio verion from VS 2012 to VS 2017. We are using Cmake3.18.2. It looks the configuration and generation time in cmake extremely high in VS 2017. In VS 2012 same code its taking around 15 mins, now…

---

## [support for cuDNN NVIDIA CUDA® Deep Neural Network library](https://discourse.cmake.org/t/support-for-cudnn-nvidia-cuda-deep-neural-network-library/2082)

<div class="topic-metadata">

**Author:** [@Morteza\_Kianian](https://discourse.cmake.org/u/Morteza_Kianian)\
**Replies:** 2\
**Last updated:** [October 28, 2020, 6:17pm UTC](https://discourse.cmake.org/t/support-for-cudnn-nvidia-cuda-deep-neural-network-library/2082 "2020-10-28T18:17:00Z")

</div>

Currently for adding cuDNN libraries a module created by Stefano Sinigardi called FindCUDNN.cmake is used in many projects such as Darknet. I see the FindCUDA.cmake module is replaced by FindCUDAToolkit but still there’s…

---

## [Cleaning up Check\<Lang\>SourceCompiles module docs](https://discourse.cmake.org/t/cleaning-up-check-lang-sourcecompiles-module-docs/2063)

<div class="topic-metadata">

**Author:** [@craig.scott](https://discourse.cmake.org/u/craig.scott)\
**Replies:** 2\
**Last updated:** [October 24, 2020, 11:09am UTC](https://discourse.cmake.org/t/cleaning-up-check-lang-sourcecompiles-module-docs/2063 "2020-10-24T11:09:23Z")

</div>

The CMake 3.19 release includes a new CheckSourceCompiles module which replaces the individual Check\<Lang\>SourceCompiles modules. Indeed, those modules now simply forward to the new one. The old modules still have all th…

---

## [CMakePresets.json section appears too early in the cmake(1) doc](https://discourse.cmake.org/t/cmakepresets-json-section-appears-too-early-in-the-cmake-1-doc/1998)

<div class="topic-metadata">

**Author:** [@craig.scott](https://discourse.cmake.org/u/craig.scott)\
**Replies:** 3\
**Last updated:** [October 14, 2020, 12:47pm UTC](https://discourse.cmake.org/t/cmakepresets-json-section-appears-too-early-in-the-cmake-1-doc/1998 "2020-10-14T12:47:44Z")

</div>

The CMakePresets.json feature newly added in CMake 3.19 takes up a substantial amount of space early in the page for the cmake(1) documentation. It should have its own section within that page and I would suggest it shou…

[Previous page](https://discourse.cmake.org/c/development/9.md?page=19)

[Next page](https://discourse.cmake.org/c/development/9.md?page=21)
