From af0fbf042523601d00ae058d13d23f4c22760977 Mon Sep 17 00:00:00 2001 From: Fredrik Fornwall Date: Thu, 26 Sep 2019 00:29:19 +0200 Subject: [PATCH] luv: Link against libm and liblua --- packages/luv/CMakeLists.txt.patch | 15 ++++++++++++--- packages/luv/build.sh | 10 ++-------- packages/luv/libluv.pc.in | 12 ------------ 3 files changed, 14 insertions(+), 23 deletions(-) delete mode 100644 packages/luv/libluv.pc.in diff --git a/packages/luv/CMakeLists.txt.patch b/packages/luv/CMakeLists.txt.patch index 866cee7cc..313682650 100644 --- a/packages/luv/CMakeLists.txt.patch +++ b/packages/luv/CMakeLists.txt.patch @@ -1,6 +1,6 @@ -diff -u -r ../luv-1.30.1-0/CMakeLists.txt ./CMakeLists.txt ---- ../luv-1.30.1-0/CMakeLists.txt 2019-08-02 04:08:32.000000000 +0000 -+++ ./CMakeLists.txt 2019-09-17 19:52:12.573735604 +0000 +diff -u -r ../luv-1.30.1-1/CMakeLists.txt ./CMakeLists.txt +--- ../luv-1.30.1-1/CMakeLists.txt 2019-09-18 04:33:34.000000000 +0000 ++++ ./CMakeLists.txt 2019-09-25 22:23:19.659091635 +0000 @@ -107,7 +107,6 @@ include_directories(${LUAJIT_INCLUDE_DIR}) link_directories(${LUAJIT_LIBRARIES}) @@ -9,3 +9,12 @@ diff -u -r ../luv-1.30.1-0/CMakeLists.txt ./CMakeLists.txt include_directories(${LUA_INCLUDE_DIR}) endif (USE_LUAJIT) +@@ -175,7 +174,7 @@ + elseif("${CMAKE_SYSTEM_NAME}" MATCHES "Linux") + target_link_libraries(luv ${LIBUV_LIBRARIES} rt) + else() +- target_link_libraries(luv ${LIBUV_LIBRARIES}) ++ target_link_libraries(luv m lua ${LIBUV_LIBRARIES}) + endif() + + if (NOT LUA) diff --git a/packages/luv/build.sh b/packages/luv/build.sh index 488b31179..45475e484 100644 --- a/packages/luv/build.sh +++ b/packages/luv/build.sh @@ -1,8 +1,8 @@ TERMUX_PKG_HOMEPAGE=https://github.com/luvit/luv TERMUX_PKG_DESCRIPTION="Bare libuv bindings for lua" TERMUX_PKG_LICENSE="Apache-2.0" -TERMUX_PKG_VERSION="1.30.1-0" -TERMUX_PKG_SHA256=420fc299f3b25aff55b839e9fe590982f45045b3e53ebeab2449eca7e23a106a +TERMUX_PKG_VERSION="1.30.1-1" +TERMUX_PKG_SHA256=4e287bed6f51fd50ce03ba7fa8cc33d84e1b9cb86911c4812bb1f47a1e3ed12a TERMUX_PKG_SRCURL=https://github.com/luvit/luv/releases/download/$TERMUX_PKG_VERSION/luv-$TERMUX_PKG_VERSION.tar.gz TERMUX_PKG_DEPENDS="liblua, libuv" TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" @@ -10,12 +10,6 @@ TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" -DBUILD_SHARED_LIBS=ON -DLUA_BUILD_TYPE=System -DLUA_INCLUDE_DIR=$TERMUX_PREFIX/include --DLUA_LIBRARY=$TERMUX_PREFIX/lib/liblua.so -DWITH_LUA_ENGINE=Lua -DWITH_SHARED_LIBUV=ON " - -termux_step_post_extract_package() { - # https://github.com/luvit/luv/issues/376 - cp $TERMUX_PKG_BUILDER_DIR/libluv.pc.in $TERMUX_PKG_SRCDIR -} diff --git a/packages/luv/libluv.pc.in b/packages/luv/libluv.pc.in deleted file mode 100644 index d1544f650..000000000 --- a/packages/luv/libluv.pc.in +++ /dev/null @@ -1,12 +0,0 @@ -prefix=@prefix@ -exec_prefix=${prefix} -libdir=@libdir@ -includedir=@includedir@ - -Name: libluv -Version: @LUV_VERSION@ -Description: Bare and full libuv bindings for Lua/LuaJIT. -URL: https://github.com/luvit/luv - -Libs: -L${libdir} -lluv @LIBS@ -Cflags: -I${includedir}