mirror of
https://github.com/threeal/cmake-action.git
synced 2026-02-02 03:50:55 +00:00
feat: add options input
This commit is contained in:
@@ -26,6 +26,9 @@ inputs:
|
||||
cxx-flags:
|
||||
description: Additional flags to pass when compiling C++ language files
|
||||
required: false
|
||||
options:
|
||||
description: Additional options to pass during the CMake configuration
|
||||
required: false
|
||||
args:
|
||||
description: Additional arguments to pass during the CMake configuration
|
||||
required: false
|
||||
@@ -78,6 +81,9 @@ runs:
|
||||
if [ -n '${{ inputs.cxx-flags }}' ]; then
|
||||
ARGS="$ARGS -D CMAKE_CXX_FLAGS='${{ inputs.cxx-flags }}'"
|
||||
fi
|
||||
for OPT in ${{ inputs.options }}; do
|
||||
ARGS="$ARGS -D $OPT"
|
||||
done
|
||||
if [ -n '${{ inputs.args }}' ]; then
|
||||
ARGS="$ARGS ${{ inputs.args }}"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user