mirror of
https://github.com/mhx/dwarfs.git
synced 2025-08-03 17:56:12 -04:00
build: enable --gc-sections also in release mode
This commit is contained in:
parent
3366ef4585
commit
b1d3e7e41e
@ -121,6 +121,9 @@ case "-$BUILD_TYPE-" in
|
|||||||
*-release-*)
|
*-release-*)
|
||||||
CMAKE_ARGS="${CMAKE_ARGS} -DCMAKE_BUILD_TYPE=Release"
|
CMAKE_ARGS="${CMAKE_ARGS} -DCMAKE_BUILD_TYPE=Release"
|
||||||
CMAKE_ARGS="${CMAKE_ARGS} -DWITH_BENCHMARKS=1"
|
CMAKE_ARGS="${CMAKE_ARGS} -DWITH_BENCHMARKS=1"
|
||||||
|
export CFLAGS="-ffunction-sections -fdata-sections -fvisibility=hidden -fmerge-all-constants"
|
||||||
|
export CXXFLAGS="${CFLAGS}"
|
||||||
|
export LDFLAGS="-Wl,--gc-sections"
|
||||||
;;
|
;;
|
||||||
*-relsize-*)
|
*-relsize-*)
|
||||||
CMAKE_ARGS="${CMAKE_ARGS} -DCMAKE_BUILD_TYPE=MinSizeRel"
|
CMAKE_ARGS="${CMAKE_ARGS} -DCMAKE_BUILD_TYPE=MinSizeRel"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user