2024-10-04 15:20:13 +08:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
source versions.sh
|
|
|
|
|
|
|
|
GLSOURCES="/sources"
|
|
|
|
|
2024-10-09 02:37:48 +08:00
|
|
|
pushd ${GLSOURCES} > /dev/null 2>&1 || myfail "Failed to move to ${GLSOURCES}"
|
2024-10-04 15:20:13 +08:00
|
|
|
|
|
|
|
[ -d lz4-${lz4_version} ] && rm -rf lz4-${lz4_version}
|
|
|
|
|
|
|
|
tar -zxf ${lz4_tarball}
|
|
|
|
|
|
|
|
cd lz4-${lz4_version}
|
|
|
|
|
|
|
|
make BUILD_STATIC=no PREFIX=/usr
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
|
myfail "Failed building lz4"
|
|
|
|
fi
|
|
|
|
|
2024-10-09 02:37:48 +08:00
|
|
|
if [ ! -f ${GLSOURCES}/SKIPTESTS ]; then
|
|
|
|
echo "running lz4 make check"
|
|
|
|
make -j1 check > ${GLSOURCES}/lz4.check.log 2>&1
|
|
|
|
fi
|
2024-10-04 15:20:13 +08:00
|
|
|
|
|
|
|
make BUILD_STATIC=no PREFIX=/usr install
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
|
myfail "Failed installing lz4"
|
|
|
|
fi
|
|
|
|
|
2024-10-08 12:28:55 +08:00
|
|
|
popd
|
|
|
|
|
|
|
|
# cleanup
|
|
|
|
|
|
|
|
pushd $GLSOURCES
|
|
|
|
|
|
|
|
rm -rf lz4-${lz4_version}
|
|
|
|
|
|
|
|
popd
|