-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #283 from sharkwouter/no-lgpl-for-sdl2-mixer
Do not link SDL2_mixer to libxmp, because LGPL
- Loading branch information
Showing
3 changed files
with
72 additions
and
10 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,19 @@ | ||
pkgname=libxmp-lite | ||
pkgver=4.5.0 | ||
pkgver=4.6.0 | ||
pkgrel=1 | ||
url="https://github.com/libxmp/libxmp" | ||
source=("https://github.com/libxmp/libxmp/releases/download/libxmp-${pkgver}/${pkgname}-${pkgver}.tar.gz") | ||
sha256sums=('19a019abd5a3ddf449cd20ca52cfe18970f6ab28abdffdd54cff563981a943bb') | ||
sha256sums=('71a93eb0119824bcc56eca95db154d1cdf30304b33d89a4732de6fef8a2c6f38') | ||
|
||
build() { | ||
cd $pkgname-$pkgver | ||
./configure --host=arm-vita-eabi --prefix=$prefix --disable-shared --enable-static | ||
mkdir -p build && cd build | ||
cmake -DCMAKE_TOOLCHAIN_FILE=$VITASDK/share/vita.toolchain.cmake -DCMAKE_INSTALL_PREFIX=$prefix -DBUILD_SHARED_LIBS=OFF \ | ||
-DCMAKE_POSITION_INDEPENDENT_CODE=OFF .. | ||
make -j$(nproc) | ||
} | ||
|
||
package () { | ||
cd $pkgname-$pkgver | ||
cd $pkgname-$pkgver/build | ||
make DESTDIR=$pkgdir install | ||
} |
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 |
---|---|---|
@@ -0,0 +1,56 @@ | ||
diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
index 54317572..2d5baaaa 100644 | ||
--- a/CMakeLists.txt | ||
+++ b/CMakeLists.txt | ||
@@ -589,10 +589,10 @@ if(SDL2MIXER_MOD_XMP) | ||
if(SDL2MIXER_MOD_XMP_LITE) | ||
message(STATUS "Using system libxmp-lite") | ||
find_package(libxmp-lite REQUIRED) | ||
- set(tgt_xmp libxmp-lite::libxmp-lite) | ||
+ set(tgt_xmp libxmp-lite) | ||
set(xmp_name libxmp-lite) | ||
if(NOT SDL2MIXER_MOD_XMP_SHARED) | ||
- list(APPEND PC_REQUIRES libxmplite) | ||
+ list(APPEND PC_REQUIRES libxmp-lite) | ||
endif() | ||
else() | ||
message(STATUS "Using system libxmp") | ||
diff --git a/cmake/Findlibxmp-lite.cmake b/cmake/Findlibxmp-lite.cmake | ||
index d0b2bbbb..911ed77b 100644 | ||
--- a/cmake/Findlibxmp-lite.cmake | ||
+++ b/cmake/Findlibxmp-lite.cmake | ||
@@ -1,9 +1,10 @@ | ||
find_library(libxmp_lite_LIBRARY | ||
- NAMES xmp | ||
+ NAMES xmp-lite | ||
) | ||
|
||
find_path(libxmp_lite_INCLUDE_PATH | ||
NAMES xmp.h | ||
+ PATH_SUFFIXES libxmp-lite | ||
) | ||
|
||
set(libxmp_lite_COMPILE_OPTIONS "" CACHE STRING "Extra compile options of libxmp_lite") | ||
@@ -12,20 +13,19 @@ set(libxmp_lite_LINK_LIBRARIES "" CACHE STRING "Extra link libraries of libxmp_l | ||
|
||
set(libxmp_lite_LINK_FLAGS "" CACHE STRING "Extra link flags of libxmp_lite") | ||
|
||
-find_package_handle_standard_args(libxmp_lite | ||
+find_package_handle_standard_args(libxmp-lite | ||
REQUIRED_VARS libxmp_lite_LIBRARY libxmp_lite_INCLUDE_PATH | ||
) | ||
|
||
if(libxmp_lite_FOUND) | ||
if(NOT TARGET libxmp-lite::libxmp-lite) | ||
add_library(libxmp-lite::libxmp-lite UNKNOWN IMPORTED) | ||
- set_target_properties(libxmp_lite::libxmp_lite-shared PROPERTIES | ||
+ set_target_properties(libxmp_lite::libxmp_lite PROPERTIES | ||
IMPORTED_LOCATION "${libxmp_lite_LIBRARY}" | ||
INTERFACE_INCLUDE_DIRECTORIES "${libxmp_lite_INCLUDE_PATH}" | ||
INTERFACE_COMPILE_OPTIONS "${libxmp_lite_COMPILE_OPTIONS}" | ||
INTERFACE_LINK_LIBRARIES "${libxmp_lite_LINK_LIBRARIES}" | ||
INTERFACE_LINK_FLAGS "${libxmp_lite_LINK_FLAGS}" | ||
) | ||
- endif() | ||
endif() | ||
endif() |