brotli: Update from 1.0.3 to 1.0.4

Also switch to building with cmake, and add a patch to build the
brotli binary against shared libs (binary size from 700 kb to 70 kb).
This commit is contained in:
Fredrik Fornwall 2018-05-27 14:51:20 +02:00
parent b42ad0b3f3
commit d8b43f2e48
2 changed files with 18 additions and 9 deletions

View File

@ -0,0 +1,12 @@
diff -u -r ../brotli-1.0.4/CMakeLists.txt ./CMakeLists.txt
--- ../brotli-1.0.4/CMakeLists.txt 2018-03-29 08:37:07.000000000 +0000
+++ ./CMakeLists.txt 2018-05-27 12:33:42.384489726 +0000
@@ -183,7 +183,7 @@
# Build the brotli executable
add_executable(brotli ${BROTLI_CLI_C})
-target_link_libraries(brotli ${BROTLI_LIBRARIES_STATIC})
+target_link_libraries(brotli ${BROTLI_LIBRARIES})
# Installation
if(NOT BROTLI_BUNDLED_MODE)

View File

@ -1,15 +1,12 @@
TERMUX_PKG_HOMEPAGE=https://github.com/google/brotli
TERMUX_PKG_DESCRIPTION="lossless compression algorithm and format (command line utility)"
TERMUX_PKG_VERSION=1.0.3
TERMUX_PKG_VERSION=1.0.4
TERMUX_PKG_SHA256=2268a3dff1cc36e18549e89a51ee0cd9513908a977d56d6a1f9d4c61c2af37c3
TERMUX_PKG_SRCURL=https://github.com/google/brotli/archive/v$TERMUX_PKG_VERSION.tar.gz
TERMUX_PKG_SHA256=7948154166ef8556f8426a4ede219aaa98a81a5baffe1f7cf2523fa67d59cd1c
TERMUX_PKG_BUILD_IN_SRC=yes
termux_step_pre_configure() {
./bootstrap
}
TERMUX_PKG_FORCE_CMAKE=yes
termux_step_post_make_install() {
cp docs/brotli.1 $TERMUX_PREFIX/share/man/man1
cp docs/*.3 $TERMUX_PREFIX/share/man/man3
mkdir -p $TERMUX_PREFIX/share/man/man{1,3}
cp $TERMUX_PKG_SRCDIR/docs/brotli.1 $TERMUX_PREFIX/share/man/man1/
cp $TERMUX_PKG_SRCDIR/docs/*.3 $TERMUX_PREFIX/share/man/man3/
}