b8a5f431467788653db346b1a4f8b5a28626b779
[openwrt/svn-archive/archive.git] / libs / speex / 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
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=speex
11 PKG_VERSION:=1.2beta3.2
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://downloads.us.xiph.org/releases/speex/
16 PKG_MD5SUM:=b47396952c5fdd54b6468316c3bd339f
17
18 PKG_BUILD_DEPENDS:=libnotimpl
19
20 include $(INCLUDE_DIR)/package.mk
21
22 define Package/libspeex
23 SECTION:=libs
24 CATEGORY:=Libraries
25 TITLE:=Open source speech compression codec library
26 URL:=http://www.speex.org/
27 endef
28
29 define Package/libspeexdsp
30 SECTION:=libs
31 CATEGORY:=Libraries
32 TITLE:=Open source speech compression codec library output to DSP
33 URL:=http://www.speex.org/
34 endef
35
36 define Package/libspeex/description
37 Open source patent-free speech compression codec library.
38 Speex is an Open Source/Free Software patent-free audio compression
39 format designed for speech. The Speex Project aims to lower the
40 barrier of entry for voice applications by providing a free
41 alternative to expensive proprietary speech codecs. Moreover, Speex
42 is well-adapted to Internet applications and provides useful features
43 that are not present in most other codecs.
44
45 This package contains the shared codec library, needed by other programs.
46 endef
47
48 TARGET_CFLAGS += $(FPIC)
49
50 define Package/libspeexdsp/description
51 Open source patent-free speech compression codec library.
52 Speex is an Open Source/Free Software patent-free audio compression
53 format designed for speech. The Speex Project aims to lower the
54 barrier of entry for voice applications by providing a free
55 alternative to expensive proprietary speech codecs. Moreover, Speex
56 is well-adapted to Internet applications and provides useful features
57 that are not present in most other codecs.
58
59 This package contains the shared dsp library, needed by other programs.
60 endef
61
62 TARGET_LDFLAGS:=$(TARGET_LDFLAGS) -lnotimpl
63
64 define Build/Configure
65 $(call Build/Configure/Default, \
66 --enable-shared \
67 --enable-static \
68 --enable-fixed-point \
69 --disable-oggtest \
70 --disable-float-api \
71 --disable-vbr, \
72 OGG_CFLAGS="" \
73 )
74 endef
75
76 define Build/Compile
77 $(MAKE) -C $(PKG_BUILD_DIR) \
78 DESTDIR="$(PKG_INSTALL_DIR)" \
79 bin_PROGRAMS="" \
80 all install
81 endef
82
83 define Build/InstallDev
84 $(INSTALL_DIR) $(1)/usr/include
85 $(CP) $(PKG_INSTALL_DIR)/usr/include/speex $(1)/usr/include/
86 $(INSTALL_DIR) $(1)/usr/lib
87 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libspeex.{a,so*} $(1)/usr/lib/
88 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libspeexdsp.{a,so*} $(1)/usr/lib/
89 $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
90 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/speex.pc $(1)/usr/lib/pkgconfig/
91 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/speexdsp.pc $(1)/usr/lib/pkgconfig/
92 endef
93
94 define Package/libspeex/install
95 $(INSTALL_DIR) $(1)/usr/lib
96 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libspeex.so.* $(1)/usr/lib/
97 endef
98
99 define Package/libspeexdsp/install
100 $(INSTALL_DIR) $(1)/usr/lib
101 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libspeexdsp.so.* $(1)/usr/lib/
102 endef
103
104 $(eval $(call BuildPackage,libspeex))
105 $(eval $(call BuildPackage,libspeexdsp))
106