update alsa-lib to 1.0.11, fix compile on mac os x
[openwrt/svn-archive/archive.git] / libs / alsa-lib / 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:=alsa-lib
12 PKG_VERSION:=1.0.11
13 PKG_RELEASE:=1
14
15 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
16 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
17 PKG_SOURCE_URL:=ftp://ftp.alsa-project.org/pub/lib/
18 PKG_MD5SUM:=ef7ae78a0ef08cbeacb295f2518886ab
19 PKG_CAT:=bzcat
20
21 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
22
23 include $(INCLUDE_DIR)/package.mk
24
25 define Package/alsa-lib
26 SECTION:=libs
27 CATEGORY:=Libraries
28 DEPENDS:=+alsa
29 TITLE:=Advanced Linux Sound Architecture Library
30 DESCRIPTION:=This is the library package for alsa, needed by some userspace programs. You must\\\
31 have enabled the ALSA support in the kernel.
32 URL:=http://www.alsa-project.org/
33 endef
34
35 define Build/Configure
36 $(call Build/Configure/Default,\
37 --enable-shared=yes \
38 --enable-static=yes \
39 --with-gnu-ld \
40 --disable-debugging \
41 --disable-profiling \
42 --with-softfloat \
43 --with-versioned=no \
44 )
45 endef
46
47 define Build/Compile
48 $(call Build/Compile/Default,\
49 DESTDIR="$(PKG_INSTALL_DIR)" \
50 all install)
51 endef
52
53 define Package/alsa-lib/install
54 install -d -m0755 $(1)/usr/lib
55 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libasound.so.* $(1)/usr/lib/
56 endef
57
58 define Build/InstallDev
59 mkdir -p $(STAGING_DIR)/usr/include
60 $(CP) $(PKG_INSTALL_DIR)/usr/include/alsa $(STAGING_DIR)/usr/include/
61 mkdir -p $(STAGING_DIR)/usr/lib
62 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libasound.{a,so}* $(STAGING_DIR)/usr/lib/
63 endef
64
65 define Build/UninstallDev
66 rm -rf \
67 $(STAGING_DIR)/usr/include/alsa \
68 $(STAGING_DIR)/usr/lib/libasound.{a,so}*
69 endef
70
71 $(eval $(call BuildPackage,alsa-lib))