mirror of
https://github.com/mhx/dwarfs.git
synced 2025-08-04 02:06:22 -04:00
build: also build static binaries with -O2
This commit is contained in:
parent
e0bcadd02c
commit
340c96fd56
@ -77,6 +77,10 @@ case "-$BUILD_TYPE-" in
|
|||||||
exit 1
|
exit 1
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
if [[ "-$BUILD_TYPE-" == *-O2-* ]]; then
|
||||||
|
CMAKE_ARGS="${CMAKE_ARGS} -DDWARFS_OPTIMIZE=2"
|
||||||
|
fi
|
||||||
|
|
||||||
if [[ "-$BUILD_TYPE-" == *-nojemalloc-* ]]; then
|
if [[ "-$BUILD_TYPE-" == *-nojemalloc-* ]]; then
|
||||||
CMAKE_ARGS="${CMAKE_ARGS} -DUSE_JEMALLOC=0"
|
CMAKE_ARGS="${CMAKE_ARGS} -DUSE_JEMALLOC=0"
|
||||||
fi
|
fi
|
||||||
@ -117,8 +121,9 @@ if [[ "-$BUILD_TYPE-" == *-coverage-* ]]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ "-$BUILD_TYPE-" == *-static-* ]]; then
|
if [[ "-$BUILD_TYPE-" == *-static-* ]]; then
|
||||||
|
if [[ "-$BUILD_TYPE-" == *-release-* ]]; then
|
||||||
# in the clang-release-static case, we also try to build from the source tarball
|
# in the clang-release-static case, we also try to build from the source tarball
|
||||||
if [[ "-$BUILD_TYPE-" == *-release-* ]] && [[ "-$BUILD_TYPE-" == *-clang-* ]]; then
|
if [[ "-$BUILD_TYPE-" == *-clang-* ]] && [[ "-$BUILD_TYPE-" != *-O2-* ]]; then
|
||||||
$BUILD_TOOL package_source
|
$BUILD_TOOL package_source
|
||||||
|
|
||||||
if [[ "$BUILD_ARCH" == "amd64" ]]; then
|
if [[ "$BUILD_ARCH" == "amd64" ]]; then
|
||||||
@ -150,6 +155,7 @@ if [[ "-$BUILD_TYPE-" == *-static-* ]]; then
|
|||||||
$BUILD_TOOL
|
$BUILD_TOOL
|
||||||
|
|
||||||
ctest --output-on-failure -j$(nproc)
|
ctest --output-on-failure -j$(nproc)
|
||||||
|
fi
|
||||||
|
|
||||||
$BUILD_TOOL strip
|
$BUILD_TOOL strip
|
||||||
fi
|
fi
|
||||||
|
2
.github/workflows/build.yml
vendored
2
.github/workflows/build.yml
vendored
@ -106,7 +106,9 @@ jobs:
|
|||||||
- oldgcc-debug-make
|
- oldgcc-debug-make
|
||||||
- clang-release-ninja
|
- clang-release-ninja
|
||||||
- gcc-release-ninja-static
|
- gcc-release-ninja-static
|
||||||
|
- gcc-release-ninja-O2-static
|
||||||
- clang-release-ninja-static
|
- clang-release-ninja-static
|
||||||
|
- clang-release-ninja-O2-static
|
||||||
- clang-reldbg-ninja-static
|
- clang-reldbg-ninja-static
|
||||||
- clang-debug-ninja-static
|
- clang-debug-ninja-static
|
||||||
include:
|
include:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user