Static linking for MinGW
This commit is contained in:
parent
b07c429d7b
commit
4c41811bb4
3 changed files with 5 additions and 3 deletions
|
|
@ -7,11 +7,11 @@ mkdir -p build/${INSTALL_DIR} && cd build
|
|||
|
||||
if [[ ${CROSS_COMPILE} == "mingw32" ]]; then
|
||||
|
||||
buildenv i686-w64-mingw32-cmake -DCMAKE_BUILD_TYPE=Release -DSFIZZ_JACK=OFF ..
|
||||
buildenv i686-w64-mingw32-cmake -DCMAKE_BUILD_TYPE=Release -DSFIZZ_JACK=OFF -DSFIZZ_STATIC_LIBSNDFILE=ON ..
|
||||
buildenv make -j
|
||||
elif [[ ${CROSS_COMPILE} == "mingw64" ]]; then
|
||||
|
||||
buildenv x86_64-w64-mingw32-cmake -DCMAKE_BUILD_TYPE=Release -DSFIZZ_JACK=OFF ..
|
||||
buildenv x86_64-w64-mingw32-cmake -DCMAKE_BUILD_TYPE=Release -DSFIZZ_JACK=OFF -DSFIZZ_STATIC_LIBSNDFILE=ON ..
|
||||
buildenv make -j
|
||||
elif [[ ${BUILD_TYPE} == "lv2" ]]; then
|
||||
|
||||
|
|
|
|||
|
|
@ -22,6 +22,9 @@ if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
|
|||
endif()
|
||||
target_include_directories(${LV2PLUGIN_PRJ_NAME} PRIVATE . external/ardour)
|
||||
sfizz_enable_lto_if_needed (${LV2PLUGIN_PRJ_NAME})
|
||||
if (MINGW)
|
||||
target_link_options (${LV2PLUGIN_PRJ_NAME} PRIVATE "-static")
|
||||
endif()
|
||||
|
||||
# Remove the "lib" prefix, rename the target name and build it in the .lv build dir
|
||||
# <build_dir>/lv2/<plugin_name>_lv2.<ext> to
|
||||
|
|
|
|||
|
|
@ -68,4 +68,3 @@ if (SFIZZ_SHARED)
|
|||
endif()
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue