This repository has been archived on 2023-08-20. You can view files and clone it, but cannot push or open issues or pull requests.
lsts_glued/rules/flac/default.bash
2014-02-04 07:44:17 +00:00

59 lines
918 B
Bash

version=\
(
"1.2.1"
)
url=\
(
"http://downloads.sourceforge.net/project/flac/flac-src/flac-${version}-src/flac-${version}.tar.gz"
)
md5=\
(
"153c8b15a54da428d1f0fadc756c22c7"
)
requires=(
"libogg/default"
)
post_unpack()
{
patches=$(ls "$pkg_dir/patches-$version/"*.patch)
if [ -n "$patches" ]; then
cat $patches | patch -p1
fi
}
configure()
{
./configure \
--prefix="${cfg_dir_toolchain_sysroot}/usr" \
--target="$cfg_target_canonical" \
--host="$cfg_target_canonical" \
--build="$cfg_host_canonical"
}
build()
{
$cmd_make
}
host_install()
{
$cmd_make install
}
target_install()
{
# Libs:
for f in "$cfg_dir_toolchain_sysroot/usr/lib/"libFLAC*.so*; do
if [ -L "$f" ]; then
$cmd_cp "$f" "$cfg_dir_rootfs/usr/lib"
else
$cmd_target_strip -v "$f" -o "$cfg_dir_rootfs/usr/lib/$(basename "$f")"
fi
done
}