Skip to content

Commit 9df491e

Browse files
committed
CMake: Remove option to use mold
This can be easily achieved by settings `LDFLAGS=-fuse-ld=mold` before configuration.
1 parent bbae146 commit 9df491e

2 files changed

Lines changed: 1 addition & 11 deletions

File tree

CMakeLists.txt

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ set(CMAKE_COLOR_DIAGNOSTICS ON)
3636
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
3737

3838
option(BTOP_STATIC "Link btop statically" OFF)
39-
option(BTOP_USE_MOLD "Use mold to link btop" OFF)
4039
option(BTOP_PEDANTIC "Enable a bunch of additional warnings" OFF)
4140
option(BTOP_WERROR "Compile with warnings as errors" OFF)
4241
option(BTOP_GPU "Enable GPU support" ON)
@@ -100,7 +99,7 @@ execute_process(
10099
OUTPUT_VARIABLE GIT_COMMIT
101100
OUTPUT_STRIP_TRAILING_WHITESPACE ERROR_QUIET)
102101
set(CONFIGURE_COMMAND
103-
"cmake -DBTOP_STATIC=${BTOP_STATIC} -DBTOP_USE_MOLD=${BTOP_USE_MOLD} -DBTOP_GPU=${BTOP_GPU}"
102+
"cmake -DBTOP_STATIC=${BTOP_STATIC} -DBTOP_GPU=${BTOP_GPU}"
104103
)
105104
get_filename_component(CXX_COMPILER_BASENAME "${CMAKE_CXX_COMPILER}" NAME)
106105
set(COMPILER "${CXX_COMPILER_BASENAME}")
@@ -189,10 +188,6 @@ if(LINUX AND BTOP_GPU)
189188
endif()
190189
endif()
191190

192-
if(BTOP_USE_MOLD)
193-
target_link_options(btop PRIVATE -fuse-ld=mold)
194-
endif()
195-
196191
if(BTOP_STATIC)
197192
target_compile_definitions(btop PRIVATE STATIC_BUILD)
198193
target_link_options(btop PRIVATE -static LINKER:--fatal-warnings)

README.md

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -555,7 +555,6 @@ Can be set with `make setcap` (preferred) or `make setuid` or by running btop wi
555555
|---------------------------------|-------------------------------------------------------------------------|
556556
| `-DBTOP_STATIC=<ON\|OFF>` | Enables static linking (OFF by default) |
557557
| `-DBTOP_LTO=<ON\|OFF>` | Enables link time optimization (ON by default) |
558-
| `-DBTOP_USE_MOLD=<ON\|OFF>` | Use mold to link btop (OFF by default) |
559558
| `-DBTOP_PEDANTIC=<ON\|OFF>` | Compile with additional warnings (OFF by default) |
560559
| `-DBTOP_WERROR=<ON\|OFF>` | Compile with warnings as errors (OFF by default) |
561560
| `-DBTOP_GPU=<ON\|OFF>` | Enable GPU support (ON by default) |
@@ -726,7 +725,6 @@ Can be set with `make setcap` (preferred) or `make setuid` or by running btop wi
726725
| Configure flag | Description |
727726
|---------------------------------|-------------------------------------------------------------------------|
728727
| `-DBTOP_LTO=<ON\|OFF>` | Enables link time optimization (ON by default) |
729-
| `-DBTOP_USE_MOLD=<ON\|OFF>` | Use mold to link btop (OFF by default) |
730728
| `-DBTOP_PEDANTIC=<ON\|OFF>` | Compile with additional warnings (OFF by default) |
731729
| `-DBTOP_WERROR=<ON\|OFF>` | Compile with warnings as errors (OFF by default) |
732730
| `-DCMAKE_INSTALL_PREFIX=<path>` | The installation prefix ('/usr/local' by default) |
@@ -903,7 +901,6 @@ Can be set with `make setcap` (preferred) or `make setuid` or by running btop wi
903901
|---------------------------------|-------------------------------------------------------------------------|
904902
| `-DBTOP_STATIC=<ON\|OFF>` | Enables static linking (OFF by default) |
905903
| `-DBTOP_LTO=<ON\|OFF>` | Enables link time optimization (ON by default) |
906-
| `-DBTOP_USE_MOLD=<ON\|OFF>` | Use mold to link btop (OFF by default) |
907904
| `-DBTOP_PEDANTIC=<ON\|OFF>` | Compile with additional warnings (OFF by default) |
908905
| `-DBTOP_WERROR=<ON\|OFF>` | Compile with warnings as errors (OFF by default) |
909906
| `-DCMAKE_INSTALL_PREFIX=<path>` | The installation prefix ('/usr/local' by default) |
@@ -1064,7 +1061,6 @@ Can be set with `make setcap` (preferred) or `make setuid` or by running btop wi
10641061
| Configure flag | Description |
10651062
|---------------------------------|-------------------------------------------------------------------------|
10661063
| `-DBTOP_LTO=<ON\|OFF>` | Enables link time optimization (ON by default) |
1067-
| `-DBTOP_USE_MOLD=<ON\|OFF>` | Use mold to link btop (OFF by default) |
10681064
| `-DBTOP_PEDANTIC=<ON\|OFF>` | Compile with additional warnings (OFF by default) |
10691065
| `-DBTOP_WERROR=<ON\|OFF>` | Compile with warnings as errors (OFF by default) |
10701066
| `-DCMAKE_INSTALL_PREFIX=<path>` | The installation prefix ('/usr/local' by default) |
@@ -1225,7 +1221,6 @@ Can be set with `make setcap` (preferred) or `make setuid` or by running btop wi
12251221
| Configure flag | Description |
12261222
|---------------------------------|-------------------------------------------------------------------------|
12271223
| `-DBTOP_LTO=<ON\|OFF>` | Enables link time optimization (ON by default) |
1228-
| `-DBTOP_USE_MOLD=<ON\|OFF>` | Use mold to link btop (OFF by default) |
12291224
| `-DBTOP_PEDANTIC=<ON\|OFF>` | Compile with additional warnings (OFF by default) |
12301225
| `-DBTOP_WERROR=<ON\|OFF>` | Compile with warnings as errors (OFF by default) |
12311226
| `-DCMAKE_INSTALL_PREFIX=<path>` | The installation prefix ('/usr/local' by default) |

0 commit comments

Comments
 (0)