Commit 813042bf authored by Natanael Copa's avatar Natanael Copa

main/libmad: new aport

A high-quality MPEG audio decoder
http://www.underbit.com/products/mad/
parent 92d1bc8f
# Contributor: Sebastian Wicki <gandro@gmx.net>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=libmad
pkgver=0.15.1b
pkgrel=0
pkgdesc="A high-quality MPEG audio decoder"
url="http://www.underbit.com/products/mad/"
license="GPL"
subpackages="$pkgname-dev"
depends=
makedepends="autoconf automake libtool"
source="http://downloads.sourceforge.net/sourceforge/mad/$pkgname-$pkgver.tar.gz
libmad-0.15.1b-cflags-O2.patch
libmad-0.15.1b-cflags.patch
mad.pc
"
build ()
{
cd "$srcdir"/$pkgname-$pkgver
for i in ../*.patch; do
msg "Applying $i..."
patch -Np1 -i $i || return 1
done
aclocal && autoconf && ./missing --run automake --foreign \
&& libtoolize --force || return 1
./configure --prefix=/usr \
--enable-fpm=intel \
--enable-accuracy
make -j1 || return 1
make DESTDIR="$pkgdir" install
install -D -m644 "$srcdir"/mad.pc "$pkgdir"/usr/lib/pkgconfig/mad.pc
}
md5sums="1be543bc30c56fb6bea1d7bf6a64e66c libmad-0.15.1b.tar.gz
fbda7a1821e2038221deb3f476da034d libmad-0.15.1b-cflags-O2.patch
bcd6eab331fc316baf4e9c9882fe13f4 libmad-0.15.1b-cflags.patch
89806934195402446d21d1a83f523b11 mad.pc"
diff -Naur libmad-0.15.1b-orig/configure.ac libmad-0.15.1b/configure.ac
--- libmad-0.15.1b-orig/configure.ac 2007-07-01 12:58:13.000000000 -0600
+++ libmad-0.15.1b/configure.ac 2007-07-01 12:59:13.000000000 -0600
@@ -105,7 +105,7 @@
shift
;;
-O2)
- optimize="-O"
+ optimize="-O2"
shift
;;
-fomit-frame-pointer)
diff -Naur libmad-0.15.1b-orig/configure.ac libmad-0.15.1b/configure.ac
--- libmad-0.15.1b-orig/configure.ac 2007-06-30 20:22:31.000000000 -0600
+++ libmad-0.15.1b/configure.ac 2007-06-30 20:25:31.000000000 -0600
@@ -122,74 +122,74 @@
esac
done
-if test "$GCC" = yes
-then
- if test -z "$arch"
- then
- case "$host" in
- i386-*) ;;
- i?86-*) arch="-march=i486" ;;
- arm*-empeg-*) arch="-march=armv4 -mtune=strongarm1100" ;;
- armv4*-*) arch="-march=armv4 -mtune=strongarm" ;;
- powerpc-*) ;;
- mips*-agenda-*) arch="-mcpu=vr4100" ;;
- mips*-luxsonor-*) arch="-mips1 -mcpu=r3000 -Wa,-m4010" ;;
- esac
- fi
-
- case "$optimize" in
- -O|"-O "*)
- optimize="-O"
- optimize="$optimize -fforce-mem"
- optimize="$optimize -fforce-addr"
- : #x optimize="$optimize -finline-functions"
- : #- optimize="$optimize -fstrength-reduce"
- optimize="$optimize -fthread-jumps"
- optimize="$optimize -fcse-follow-jumps"
- optimize="$optimize -fcse-skip-blocks"
- : #x optimize="$optimize -frerun-cse-after-loop"
- : #x optimize="$optimize -frerun-loop-opt"
- : #x optimize="$optimize -fgcse"
- optimize="$optimize -fexpensive-optimizations"
- optimize="$optimize -fregmove"
- : #* optimize="$optimize -fdelayed-branch"
- : #x optimize="$optimize -fschedule-insns"
- optimize="$optimize -fschedule-insns2"
- : #? optimize="$optimize -ffunction-sections"
- : #? optimize="$optimize -fcaller-saves"
- : #> optimize="$optimize -funroll-loops"
- : #> optimize="$optimize -funroll-all-loops"
- : #x optimize="$optimize -fmove-all-movables"
- : #x optimize="$optimize -freduce-all-givs"
- : #? optimize="$optimize -fstrict-aliasing"
- : #* optimize="$optimize -fstructure-noalias"
-
- case "$host" in
- arm*-*)
- optimize="$optimize -fstrength-reduce"
- ;;
- mips*-*)
- optimize="$optimize -fstrength-reduce"
- optimize="$optimize -finline-functions"
- ;;
- i?86-*)
- optimize="$optimize -fstrength-reduce"
- ;;
- powerpc-apple-*)
- # this triggers an internal compiler error with gcc2
- : #optimize="$optimize -fstrength-reduce"
-
- # this is really only beneficial with gcc3
- : #optimize="$optimize -finline-functions"
- ;;
- *)
- # this sometimes provokes bugs in gcc 2.95.2
- : #optimize="$optimize -fstrength-reduce"
- ;;
- esac
- ;;
- esac
-fi
+#if test "$GCC" = yes
+#then
+# if test -z "$arch"
+# then
+# case "$host" in
+# i386-*) ;;
+# i?86-*) arch="-march=i486" ;;
+# arm*-empeg-*) arch="-march=armv4 -mtune=strongarm1100" ;;
+# armv4*-*) arch="-march=armv4 -mtune=strongarm" ;;
+# powerpc-*) ;;
+# mips*-agenda-*) arch="-mcpu=vr4100" ;;
+# mips*-luxsonor-*) arch="-mips1 -mcpu=r3000 -Wa,-m4010" ;;
+# esac
+# fi
+#
+# case "$optimize" in
+# -O|"-O "*)
+# optimize="-O"
+# optimize="$optimize -fforce-mem"
+# optimize="$optimize -fforce-addr"
+# : #x optimize="$optimize -finline-functions"
+# : #- optimize="$optimize -fstrength-reduce"
+# optimize="$optimize -fthread-jumps"
+# optimize="$optimize -fcse-follow-jumps"
+# optimize="$optimize -fcse-skip-blocks"
+# : #x optimize="$optimize -frerun-cse-after-loop"
+# : #x optimize="$optimize -frerun-loop-opt"
+# : #x optimize="$optimize -fgcse"
+# optimize="$optimize -fexpensive-optimizations"
+# optimize="$optimize -fregmove"
+# : #* optimize="$optimize -fdelayed-branch"
+# : #x optimize="$optimize -fschedule-insns"
+# optimize="$optimize -fschedule-insns2"
+# : #? optimize="$optimize -ffunction-sections"
+# : #? optimize="$optimize -fcaller-saves"
+# : #> optimize="$optimize -funroll-loops"
+# : #> optimize="$optimize -funroll-all-loops"
+# : #x optimize="$optimize -fmove-all-movables"
+# : #x optimize="$optimize -freduce-all-givs"
+# : #? optimize="$optimize -fstrict-aliasing"
+# : #* optimize="$optimize -fstructure-noalias"
+#
+# case "$host" in
+# arm*-*)
+# optimize="$optimize -fstrength-reduce"
+# ;;
+# mips*-*)
+# optimize="$optimize -fstrength-reduce"
+# optimize="$optimize -finline-functions"
+# ;;
+# i?86-*)
+# optimize="$optimize -fstrength-reduce"
+# ;;
+# powerpc-apple-*)
+# # this triggers an internal compiler error with gcc2
+# : #optimize="$optimize -fstrength-reduce"
+#
+# # this is really only beneficial with gcc3
+# : #optimize="$optimize -finline-functions"
+# ;;
+# *)
+# # this sometimes provokes bugs in gcc 2.95.2
+# : #optimize="$optimize -fstrength-reduce"
+# ;;
+# esac
+# ;;
+# esac
+#fi
case "$host" in
mips*-agenda-*)
prefix=/usr
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=${prefix}/include
Name: mad
Description: MPEG Audio Decoder
Requires:
Version: 0.15.0b
Libs: -L${libdir} -lmad -lm
Cflags: -I${includedir}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment