From c44e2e69855c7111a81d2d7a9a78e254ece6ba6f Mon Sep 17 00:00:00 2001 From: Jean Pierre Cimalando Date: Fri, 6 Mar 2020 15:24:57 +0100 Subject: [PATCH] Add linker options for MinGW --- vst/CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/vst/CMakeLists.txt b/vst/CMakeLists.txt index 0d8c505f..89c9bfc4 100644 --- a/vst/CMakeLists.txt +++ b/vst/CMakeLists.txt @@ -57,6 +57,10 @@ if (${CMAKE_SYSTEM_NAME} MATCHES "Linux") target_link_libraries(${VSTPLUGIN_PRJ_NAME} PRIVATE "-Wl,--version-script=${CMAKE_CURRENT_SOURCE_DIR}/vst3.version") endif() +sfizz_enable_lto_if_needed (${VSTPLUGIN_PRJ_NAME}) +if (MINGW) + set_target_properties (${VSTPLUGIN_PRJ_NAME} PROPERTIES LINK_FLAGS "-static") +endif() # Create the bundle (see "VST 3 Locations / Format") execute_process (