forked from surge-synthesizer/surge
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
CMake: Abolish OS_COMPILE_OPTIONS (surge-synthesizer#2788)
This makes compile options cross-platform and globalizes them, making them apply to (future) CMake subdirectories. A few flags were changed: - The macOS warning settings are now effective for all Clang builds. - Suppressed some noisy Windows Clang warnings caused by headers. - Linux: -f{function,data}-sections was dropped. Didn't have much of an effect anyway without --gc-sections, and enabling that only saved about 10% in binary size, not worth the possible downsides.
- Loading branch information
Showing
3 changed files
with
87 additions
and
100 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,10 @@ | ||
set( LINUX_ON_ARM True ) | ||
set(LINUX_ON_ARM_COMPILE_OPTIONS | ||
set(FLAGS | ||
-march=native | ||
-mcpu=native | ||
-Wno-psabi | ||
-flax-vector-conversions #FIXME - remove this | ||
) | ||
|
||
string(REPLACE ";" " " FLAGS "${FLAGS}") | ||
set(CMAKE_C_FLAGS_INIT "${FLAGS}" CACHE STRING "" FORCE) | ||
set(CMAKE_CXX_FLAGS_INIT "${FLAGS}" CACHE STRING "" FORCE) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters