Skip to content

Commit

Permalink
tools/win32/configure*.ps1: allow custom $CMAKE_ARGS (JSON array)
Browse files Browse the repository at this point in the history
  • Loading branch information
Al2Klimov committed Jan 21, 2025
1 parent c578341 commit 842fb79
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
6 changes: 5 additions & 1 deletion tools/win32/configure-dev.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ if (-not (Test-Path env:CMAKE_GENERATOR)) {
if (-not (Test-Path env:CMAKE_GENERATOR_PLATFORM)) {
$env:CMAKE_GENERATOR_PLATFORM = 'x64'
}
if (-not (Test-Path env:CMAKE_ARGS)) {
$env:CMAKE_ARGS = '[]'
}
if (-not (Test-Path env:OPENSSL_ROOT_DIR)) {
$env:OPENSSL_ROOT_DIR = 'c:\local\OpenSSL-Win64'
}
Expand Down Expand Up @@ -60,7 +63,8 @@ if (Test-Path CMakeCache.txt) {
-DBOOST_LIBRARYDIR="$env:BOOST_LIBRARYDIR" `
-DBOOST_INCLUDEDIR="$env:BOOST_ROOT" `
-DFLEX_EXECUTABLE="$env:FLEX_BINARY" `
-DBISON_EXECUTABLE="$env:BISON_BINARY"
-DBISON_EXECUTABLE="$env:BISON_BINARY" `
$(ConvertFrom-Json -InputObject "$env:CMAKE_ARGS")

cd "$sourcePath"

Expand Down
6 changes: 5 additions & 1 deletion tools/win32/configure.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ if (-not (Test-Path env:CMAKE_GENERATOR_PLATFORM)) {
$env:CMAKE_GENERATOR_PLATFORM = 'x64'
}
}
if (-not (Test-Path env:CMAKE_ARGS)) {
$env:CMAKE_ARGS = '[]'
}
if (-not (Test-Path env:OPENSSL_ROOT_DIR)) {
$env:OPENSSL_ROOT_DIR = "c:\local\OpenSSL_3_0_15-Win${env:BITS}"
}
Expand Down Expand Up @@ -63,7 +66,8 @@ if (Test-Path CMakeCache.txt) {
-DBOOST_LIBRARYDIR="$env:BOOST_LIBRARYDIR" `
-DBOOST_INCLUDEDIR="$env:BOOST_ROOT" `
-DFLEX_EXECUTABLE="$env:FLEX_BINARY" `
-DBISON_EXECUTABLE="$env:BISON_BINARY"
-DBISON_EXECUTABLE="$env:BISON_BINARY" `
$(ConvertFrom-Json -InputObject "$env:CMAKE_ARGS")

cd "$sourcePath"

Expand Down

0 comments on commit 842fb79

Please sign in to comment.