Skip to content

Commit

Permalink
[vcpkg_configure_cmake] Pass CMAKE_DISABLE_SOURCE_CHANGES to all port…
Browse files Browse the repository at this point in the history
…s by default (microsoft#12846)

* [vcpkg] Pass CMAKE_DISABLE_SOURCE_CHANGES to all ports by default

* [docs] Regenerate

Co-authored-by: Robert Schumacher <[email protected]>
Co-authored-by: Billy Robert O'Neal III <[email protected]>
  • Loading branch information
3 people authored Sep 1, 2020
1 parent 2045a0e commit cdd4a98
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions docs/maintainers/vcpkg_configure_cmake.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ This should be specified unless the port is known to not work under Ninja.
Disables running the CMake configure step in parallel.
This is needed for libraries which write back into their source directory during configure.

This also disables CMAKE_DISABLE_SOURCE_CHANGES.

### NO_CHARSET_FLAG
Disables passing `utf-8` as the default character set to `CMAKE_C_FLAGS` and `CMAKE_CXX_FLAGS`.

Expand Down
3 changes: 3 additions & 0 deletions scripts/cmake/vcpkg_configure_cmake.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@
## Disables running the CMake configure step in parallel.
## This is needed for libraries which write back into their source directory during configure.
##
## This also disables CMAKE_DISABLE_SOURCE_CHANGES.
##
## ### NO_CHARSET_FLAG
## Disables passing `utf-8` as the default character set to `CMAKE_C_FLAGS` and `CMAKE_CXX_FLAGS`.
##
Expand Down Expand Up @@ -266,6 +268,7 @@ function(vcpkg_configure_cmake)
-DCMAKE_INSTALL_PREFIX=${CURRENT_PACKAGES_DIR}/debug)

if(NINJA_HOST AND CMAKE_HOST_WIN32 AND NOT _csc_DISABLE_PARALLEL_CONFIGURE)
list(APPEND _csc_OPTIONS "-DCMAKE_DISABLE_SOURCE_CHANGES=ON")

vcpkg_find_acquire_program(NINJA)
get_filename_component(NINJA_PATH ${NINJA} DIRECTORY)
Expand Down

0 comments on commit cdd4a98

Please sign in to comment.