vcpkg/docs/maintainers/internal/vcpkg_internal_get_cmake_vars.md
Jack·Boos·Yu 2b20b27b0d
[docs] Fix the automatically generated document URL (#16611)
* [document] Fix the automatically generated document URL

* [docs] Format all documents
2021-03-10 11:56:07 -06:00

1.0 KiB

vcpkg_internal_get_cmake_vars

The latest version of this document lives in the vcpkg repo.

Only for internal use in vcpkg helpers. Behavior and arguments will change without notice. Runs a cmake configure with a dummy project to extract certain cmake variables

Usage

vcpkg_internal_get_cmake_vars(
    [OUTPUT_FILE <output_file_with_vars>]
    [OPTIONS <-DUSE_THIS_IN_ALL_BUILDS=1>...]
)

Parameters

OPTIONS

Additional options to pass to the test configure call

OUTPUT_FILE

Variable to return the path to the generated cmake file with the detected CMAKE_ variables set as VCKPG_DETECTED_

Notes

If possible avoid usage in portfiles.

Examples

Source

scripts/cmake/vcpkg_internal_get_cmake_vars.cmake