Browse Source

gerbera: update to 1.5.0

This is a fairly massive update that adds new dependencies.

Switched the CMAKE_OPTIONS to use ON/OFF as is done elsewhere.

Added a patch fixing compilation with libiconv-stub/full.

Add a small debug option to write to syslog debug information.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
lilik-openwrt-22.03
Rosen Penev 5 years ago
parent
commit
2e4d2d36c2
No known key found for this signature in database GPG Key ID: 36D31CFA845F0E3B
4 changed files with 45 additions and 18 deletions
  1. +20
    -18
      multimedia/gerbera/Makefile
  2. +1
    -0
      multimedia/gerbera/files/gerbera.config
  3. +3
    -0
      multimedia/gerbera/files/gerbera.init
  4. +21
    -0
      multimedia/gerbera/patches/010-iconv.patch

+ 20
- 18
multimedia/gerbera/Makefile View File

@ -8,12 +8,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=gerbera
PKG_VERSION:=1.4.0
PKG_VERSION:=1.5.0
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://codeload.github.com/gerbera/gerbera/tar.gz/v$(PKG_VERSION)?
PKG_HASH:=904a9031c85ac805e4c139f363510226952683d7257acd1dee25ba1e97fd7651
PKG_HASH:=693a99b295bc79d842f036a6d04996d4676ac0791d65f3a1f7aab4badf9fb5ef
PKG_MAINTAINER:=
PKG_LICENSE:=GPL-2.0-or-later
@ -28,7 +28,7 @@ include $(INCLUDE_DIR)/nls.mk
define Package/gerbera
SECTION:=multimedia
CATEGORY:=Multimedia
DEPENDS:=+file +libupnp +libsqlite3 +libexif +libexpat +libuuid +libstdcpp $(ICONV_DEPENDS)
DEPENDS:=+file +libupnp +libsqlite3 +libexif +libuuid +pugixml +spdlog $(ICONV_DEPENDS)
TITLE:=A free media server
URL:=https://gerbera.io
USERID:=gerbera:gerbera
@ -43,23 +43,25 @@ define Package/gerbera/conffiles
endef
CMAKE_OPTIONS += \
-DCXX_FILESYSTEM_NO_LINK_NEEDED=$(if $(CONFIG_GCC_USE_VERSION_9),ON,OFF) \
-DCXX_FILESYSTEM_STDCPPFS_NEEDED=$(if $(CONFIG_GCC_USE_VERSION_8),OFF,ON) \
-DICONV_INCLUDE_DIR=$(ICONV_PREFIX)/include \
-DICONV_LIBRARIES=$(ICONV_PREFIX)/lib/libiconv.a \
-DWITH_MAGIC=1 \
-DWITH_MYSQL=0 \
-DWITH_CURL=0 \
-DWITH_INOTIFY=1 \
-DWITH_JS=0 \
-DWITH_TAGLIB=0 \
-DWITH_AVCODEC=0 \
-DWITH_FFMPEGTHUMBNAILER=0 \
-DWITH_EXIF=1 \
-DWITH_EXIV2=0 \
-DWITH_MATROSKA=0 \
-DWITH_SYSTEMD=0 \
-DWITH_LASTFM=0 \
-DWITH_DEBUG=0 \
-DWITH_TESTS=0
-DWITH_MAGIC=ON \
-DWITH_MYSQL=OFF \
-DWITH_CURL=OFF \
-DWITH_INOTIFY=ON \
-DWITH_JS=OFF \
-DWITH_TAGLIB=OFF \
-DWITH_AVCODEC=OFF \
-DWITH_FFMPEGTHUMBNAILER=OFF \
-DWITH_EXIF=ON \
-DWITH_EXIV2=OFF \
-DWITH_MATROSKA=OFF \
-DWITH_SYSTEMD=OFF \
-DWITH_LASTFM=OFF \
-DWITH_DEBUG=OFF \
-DWITH_TESTS=OFF
TARGET_CFLAGS += -ffunction-sections -fdata-sections -flto
TARGET_LDFLAGS += -Wl,--gc-sections,--as-needed


+ 1
- 0
multimedia/gerbera/files/gerbera.config View File

@ -1,3 +1,4 @@
config gerbera config
option enabled '0'
option debug '0'
option home '/tmp/gerbera'

+ 3
- 0
multimedia/gerbera/files/gerbera.init View File

@ -7,10 +7,12 @@ PROG=/usr/bin/gerbera
start_service() {
local enabled
local debug
local home
config_load 'gerbera'
config_get_bool enabled config 'enabled' '0'
config_get_bool debug config 'debug' '0'
[ "$enabled" -eq 0 ] && {
echo "Gerbera not enabled. Please enable in /etc/config/gerbera"
@ -33,6 +35,7 @@ start_service() {
procd_set_param user gerbera
procd_set_param group gerbera
procd_set_param command "$PROG" -c "$home/config.xml"
procd_set_param stdout "$debug"
procd_set_param stderr 1
procd_close_instance
}

+ 21
- 0
multimedia/gerbera/patches/010-iconv.patch View File

@ -0,0 +1,21 @@
--- a/src/util/string_converter.cc
+++ b/src/util/string_converter.cc
@@ -41,15 +41,15 @@ StringConverter::StringConverter(const std::string& from, const std::string& to)
dirty = false;
cd = iconv_open(to.c_str(), from.c_str());
- if (cd == reinterpret_cast<iconv_t>(-1)) {
- cd = static_cast<iconv_t>(nullptr);
+ if (cd == (iconv_t)(-1)) {
+ cd = (iconv_t)(nullptr);
throw_std_runtime_error(std::string("iconv: ") + strerror(errno));
}
}
StringConverter::~StringConverter()
{
- if (cd != static_cast<iconv_t>(nullptr))
+ if (cd != (iconv_t)(nullptr))
iconv_close(cd);
}

Loading…
Cancel
Save