aboutsummaryrefslogtreecommitdiff
path: root/scripts/xz.sh
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/xz.sh')
-rw-r--r--scripts/xz.sh24
1 files changed, 24 insertions, 0 deletions
diff --git a/scripts/xz.sh b/scripts/xz.sh
new file mode 100644
index 0000000..079f3e2
--- /dev/null
+++ b/scripts/xz.sh
@@ -0,0 +1,24 @@
+#!/bin/sh
+. ./.vars
+VERSION=5.2.3
+APP_NAME="xz"
+BUILD_DIR="${build_dir}/$APP_NAME-$VERSION"
+if ! [ -d "$BUILD_DIR" ] ; then
+ cd "$build_dir"
+ tar xfJv ${dist_dir}/$APP_NAME-$VERSION.tar.xz
+fi
+cd "$BUILD_DIR"
+export CC=$BUILD_TGT-gcc
+export CFLAGS="-I$prefix/usr/include -static"
+export CPPFLAGS="$CFLAGS"
+export DESTDIR=$prefix
+export LDFLAGS="-L$prefix/usr/lib/ -static"
+rm config.log || echo ""
+make clean || echo ""
+./configure \
+ --host=$BUILD_TGT \
+ --prefix=/usr \
+ --enable-threads='yes' \
+ --with-sysroot=$prefix
+make -j$(nproc)
+make install