You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

92 lines
2.6 KiB

  1. #
  2. # Copyright (C) 2008-2015 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=libshout
  9. PKG_VERSION:=2.3.1
  10. PKG_RELEASE:=3
  11. PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
  12. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  13. PKG_SOURCE_URL:=http://downloads.us.xiph.org/releases/libshout/
  14. PKG_MD5SUM:=11765b2592e7ea623ccd93d3f8df172c
  15. PKG_LICENSE:=LGPL-2.0+
  16. PKG_LICENSE_FILES:=COPYING
  17. PKG_MAINTAINER:=Nicolas Thill <nico@openwrt.org>
  18. PKG_FIXUP:=autoreconf
  19. PKG_INSTALL:=1
  20. include $(INCLUDE_DIR)/package.mk
  21. define Package/libshout/default
  22. SECTION:=libs
  23. CATEGORY:=Libraries
  24. TITLE:=Shoutcast client library
  25. URL:=http://www.icecast.org/download.php
  26. DEPENDS:= +libvorbis +libvorbisidec +libpthread
  27. endef
  28. define Package/libshout
  29. $(call Package/libshout/default)
  30. TITLE+= (no speex & theora)
  31. VARIANT:=nospeex
  32. endef
  33. define Package/libshout-full
  34. $(call Package/libshout/default)
  35. TITLE+= (all codecs)
  36. DEPENDS+= +libspeex +libtheora
  37. VARIANT:=full
  38. endef
  39. define Package/libshout/description
  40. libshout allows applications to easily communicate and broadcast
  41. to an Icecast streaming media server. It handles the socket connections,
  42. metadata communication, and data streaming for the calling application,
  43. and lets developers focus on feature sets instead of implementation
  44. details.
  45. endef
  46. Package/libshout-full/description=Package/libshout/description
  47. CONFIGURE_ARGS += \
  48. --enable-shared \
  49. --enable-static
  50. ifeq ($(BUILD_VARIANT),nospeex)
  51. CONFIGURE_ARGS += --disable-theora --disable-speex
  52. endif
  53. CONFIGURE_VARS += \
  54. VORBIS_CFLAGS="-I$(STAGING_DIR)/usr/include/tremor/" \
  55. VORBIS_LIBS="$(TARGET_LDFLAGS) -lvorbis -lvorbisidec" \
  56. TARGET_CFLAGS += $(FPIC) -Wl,-rpath-link="$(STAGING_DIR)/usr/lib"
  57. PACKAGE_CONFIG_FILE=shout$(if $(findstring $(BUILD_VARIANT),full),-full).pc
  58. define Build/InstallDev
  59. $(INSTALL_DIR) $(1)/usr/include
  60. $(CP) $(PKG_INSTALL_DIR)/usr/include/shout $(1)/usr/include/
  61. $(INSTALL_DIR) $(1)/usr/lib
  62. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libshout.{a,so*} $(1)/usr/lib/
  63. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  64. $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/shout.pc $(1)/usr/lib/pkgconfig/$(PACKAGE_CONFIG_FILE)
  65. $(SED) 's| -I/usr/include||' $(1)/usr/lib/pkgconfig/$(PACKAGE_CONFIG_FILE)
  66. endef
  67. define Package/libshout/install
  68. $(INSTALL_DIR) $(1)/usr/lib
  69. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libshout.so.* $(1)/usr/lib/
  70. endef
  71. Package/libshout-full/install=$(Package/libshout/install)
  72. $(eval $(call BuildPackage,libshout))
  73. $(eval $(call BuildPackage,libshout-full))