minidlna: update to 1.3.0 14079/head
authorRosen Penev <rosenp@gmail.com>
Sun, 29 Nov 2020 23:58:20 +0000 (15:58 -0800)
committerRosen Penev <rosenp@gmail.com>
Mon, 30 Nov 2020 00:14:36 +0000 (16:14 -0800)
Fixes two CVEs relating to UPnP.

Removed libuuid dependency. It is not used.

Remove clock_gettime hack. It seems to have been fixed.

Removed upstream patches.

Refreshed the other ones.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
multimedia/minidlna/Makefile
multimedia/minidlna/patches/001-dont-build-po-files.patch
multimedia/minidlna/patches/005-added-support-RMVB.patch
multimedia/minidlna/patches/010-lg.patch [deleted file]
multimedia/minidlna/patches/020-wrap_container_definitions_into_a_structure.patch
multimedia/minidlna/patches/030-mark_all_instances_of_magic_container_s_as_const.patch
multimedia/minidlna/patches/040-heroes.patch
multimedia/minidlna/patches/070-return-void.patch
multimedia/minidlna/patches/999-05-fix-setjmp-buffer-multiple-def.patch [deleted file]

index 56581a37bbd8293c56f27b2a29dc745023d125ea..25db032b507edd196761b23964c64c831850a4a7 100644 (file)
@@ -8,13 +8,12 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=minidlna
-PKG_RELEASE:=8
+PKG_VERSION:=1.3.0
+PKG_RELEASE:=1
 
-PKG_SOURCE_PROTO:=git
-PKG_SOURCE_URL:=https://git.code.sf.net/p/minidlna/git
-PKG_SOURCE_DATE:=2019-12-09
-PKG_SOURCE_VERSION:=0763719f2776f91114bc5564919896f28e078c77
-PKG_MIRROR_HASH:=93030a80eff44c0ec13f54daf3b2ba345b70ef8645e0343a34092f37d6f9e8dd
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
+PKG_SOURCE_URL:=@SF/minidlna
+PKG_HASH:=47d9b06b4c48801a4c1112ec23d24782728b5495e95ec2195bbe5c81bc2d3c63
 
 PKG_MAINTAINER:=
 PKG_LICENSE:=GPL-2.0-or-later BSD-3-Clause
@@ -23,7 +22,6 @@ PKG_LICENSE_FILES:=COPYING LICENCE.miniupnpd
 PKG_FIXUP:=autoreconf
 PKG_INSTALL:=1
 PKG_BUILD_PARALLEL:=1
-PKG_BUILD_DEPENDS:=util-linux
 
 include $(INCLUDE_DIR)/package.mk
 include $(INCLUDE_DIR)/nls.mk
@@ -34,8 +32,7 @@ define Package/minidlna
   TITLE:=UPnP A/V & DLNA Media Server
   URL:=http://minidlna.sourceforge.net/
   DEPENDS:= +libpthread +libexif +libjpeg +libsqlite3 +libffmpeg \
-       +libid3tag +libflac +libvorbis +libuuid \
-       $(ICONV_DEPENDS) $(INTL_DEPENDS)
+       +libid3tag +libflac +libvorbis $(ICONV_DEPENDS) $(INTL_DEPENDS)
   USERID:=minidlna:minidlna
 endef
 
@@ -57,8 +54,6 @@ CONFIGURE_ARGS += \
        --with-db-path="/var/run/minidlna" \
        --with-log-path="/var/log"
 
-TARGET_CFLAGS += -DHAVE_CLOCK_GETTIME
-
 define Package/minidlna/install
        $(INSTALL_DIR) $(1)/usr/sbin
        $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/minidlnad $(1)/usr/sbin/minidlnad
index 7d9f6b6373d740db9cc68ca3ec47b3a23cc07d8f..f16514cbbf3c660353b2f11eeb2db1fd43b841fe 100644 (file)
@@ -2,7 +2,7 @@
 +++ b/Makefile.am
 @@ -17,7 +17,7 @@
  
- AM_CFLAGS = -Wall -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 @STATIC_CFLAGS@
+ AM_CFLAGS = -Wall -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
  
 -SUBDIRS=po
 +SUBDIRS=
  check_PROGRAMS = testupnpdescgen
 --- a/configure.ac
 +++ b/configure.ac
-@@ -647,6 +647,8 @@ case "$target_os" in
+@@ -658,6 +658,5 @@ case "$target_os" in
  esac
  
  
 -AC_OUTPUT([ po/Makefile.in
 -Makefile
 -])
-+# AC_OUTPUT([ po/Makefile.in
-+# Makefile
-+# ])
 +AC_CONFIG_FILES([Makefile])
 +AC_OUTPUT
index 86f6505182eb4f3a653670c96e311b4291998573..ddf354f2d4053dde7d566249d84b4e1045b72829 100644 (file)
@@ -9,11 +9,9 @@ Subject: [PATCH] Added support RMVB.
  utils.c          | 3 +++
  3 files changed, 9 insertions(+), 1 deletion(-)
 
-diff --git a/metadata.c b/metadata.c
-index 9cd86dc..2d13480 100644
 --- a/metadata.c
 +++ b/metadata.c
-@@ -862,6 +862,10 @@ GetVideoMetadata(const char *path, const char *name)
+@@ -862,6 +862,10 @@ GetVideoMetadata(const char *path, const
                        xasprintf(&m.mime, "video/x-matroska");
                else if( strcmp(ctx->iformat->name, "flv") == 0 )
                        xasprintf(&m.mime, "video/x-flv");
@@ -24,8 +22,6 @@ index 9cd86dc..2d13480 100644
                if( m.mime )
                        goto video_no_dlna;
  
-diff --git a/upnpglobalvars.h b/upnpglobalvars.h
-index 1a2fb5e..2cbe24c 100644
 --- a/upnpglobalvars.h
 +++ b/upnpglobalvars.h
 @@ -172,7 +172,8 @@
@@ -38,8 +34,6 @@ index 1a2fb5e..2cbe24c 100644
  
  #define DLNA_FLAG_DLNA_V1_5      0x00100000
  #define DLNA_FLAG_HTTP_STALLING  0x00200000
-diff --git a/utils.c b/utils.c
-index dc936f9..006f611 100644
 --- a/utils.c
 +++ b/utils.c
 @@ -377,6 +377,8 @@ mime_to_ext(const char * mime)
@@ -59,6 +53,3 @@ index dc936f9..006f611 100644
  #ifdef TIVO_SUPPORT
                ends_with(file, ".TiVo") ||
  #endif
--- 
-2.20.1
-
diff --git a/multimedia/minidlna/patches/010-lg.patch b/multimedia/minidlna/patches/010-lg.patch
deleted file mode 100644 (file)
index 1fb48b1..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-From eb473817d73b8740f27955f93950029fdfc9d73e Mon Sep 17 00:00:00 2001
-From: Daniel Kamil Kozar <dkk089@gmail.com>
-Date: Sat, 15 Dec 2018 00:55:20 +0100
-Subject: [PATCH] LG webOS 3.5 devices require audio/flac in order to detect
- FLAC
-
-Imported from https://sourceforge.net/p/minidlna/patches/176/
----
- clients.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/clients.c b/clients.c
-index 42f0d1c..d324eab 100644
---- a/clients.c
-+++ b/clients.c
-@@ -164,7 +164,7 @@ struct client_type_s client_types[] =
-       /* USER-AGENT: Linux/2.6.35 UPnP/1.0 DLNADOC/1.50 INTEL_NMPR/2.0 LGE_DLNA_SDK/1.6.0 */
-       { ELGNetCastDevice,
--        FLAG_DLNA | FLAG_CAPTION_RES,
-+        FLAG_DLNA | FLAG_CAPTION_RES | FLAG_MIME_FLAC_FLAC,
-         "LG",
-         "LGE_DLNA_SDK/1.6.0",
-         EUserAgent
index 4733b32fe242b0de79ea587267bb27f270eb142a..859e9f437e7b1fc7c937e4493501ad5ef705d901 100644 (file)
@@ -9,8 +9,6 @@ Subject: [PATCH] Wrap container definitions into a structure
  scanner.c    | 33 ++++++---------------------------
  3 files changed, 39 insertions(+), 27 deletions(-)
 
-diff --git a/containers.c b/containers.c
-index f5cece1..19a0bb1 100644
 --- a/containers.c
 +++ b/containers.c
 @@ -23,6 +23,31 @@
@@ -45,8 +43,6 @@ index f5cece1..19a0bb1 100644
  #define NINETY_DAYS "7776000"
  
  const char *music_id = MUSIC_ID;
-diff --git a/containers.h b/containers.h
-index aef77c5..1fcf7cd 100644
 --- a/containers.h
 +++ b/containers.h
 @@ -16,6 +16,14 @@
@@ -64,11 +60,9 @@ index aef77c5..1fcf7cd 100644
  struct magic_container_s {
        const char *name;
        const char *objectid_match;
-diff --git a/scanner.c b/scanner.c
-index a730567..eb26c9e 100644
 --- a/scanner.c
 +++ b/scanner.c
-@@ -529,30 +529,7 @@ insert_file(const char *name, const char *path, const char *parentID, int object
+@@ -529,30 +529,7 @@ insert_file(const char *name, const char
  int
  CreateDatabase(void)
  {
index 44a27665bd2a9ea50ed290653bb928ccae14dfb8..84a818835a29cc3c17c31514cedf58f9cf304327 100644 (file)
@@ -12,7 +12,7 @@ Subject: [PATCH] Mark all instances of magic_container_s as const
 
 --- a/containers.c
 +++ b/containers.c
-@@ -50,23 +50,23 @@
+@@ -50,23 +50,23 @@ const struct container_s containers[] =
  
  #define NINETY_DAYS "7776000"
  
@@ -96,7 +96,7 @@ Subject: [PATCH] Mark all instances of magic_container_s as const
                if( sql_get_int_field(db, "SELECT 1 from OBJECTS where OBJECT_ID = '%s'", magic->objectid_match) == 0 )
 --- a/upnpsoap.c
 +++ b/upnpsoap.c
-@@ -800,7 +800,7 @@ add_res(char *size, char *duration, char
+@@ -804,7 +804,7 @@ add_res(char *size, char *duration, char
  }
  
  static int
@@ -105,7 +105,7 @@ Subject: [PATCH] Mark all instances of magic_container_s as const
  {
        int ret;
  
-@@ -1297,7 +1297,7 @@ BrowseContentDirectory(struct upnphttp *
+@@ -1301,7 +1301,7 @@ BrowseContentDirectory(struct upnphttp *
                        "<Result>"
                        "&lt;DIDL-Lite"
                        CONTENT_DIRECTORY_SCHEMAS;
@@ -114,7 +114,7 @@ Subject: [PATCH] Mark all instances of magic_container_s as const
        char *zErrMsg = NULL;
        char *sql, *ptr;
        struct Response args;
-@@ -1819,7 +1819,7 @@ SearchContentDirectory(struct upnphttp *
+@@ -1823,7 +1823,7 @@ SearchContentDirectory(struct upnphttp *
                        "<Result>"
                        "&lt;DIDL-Lite"
                        CONTENT_DIRECTORY_SCHEMAS;
index 5c2d3139638202fd73cacaef21544691348b3f42..74a3e249a4f999a0d0de61695b4cd0a666b08d7f 100644 (file)
@@ -7,8 +7,6 @@ Subject: [PATCH] What about David Bowie's "Heroes"?
  utils.c | 7 -------
  1 file changed, 7 deletions(-)
 
-diff --git a/utils.c b/utils.c
-index dc936f9..dfa2b65 100644
 --- a/utils.c
 +++ b/utils.c
 @@ -87,13 +87,6 @@ trim(char *str)
index 7109dd94ec41d7643f6f786910be6f16f1a259bb..ec0e6d3736fed8d912ce4225dc9dc3031b780dc9 100644 (file)
@@ -7,11 +7,9 @@ Subject: [PATCH] No return in a function returning non-void
  upnpdescgen.c | 1 +
  1 file changed, 1 insertion(+)
 
-diff --git a/upnpdescgen.c b/upnpdescgen.c
-index 85ce185..78d5754 100644
 --- a/upnpdescgen.c
 +++ b/upnpdescgen.c
-@@ -525,6 +525,7 @@ genXML(char *str, int *len, int *tmplen, const struct XMLElt *p)
+@@ -525,6 +525,7 @@ genXML(char * str, int * len, int * tmpl
                        pile[top].eltname = eltname;
                }
        }
diff --git a/multimedia/minidlna/patches/999-05-fix-setjmp-buffer-multiple-def.patch b/multimedia/minidlna/patches/999-05-fix-setjmp-buffer-multiple-def.patch
deleted file mode 100644 (file)
index a4a2137..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
---- a/image_utils.c
-+++ b/image_utils.c
-@@ -190,7 +190,7 @@ jpeg_memory_src(j_decompress_ptr cinfo,
-       src->pub.bytes_in_buffer = bufsize;
- }
--jmp_buf setjmp_buffer;
-+static jmp_buf setjmp_buffer;
- /* Don't exit on error like libjpeg likes to do */
- static void
- libjpeg_error_handler(j_common_ptr cinfo)
---- a/metadata.c
-+++ b/metadata.c
-@@ -502,7 +502,7 @@ GetAudioMetadata(const char *path, const
- }
- /* For libjpeg error handling */
--jmp_buf setjmp_buffer;
-+static jmp_buf setjmp_buffer;
- static void
- libjpeg_error_handler(j_common_ptr cinfo)
- {