fix compiling on avr32
[openwrt/svn-archive/archive.git] / libs / libaudiofile / Makefile
1 #
2 # Copyright (C) 2006 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=libaudiofile
12 PKG_VERSION:=0.2.6
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
16 PKG_SOURCE_URL:=http://www.cti.ecp.fr/~beauxir5/peercast
17 PKG_MD5SUM:=460f848ce5f4a33ae66b15a4fb7720ec
18
19 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)/$(PKG_NAME)-$(PKG_VERSION)
20 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
21
22 include $(INCLUDE_DIR)/package.mk
23
24 define Package/libaudiofile
25 SECTION:=libs
26 CATEGORY:=Libraries
27 TITLE:=Audio File library
28 URL:=http://www.68k.org/~michael/audiofile/
29 endef
30
31 define Package/libaudiofile/description
32 The audiofile library allows the processing of audio data to and from audio
33 files of many common formats (currently AIFF, AIFF-C, WAVE, NeXT/Sun, BICS,
34 and raw data).
35 endef
36
37 define Build/Configure
38 $(call Build/Configure/Default, \
39 --enable-shared \
40 --enable-static \
41 --with-build-cc="$(HOSTCC)" \
42 )
43 endef
44
45 define Build/Compile
46 $(MAKE) -C $(PKG_BUILD_DIR) \
47 DESTDIR="$(PKG_INSTALL_DIR)" \
48 all install
49 endef
50
51 define Build/InstallDev
52 mkdir -p $(1)/usr/bin
53 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/audiofile-config $(1)/usr/bin/
54 mkdir -p $(1)/usr/include
55 $(CP) $(PKG_INSTALL_DIR)/usr/include/af_vfs.h $(1)/usr/include/
56 $(CP) $(PKG_INSTALL_DIR)/usr/include/audiofile.h $(1)/usr/include/
57 $(CP) $(PKG_INSTALL_DIR)/usr/include/aupvlist.h $(1)/usr/include/
58 mkdir -p $(1)/usr/lib
59 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libaudiofile.{a,so*} $(1)/usr/lib/
60 mkdir -p $(1)/usr/lib/pkgconfig
61 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/audiofile.pc $(1)/usr/lib/pkgconfig/
62 endef
63
64 define Package/libaudiofile/install
65 $(INSTALL_DIR) $(1)/usr/lib
66 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libaudiofile.so.* $(1)/usr/lib/
67 endef
68
69 $(eval $(call BuildPackage,libaudiofile))