86116e4f25
minidlna will detect and use the libiconv library if the package is selected. In that case, we need to link against -liconv. Fixes the following linking problem: tagutils/tagutils.o: In function `do_iconv.constprop.6': tagutils.c:(.text+0x4d5c): undefined reference to `libiconv_open' tagutils.c:(.text+0x4da0): undefined reference to `libiconv' tagutils.c:(.text+0x4e08): undefined reference to `libiconv_close' [Peter: wrap COMMON_LIBS line] Signed-off-by: Markos Chandras <markos.chandras@imgtec.com> Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
61 lines
1.7 KiB
Makefile
61 lines
1.7 KiB
Makefile
################################################################################
|
|
#
|
|
# minidlna
|
|
#
|
|
################################################################################
|
|
|
|
MINIDLNA_VERSION = 1.0.25
|
|
MINIDLNA_SITE = http://downloads.sourceforge.net/project/minidlna/minidlna/$(MINIDLNA_VERSION)
|
|
MINIDLNA_SOURCE = minidlna_$(MINIDLNA_VERSION)_src.tar.gz
|
|
MINIDLNA_LICENSE = GPLv2 BSD-3c
|
|
MINIDLNA_LICENSE_FILES = LICENCE LICENCE.miniupnpd
|
|
|
|
MINIDLNA_DEPENDENCIES = \
|
|
ffmpeg flac libvorbis libogg libid3tag libexif libjpeg sqlite \
|
|
host-xutil_makedepend
|
|
|
|
MINIDLNA_CFLAGS=$(TARGET_CFLAGS) \
|
|
-I"$(STAGING_DIR)/usr/include/libavutil" \
|
|
-I"$(STAGING_DIR)/usr/include/libavcodec" \
|
|
-I"$(STAGING_DIR)/usr/include/libavformat"
|
|
|
|
MINIDLNA_COMMON_LIBS = \
|
|
-lpthread -lexif -ljpeg -lsqlite3 -lavformat -lavutil -lavcodec \
|
|
-lid3tag -lFLAC -logg -lvorbis
|
|
|
|
ifeq ($(BR2_PACKAGE_GETTEXT),y)
|
|
MINIDLNA_DEPENDENCIES += gettext
|
|
# we need to link with libintl
|
|
MINIDLNA_COMMON_LIBS += -lintl
|
|
endif
|
|
|
|
ifeq ($(BR2_PACKAGE_LIBICONV),y)
|
|
MINIDLNA_DEPENDENCIES += libiconv
|
|
MINIDLNA_COMMON_LIBS += -liconv
|
|
endif
|
|
|
|
MINIDLNA_MAKE_OPTS += LIBS='$(MINIDLNA_COMMON_LIBS)'
|
|
|
|
define MINIDLNA_BUILD_CMDS
|
|
PREFIX=$(STAGING_DIR)/usr \
|
|
$(TARGET_MAKE_ENV) $(MAKE) $(TARGET_CONFIGURE_OPTS) \
|
|
CFLAGS="$(MINIDLNA_CFLAGS)" -C $(@D) depend
|
|
$(TARGET_MAKE_ENV) $(MAKE) $(TARGET_CONFIGURE_OPTS) \
|
|
CFLAGS="$(MINIDLNA_CFLAGS)" $(MINIDLNA_MAKE_OPTS) -C $(@D) all
|
|
endef
|
|
|
|
define MINIDLNA_INSTALL_TARGET_CMDS
|
|
$(TARGET_MAKE_ENV) $(MAKE) $(TARGET_CONFIGURE_OPTS) \
|
|
-C $(@D) DESTDIR=$(TARGET_DIR) install
|
|
endef
|
|
|
|
define MINIDLNA_UNINSTALL_TARGET_CMDS
|
|
$(RM) $(TARGET_DIR)/usr/sbin/minidlna
|
|
endef
|
|
|
|
define MINIDLNA_CLEAN_CMDS
|
|
$(TARGET_MAKE_ENV) $(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D) clean
|
|
endef
|
|
|
|
$(eval $(generic-package))
|