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.

142 lines
3.7 KiB

  1. #
  2. # This is free software, licensed under the GNU General Public License v2.
  3. # See /LICENSE for more information.
  4. #
  5. include $(TOPDIR)/rules.mk
  6. PKG_NAME:=squeezelite
  7. PKG_VERSION:=1.9.6-1210
  8. PKG_RELEASE:=2
  9. PKG_SOURCE_PROTO:=git
  10. PKG_SOURCE_URL:=https://github.com/ralph-irving/squeezelite
  11. PKG_SOURCE_VERSION:=1b7a17616cd2bbd9935c710dc33cda11cd0de45e
  12. PKG_MIRROR_HASH:=5993fa5fcacd1640962bc60f88a93faa4fcac74a767fbf820b40a27c338a9062
  13. PKG_MAINTAINER:=Ted Hess <thess@kitschensync.net>
  14. PKG_LICENSE:=GPL-3.0-or-later
  15. PKG_LICENSE_FILES:=LICENSE.txt
  16. PKG_BUILD_PARALLEL:=1
  17. include $(INCLUDE_DIR)/package.mk
  18. define Package/squeezelite/default
  19. SECTION:=sound
  20. CATEGORY:=Sound
  21. TITLE:=Headless squeezebox emulator
  22. PROVIDES:=squeezelite
  23. URL:=https://github.com/ralph-irving/squeezelite
  24. DEPENDS:= +alsa-lib +SQUEEZELITE_RESAMPLE:libsoxr
  25. MENU:=1
  26. endef
  27. define Package/squeezelite-full
  28. $(call Package/squeezelite/default)
  29. TITLE+= (full)
  30. DEPENDS+= +libflac +libvorbis +libmpg123 +libfaad2 \
  31. +SQUEEZELITE_WMA:libffmpeg-audio-dec
  32. VARIANT:=full
  33. endef
  34. define Package/squeezelite-mini
  35. $(call Package/squeezelite/default)
  36. TITLE+= (minimal)
  37. VARIANT:=mini
  38. endef
  39. define Package/squeezelite/config/default
  40. config SQUEEZELITE_WMA
  41. bool "WMA/ALAC decode support"
  42. help
  43. Include WMA and ALAC decoding using ffmpeg
  44. default n
  45. config SQUEEZELITE_RESAMPLE
  46. bool "Resample support"
  47. help
  48. Include support for resampling using libsoxr
  49. default n
  50. config SQUEEZELITE_DSD
  51. bool "DSD playback over PCM (DoP)"
  52. help
  53. Include support for DSD over PCM for compatible DAC"
  54. default n
  55. endef
  56. define Package/squeezelite-full/config
  57. if PACKAGE_squeezelite-full
  58. $(call Package/squeezelite/config/default)
  59. endif
  60. endef
  61. define Package/squeezelite-mini/config
  62. if PACKAGE_squeezelite-mini
  63. $(call Package/squeezelite/config/default)
  64. endif
  65. endef
  66. define Package/squeezelite/description/default
  67. Squeezelite is a small headless squeezebox emulator for linux using alsa audio output
  68. It is aimed at supporting high quality audio at multiple sample rates including
  69. 44.1/48/88.2/96/176.4/192k/352.8/384kHz
  70. Supported codecs: mp3, flac, ogg, aac, (wma and alac via ffmpeg)
  71. Native support for PCM builtin
  72. Optional support of DSD playback via PCM for DoP capable DAC
  73. Optional resampling to match sound device
  74. endef
  75. define Package/squeezelite-full/description
  76. $(call Package/squeezelite/description/default)
  77. This package has all the audio codecs compiled in.
  78. endef
  79. define Package/squeezelite-mini/description
  80. $(call Package/squeezelite/description/default)
  81. This package will dynamically load installed codecs.
  82. endef
  83. ifeq ($(CONFIG_SQUEEZELITE_WMA),y)
  84. opts+= -DFFMPEG
  85. endif
  86. ifeq ($(CONFIG_SQUEEZELITE_DSD),y)
  87. opts+= -DDSD
  88. endif
  89. ifeq ($(CONFIG_SQUEEZELITE_RESAMPLE),y)
  90. opts+= -DRESAMPLE
  91. endif
  92. ifeq ($(BUILD_VARIANT),full)
  93. opts+= -DLINKALL
  94. endif
  95. MAKE_FLAGS+=OPTS="$(opts)"
  96. define Package/squeezelite/conffiles
  97. /etc/config/squeezelite
  98. endef
  99. Package/squeezelite-mini/conffiles = $(Package/squeezelite/conffiles)
  100. Package/squeezelite-full/conffiles = $(Package/squeezelite/conffiles)
  101. define Package/squeezelite/install
  102. $(INSTALL_DIR) $(1)/usr/bin
  103. $(INSTALL_BIN) $(PKG_BUILD_DIR)/squeezelite $(1)/usr/bin
  104. $(INSTALL_DIR) $(1)/etc/init.d
  105. $(INSTALL_BIN) ./files/squeezelite.init $(1)/etc/init.d/squeezelite
  106. $(INSTALL_DIR) $(1)/etc/config
  107. $(INSTALL_CONF) ./files/squeezelite.conf $(1)/etc/config/squeezelite
  108. endef
  109. Package/squeezelite-mini/install=$(Package/squeezelite/install)
  110. Package/squeezelite-full/install=$(Package/squeezelite/install)
  111. $(eval $(call BuildPackage,squeezelite-mini))
  112. $(eval $(call BuildPackage,squeezelite-full))