Skip to content

Commit d4fcaa8

Browse files
committed
Build static binaries in release mode
Improve performance and reduce binary size by building our static binaries in Release mode instead of the default unoptimized mode. This commit affects the npm package and the 'manual' installation method.
1 parent 4158540 commit d4fcaa8

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

.github/workflows/build-static.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ jobs:
2525
runs-on: ${{ matrix.toolchain.runs_on }}
2626
container: ${{ matrix.toolchain.docker_container }}
2727
env:
28-
CMAKE_BUILD_TYPE: ${{ matrix.toolchain.CMAKE_BUILD_TYPE }}
2928
CMAKE_CXX_COMPILER: ${{ matrix.toolchain.CXX }}
3029
CMAKE_CXX_FLAGS: ${{ matrix.toolchain.CFLAGS }}
3130
CMAKE_C_COMPILER: ${{ matrix.toolchain.CC }}
@@ -42,7 +41,7 @@ jobs:
4241
- name: configure
4342
run: |
4443
env | grep '^CMAKE\|^QUICK_LINT_JS' | sort
45-
cmake ${CMAKE_C_COMPILER:+-DCMAKE_C_COMPILER="${CMAKE_C_COMPILER}"} ${CMAKE_CXX_COMPILER:+-DCMAKE_CXX_COMPILER="${CMAKE_CXX_COMPILER}"} -DCMAKE_BUILD_TYPE="${CMAKE_BUILD_TYPE}" -DBUILD_TESTING=NO -DCMAKE_C_FLAGS="${CMAKE_C_FLAGS}" -DCMAKE_CXX_FLAGS="${CMAKE_CXX_FLAGS}" -DCMAKE_EXE_LINKER_FLAGS="${CMAKE_EXE_LINKER_FLAGS}" -DCMAKE_SHARED_LINKER_FLAGS="${CMAKE_SHARED_LINKER_FLAGS}" ${CMAKE_EXTRA_FLAGS} -S . -B build
44+
cmake ${CMAKE_C_COMPILER:+-DCMAKE_C_COMPILER="${CMAKE_C_COMPILER}"} ${CMAKE_CXX_COMPILER:+-DCMAKE_CXX_COMPILER="${CMAKE_CXX_COMPILER}"} -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTING=NO -DCMAKE_C_FLAGS="${CMAKE_C_FLAGS}" -DCMAKE_CXX_FLAGS="${CMAKE_CXX_FLAGS}" -DCMAKE_EXE_LINKER_FLAGS="${CMAKE_EXE_LINKER_FLAGS}" -DCMAKE_SHARED_LINKER_FLAGS="${CMAKE_SHARED_LINKER_FLAGS}" ${CMAKE_EXTRA_FLAGS} -S . -B build
4645
shell: bash
4746
- name: build
4847
run: cmake --build build --config Release

0 commit comments

Comments
 (0)