diff options
| author | Qi-rui Chen <Qi-rui.Chen.2015@my.bristol.ac.uk> | 2019-03-01 00:28:13 +0000 |
|---|---|---|
| committer | Victor Romero <romerosanchezv@gmail.com> | 2019-02-28 16:28:13 -0800 |
| commit | 590f3a78b2d64ef1beb71129feca3db24c710a25 (patch) | |
| tree | 270c7f810c7469d08fe8c0988bc6c1ccf4c91623 /ports/libmodplug/002-detect_sinf.patch | |
| parent | 7859944528be28bee1fda9f325b78d6a7f02124e (diff) | |
| download | vcpkg-590f3a78b2d64ef1beb71129feca3db24c710a25.tar.gz vcpkg-590f3a78b2d64ef1beb71129feca3db24c710a25.zip | |
Fix libmodplug to build on Linux (#5397)
* Update libmodplug to build on linux
* [libmodplug] Patch instead of changing downloading source
* [libmodplug] Keep original source instead of using fork
Diffstat (limited to 'ports/libmodplug/002-detect_sinf.patch')
| -rw-r--r-- | ports/libmodplug/002-detect_sinf.patch | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/ports/libmodplug/002-detect_sinf.patch b/ports/libmodplug/002-detect_sinf.patch new file mode 100644 index 000000000..784e2e663 --- /dev/null +++ b/ports/libmodplug/002-detect_sinf.patch @@ -0,0 +1,35 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 2ada51b..468f1a3 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -4,6 +4,7 @@ project(libmodplug) + add_definitions(-DMODPLUG_BUILD) + + include (CheckFunctionExists) ++include (CheckIncludeFile) + + include_directories(AFTER + src +@@ -11,6 +12,10 @@ include_directories(AFTER + ${PROJECT_BINARY_DIR} + ) + ++if (UNIX) ++ set (CMAKE_REQUIRED_LIBRARIES m) ++endif() ++ + if (WIN32) + add_definitions(-D_USE_MATH_DEFINES) + add_definitions(-DNOMINMAX) +@@ -44,6 +49,11 @@ if (WIN32 AND NOT (MINGW OR MSYS)) + "Compilation may fail if inttypes.h is not natively supported by the compiler." + "You can get inttypes.h from http://code.google.com/p/msinttypes/") + endif() ++else() ++ check_include_file("stdint.h" HAVE_STDINT) ++ if (HAVE_STDINT) ++ add_definitions(-DHAVE_STDINT_H) ++ endif() + endif() + + check_function_exists("setenv" HAVE_SETENV) |
