add portaudio, a portable cross-platform audio I/O library
authorNicolas Thill <nico@openwrt.org>
Sat, 25 Oct 2014 07:34:59 +0000 (09:34 +0200)
committerNicolas Thill <nico@openwrt.org>
Sat, 25 Oct 2014 07:40:56 +0000 (09:40 +0200)
Signed-off-by: Nicolas Thill <nico@openwrt.org>
sound/portaudio/Makefile [new file with mode: 0644]

diff --git a/sound/portaudio/Makefile b/sound/portaudio/Makefile
new file mode 100644 (file)
index 0000000..ffa5cfb
--- /dev/null
@@ -0,0 +1,70 @@
+#
+# Copyright (C) 2014 OpenWrt.org
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=portaudio
+PKG_VERSION:=19_20140130
+PKG_RELEASE:=1
+
+PKG_SOURCE:=pa_stable_v$(PKG_VERSION).tgz
+PKG_SOURCE_URL:=http://www.portaudio.com/archives/
+PKG_MD5SUM:=7f220406902af9dca009668e198cbd23
+
+PKG_LICENSE:=MIT
+PKG_LICENSE_FILES:=LICENSE.txt
+PKG_MAINTAINER:=Nicolas Thill <nico@openwrt.org>
+
+PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)
+PKG_INSTALL:=1
+
+include $(INCLUDE_DIR)/package.mk
+
+define Package/portaudio
+  SECTION:=sound
+  CATEGORY:=Sound
+  DEPENDS:=+alsa-lib +libpthread +librt
+  TITLE:=Portable cross-platform audio I/O
+  URL:=http://www.portaudio.com/
+endef
+
+define Package/portaudio/description
+ PortAudio is a free, cross-platform, open-source, audio I/O library.  It lets
+ you write simple audio programs in 'C' or C++ that will compile and run on many
+ platforms including Windows, Macintosh OS X, and Unix (OSS/ALSA). It is
+ intended to promote the exchange of audio software between developers on
+ different platforms. Many applications use PortAudio for Audio I/O.
+endef
+
+CONFIGURE_ARGS+= \
+       --with-alsa \
+       --without-asihpi \
+       --without-jack \
+       --with-oss \
+
+define Build/InstallDev
+       $(INSTALL_DIR) $(1)/usr/include
+       $(CP) \
+               $(PKG_INSTALL_DIR)/usr/include/portaudio.h \
+               $(PKG_INSTALL_DIR)/usr/include/pa_linux_alsa.h \
+               $(1)/usr/include/
+       $(INSTALL_DIR) $(1)/usr/lib
+       $(CP) \
+               $(PKG_INSTALL_DIR)/usr/lib/libportaudio.{a,so*} \
+               $(1)/usr/lib/
+       $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
+       $(CP) \
+               $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/portaudio-*.pc \
+               $(1)/usr/lib/pkgconfig/
+endef
+
+define Package/portaudio/install
+       $(INSTALL_DIR) $(1)/usr/lib
+       $(CP) $(PKG_INSTALL_DIR)/usr/lib/libportaudio.so.* $(1)/usr/lib/
+endef
+
+$(eval $(call BuildPackage,portaudio))