pineapple-src/externals/vcpkg/ports/fluidsynth/separate-gentables.patch

47 lines
1.5 KiB
Diff
Raw Normal View History

2022-07-22 21:01:36 -04:00
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index e913cb2..570207e 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -268,6 +268,9 @@ generate_product_version(
)
endif ( WIN32 )
+find_program(GENTABLES make_tables REQUIRED)
+execute_process(COMMAND ${GENTABLES} "${CMAKE_BINARY_DIR}/")
+
add_library ( libfluidsynth-OBJ OBJECT
${config_SOURCES}
${fluid_alsa_SOURCES}
@@ -413,6 +416,7 @@ else ( MACOSX_FRAMEWORK )
install ( FILES ${public_main_HEADER} DESTINATION ${INCLUDE_INSTALL_DIR} )
endif ( MACOSX_FRAMEWORK )
+if (0)
# ******* Auto Generated Lookup Tables ******
include(ExternalProject)
@@ -435,3 +439,4 @@ ExternalProject_Add(gentables
INSTALL_COMMAND ${GENTAB_BDIR}/make_tables.exe "${CMAKE_BINARY_DIR}/"
)
add_dependencies(libfluidsynth-OBJ gentables)
+endif()
diff --git a/src/gentables/CMakeLists.txt b/src/gentables/CMakeLists.txt
index 638f299..e834e34 100644
--- a/src/gentables/CMakeLists.txt
+++ b/src/gentables/CMakeLists.txt
@@ -15,7 +15,6 @@ project (gentables C)
set ( CMAKE_BUILD_TYPE Debug )
# hardcode ".exe" as suffix to the binary, else in case of cross-platform cross-compiling the calling cmake will not know the suffix used here and fail to find the binary
-set ( CMAKE_EXECUTABLE_SUFFIX ".exe" )
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY_DEBUG ${CMAKE_BINARY_DIR})
@@ -34,3 +33,5 @@ if ( WIN32 )
else ( WIN32 )
target_link_libraries (make_tables "m")
endif ()
+
+install(TARGETS make_tables DESTINATION bin)
\ No newline at end of file