36288be8c4b36a1bba631c53b7959ddbf6042893
[openwrt/svn-archive/archive.git] / libs / flac / 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:=flac
12 PKG_VERSION:=1.1.2
13 PKG_RELEASE:=1
14
15 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
16 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
17 PKG_SOURCE_URL:=@SF/flac
18 PKG_MD5SUM:=2bfc127cdda02834d0491ab531a20960
19 PKG_CAT:=zcat
20
21 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
22
23 include $(INCLUDE_DIR)/package.mk
24
25 define Package/libflac
26 SECTION:=libs
27 CATEGORY:=Libraries
28 TITLE:=Free Lossless Audio Codec library
29 DESCRIPTION:=Free Lossless Audio Codec (FLAC) library.
30 URL:=ttp://flac.sourceforge.net/
31 endef
32
33 define Build/Configure
34 endef
35
36 define Build/Compile
37 rm -rf $(PKG_INSTALL_DIR)
38 mkdir -p $(PKG_INSTALL_DIR)
39 $(MAKE) -C $(PKG_BUILD_DIR) -f Makefile.lite \
40 $(TARGET_CONFIGURE_OPTS) \
41 RELEASE_CFLAGS="$(TARGET_CFLAGS)" \
42 libFLAC
43 endef
44
45 define Package/libflac/install
46 install -m0755 -d $(1)/usr/lib
47 $(CP) $(PKG_BUILD_DIR)/obj/release/lib/libFLAC.so $(1)/usr/lib/
48 endef
49
50 define Build/InstallDev
51 mkdir -p $(STAGING_DIR)/usr/include
52 $(CP) $(PKG_BUILD_DIR)/include/FLAC $(STAGING_DIR)/usr/include/
53 mkdir -p $(STAGING_DIR)/usr/lib
54 $(CP) $(PKG_BUILD_DIR)/obj/release/lib/libFLAC.{a,so} $(STAGING_DIR)/usr/lib/
55 endef
56
57 define Build/UninstallDev
58 rm -rf \
59 $(STAGING_DIR)/usr/include/FLAC \
60 $(STAGING_DIR)/usr/lib/libFLAC.{a,so}
61 endef
62
63 $(eval $(call BuildPackage,libflac))