aboutsummaryrefslogtreecommitdiffstats
path: root/multimedia
diff options
context:
space:
mode:
authoravilla <avilla@FreeBSD.org>2016-12-28 13:05:46 +0800
committeravilla <avilla@FreeBSD.org>2016-12-28 13:05:46 +0800
commit72d53cf8aa34d999ae0c19515eaa7c5a95d35930 (patch)
tree73ab59cb4b32099fedee911eb5dd4e739225055b /multimedia
parent09632820f4f75ab53cc06d716ae6786eeaad69c7 (diff)
downloadfreebsd-ports-gnome-72d53cf8aa34d999ae0c19515eaa7c5a95d35930.tar.gz
freebsd-ports-gnome-72d53cf8aa34d999ae0c19515eaa7c5a95d35930.tar.zst
freebsd-ports-gnome-72d53cf8aa34d999ae0c19515eaa7c5a95d35930.zip
- Split MLT Qt plugins into their own ports [1]
- Cleanup the Python slave port [2] - Bump PORTREVISION. [1] Ports can now force the dependency on Qt plugin, which is needed by Kdenlive. Having two different (conflicting) versions will help with the transition to the KF5-dependent Kdenlive. [2] Creating slave ports for other SWIG bindings should now be easy.
Diffstat (limited to 'multimedia')
-rw-r--r--multimedia/Makefile2
-rw-r--r--multimedia/mlt-qt4/Makefile21
-rw-r--r--multimedia/mlt-qt5/Makefile11
-rw-r--r--multimedia/mlt-qt5/pkg-plist10
-rw-r--r--multimedia/mlt/Makefile120
-rw-r--r--multimedia/mlt/pkg-plist10
-rw-r--r--multimedia/py-mlt/Makefile34
7 files changed, 124 insertions, 84 deletions
diff --git a/multimedia/Makefile b/multimedia/Makefile
index 6e057b23f44e..2d21d762d26b 100644
--- a/multimedia/Makefile
+++ b/multimedia/Makefile
@@ -244,6 +244,8 @@
SUBDIR += mkvtoolnix
SUBDIR += mkxvcd
SUBDIR += mlt
+ SUBDIR += mlt-qt4
+ SUBDIR += mlt-qt5
SUBDIR += mmpython
SUBDIR += mmsclient
SUBDIR += mmsrip
diff --git a/multimedia/mlt-qt4/Makefile b/multimedia/mlt-qt4/Makefile
new file mode 100644
index 000000000000..2285e4aaf3f6
--- /dev/null
+++ b/multimedia/mlt-qt4/Makefile
@@ -0,0 +1,21 @@
+# $FreeBSD$
+
+PORTREVISION= 0
+
+CONFLICTS_INSTALL= ${PORTNAME}-qt5-*
+
+USE_QT4= corelib gui opengl svg xml
+MASTERDIR= ${.CURDIR:H}/mlt
+SLAVEPORT= qt4
+
+PLIST= ${MASTERDIR}-qt5/pkg-plist
+
+OPTIONS_DEFINE= KDE4
+KDE4_DESC= Extra image formats
+
+KDE4_CONFIGURE_ENV= PATH="${KDE_PREFIX}/bin:$$PATH"
+KDE4_CONFIGURE_WITH= kde
+KDE4_USES= kde:4
+KDE4_USE= KDE=kdelibs
+
+.include "${MASTERDIR}/Makefile"
diff --git a/multimedia/mlt-qt5/Makefile b/multimedia/mlt-qt5/Makefile
new file mode 100644
index 000000000000..0a519b1cbbb5
--- /dev/null
+++ b/multimedia/mlt-qt5/Makefile
@@ -0,0 +1,11 @@
+# $FreeBSD$
+
+PORTREVISION= 0
+
+CONFLICTS_INSTALL= ${PORTNAME}-qt4-*
+
+USE_QT5= core gui svg widgets xml
+MASTERDIR= ${.CURDIR:H}/mlt
+SLAVEPORT= qt5
+
+.include "${MASTERDIR}/Makefile"
diff --git a/multimedia/mlt-qt5/pkg-plist b/multimedia/mlt-qt5/pkg-plist
new file mode 100644
index 000000000000..2aab5947b451
--- /dev/null
+++ b/multimedia/mlt-qt5/pkg-plist
@@ -0,0 +1,10 @@
+lib/mlt/libmltqt.so
+%%DATADIR%%/qt/filter_audiospectrum.yml
+%%DATADIR%%/qt/filter_audiowaveform.yml
+%%DATADIR%%/qt/filter_lightshow.yml
+%%DATADIR%%/qt/filter_qtblend.yml
+%%DATADIR%%/qt/producer_kdenlivetitle.yml
+%%DATADIR%%/qt/producer_qimage.yml
+%%DATADIR%%/qt/producer_qtext.yml
+%%DATADIR%%/qt/transition_qtblend.yml
+%%DATADIR%%/qt/transition_vqm.yml
diff --git a/multimedia/mlt/Makefile b/multimedia/mlt/Makefile
index 4619da22feab..96a50351aef9 100644
--- a/multimedia/mlt/Makefile
+++ b/multimedia/mlt/Makefile
@@ -2,7 +2,7 @@
PORTNAME= mlt
PORTVERSION= 6.4.1
-PORTREVISION?= 1
+PORTREVISION?= 2
CATEGORIES?= multimedia
MASTER_SITES= SF/${PORTNAME}/${PORTNAME}
@@ -12,9 +12,17 @@ COMMENT?= Multimedia framework for TV broadcasting
LICENSE?= GPLv2 GPLv3 LGPL21
LICENSE_COMB?= multi
-SLAVE_PORT?= no
+USES+= alias gmake pkgconfig
+GNU_CONFIGURE= yes
+CONFIGURE_ARGS+=--enable-gpl --enable-gpl3 --target-os=FreeBSD
+
+.ifndef(WITH_DEBUG)
+CONFIGURE_ARGS+=--disable-debug
+.else
+CONFIGURE_ARGS+=--enable-debug
+.endif
-.if ${SLAVE_PORT} == "no"
+.ifndef(SLAVEPORT) # Master port.
# They both install bin/melt.
CONFLICTS_INSTALL= freeze-[0-9]*
@@ -27,35 +35,22 @@ BROKEN_sparc64= does not compile on sparc64 (invokes i386 asm)
USE_GNOME= libxml2
USE_SDL= image
USE_XORG= x11
-USES= alias gmake iconv pathfix pkgconfig
+USES+= iconv pathfix
PATHFIX_MAKEFILEIN= Makefile
-GNU_CONFIGURE= yes
-CONFIGURE_ARGS= --enable-gpl --enable-gpl3 --target-os=FreeBSD
+CONFIGURE_ARGS+=--disable-qt --swig-languages=none
USE_LDCONFIG= yes
-.ifndef(WITH_DEBUG)
-CONFIGURE_ARGS+=--disable-debug
-.else
-CONFIGURE_ARGS+=--enable-debug
-.endif
-
PLIST_SUB= PORTVERSION="${PORTVERSION}"
PORTDOCS= AUTHORS ChangeLog NEWS README docs
PORTEXAMPLES= demo
-OPTIONS_DEFINE= DOCS EXAMPLES FFMPEG FREI0R GTK2 JACK KDE4 \
- OPENGL SAMPLERATE SOX SWFDEC VIDSTAB # OPENCV VDPAU
-OPTIONS_RADIO= QT
-OPTIONS_RADIO_QT= QT4 QT5
-OPTIONS_DEFAULT=FFMPEG FREI0R GTK2 OPENGL QT4 SAMPLERATE SOX \
- SWFDEC VIDSTAB
+OPTIONS_DEFINE= DOCS EXAMPLES FFMPEG FREI0R GTK2 JACK OPENGL \
+ SAMPLERATE SOX SWFDEC VIDSTAB # OPENCV VDPAU
+OPTIONS_DEFAULT=FFMPEG FREI0R GTK2 OPENGL SAMPLERATE SOX SWFDEC VIDSTAB
OPTIONS_SUB= yes
GTK2_DESC= Images and text rendering via GTK+ 2
-KDE4_DESC= Qt 4 extra image formats support
-QT4_DESC= Images and Kdenlive titles support via Qt 4
-QT5_DESC= ${QT4_DESC:S/4/5/}
SOX_DESC= SoX audio effects support
VIDSTAB_DESC= Video stabilization support via Vid.Stab
@@ -76,12 +71,6 @@ JACK_BUILD_DEPENDS= ${LOCALBASE}/include/ladspa.h:audio/ladspa
JACK_CONFIGURE_ENABLE= jackrack
JACK_USE= GNOME=glib20
-KDE4_CONFIGURE_ENV= PATH="${KDE_PREFIX}/bin:$$PATH"
-KDE4_CONFIGURE_WITH= kde
-KDE4_USES= kde:4
-KDE4_USE= KDE=kdelibs
-KDE4_IMPLIES= QT4
-
# Prepare for OpenCV 3 port.
CONFIGURE_ARGS+= --disable-opencv
OPENCV_CONFIGURE_ENABLE=opencv
@@ -90,10 +79,6 @@ OPENGL_LIB_DEPENDS= libmovit.so:graphics/movit
OPENGL_USE= GL=gl
OPENGL_CONFIGURE_ENABLE=opengl
-QT4_USE= QT4=corelib,gui,opengl,svg,xml
-QT5_USE= QT5=core,gui,svg,widgets,xml
-QT5_PREVENTS= KDE4
-
SAMPLERATE_LIB_DEPENDS= libsamplerate.so:audio/libsamplerate
SAMPLERATE_CONFIGURE_ENABLE=resample
@@ -112,19 +97,6 @@ VDPAU_CONFIGURE_OFF= --avformat-no-vdpau
VIDSTAB_LIB_DEPENDS= libvidstab.so:multimedia/vid.stab
VIDSTAB_CONFIGURE_ENABLE=vid.stab
-.include <bsd.port.options.mk>
-
-.if ${PORT_OPTIONS:MQT[45]}
-LIB_DEPENDS+= libexif.so:graphics/libexif
-CONFIGURE_ARGS+= --enable-qt \
- --qt-libdir="${QT_LIBDIR}" \
- --qt-includedir="${QT_INCDIR}"
-PLIST_SUB+= QT=""
-.else
-CONFIGURE_ARGS+= --disable-qt
-PLIST_SUB+= QT="@comment "
-.endif
-
pre-configure:
@${REINPLACE_CMD} -e 's,/usr/local,${LOCALBASE},' \
${WRKSRC}/src/modules/avformat/vdpau.c \
@@ -136,13 +108,12 @@ pre-configure:
${WRKSRC}/src/melt/Makefile \
${WRKSRC}/src/modules/*/Makefile
-post-install:
+common-post-install:
${INSTALL_MAN} ${WRKSRC}/docs/melt.1 ${STAGEDIR}${MANPREFIX}/man/man1/melt.1
@${RM} ${WRKSRC}/docs/melt.1
${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/melt
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libmlt.so.${PORTVERSION}
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libmlt++.so.${PORTVERSION}
- ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/mlt/*
post-install-DOCS-on:
.for f in ${PORTDOCS}
@@ -154,6 +125,61 @@ post-install-EXAMPLES-on:
cd ${WRKSRC} && ${COPYTREE_SHARE} ${f} ${STAGEDIR}${EXAMPLESDIR}
.endfor
-.endif # ${SLAVE_PORT} == "no"
+.else # Slave port.
+
+PORTSCOUT= ignore:1
+
+LIB_DEPENDS+= libmlt.so:${MASTER_PORT}
+
+PLIST?= ${.CURDIR}/pkg-plist
+
+. if ${SLAVEPORT:Mqt*} # Qt slave port.
+PKGNAMESUFFIX= -${SLAVEPORT}
+
+COMMENT= Qt ${SLAVEPORT:C/[^0-9]//g} plugin for the MLT multimedia framework
+
+LICENSE= GPLv2 GPLv3
+LICENSE_COMB= multi
+
+LIB_DEPENDS+= libexif.so:graphics/libexif
+
+CONFIGURE_ARGS+=--enable-qt \
+ --qt-libdir="${QT_LIBDIR}" \
+ --qt-includedir="${QT_INCDIR}"
+BUILD_WRKSRC= ${WRKSRC}/src/modules/qt
+. elif ${SLAVEPORT:Mswig} # SWIG slave port.
+LANGUAGE= ${SLAVEPORT:Nswig}
+
+COMMENT= ${LANGUAGE} bindings for the MLT multimedia framework
+
+LICENSE= LGPL21
+LICENSE_COMB= single
+
+BUILD_DEPENDS+= swig:devel/swig13
+
+_CFLAGS= -I${LOCALBASE}/include -L${LOCALBASE}/lib
+CFLAGS+= ${_CFLAGS}
+CXXFLAGS+= ${_CFLAGS}
+CONFIGURE_ARGS+=--swig-languages=${LANGUAGE:tl}
+BUILD_WRKSRC= ${WRKSRC}/src/swig
+INSTALL_WRKSRC= ${BUILD_WRKSRC}/${LANGUAGE:tl}
+
+EXAMPLESDIR= ${PREFIX}/share/examples/${PORTNAME}/${LANGUAGE:tl}
+. endif
+
+INSTALL_WRKSRC?=${BUILD_WRKSRC}
+
+pre-install:
+ ${MKDIR} ${STAGEDIR}${PREFIX}/lib/${PORTNAME}
+
+# Dummy placeholder target.
+common-post-install:
+ @${TRUE}
+
+.endif
+
+post-install: common-post-install
+ ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/${PORTNAME}/* 2>/dev/null || ${TRUE}
+ @${RMDIR} -p ${STAGEDIR}${PREFIX}/lib/${PORTNAME} 2>/dev/null || ${TRUE}
.include <bsd.port.mk>
diff --git a/multimedia/mlt/pkg-plist b/multimedia/mlt/pkg-plist
index d210faad939b..4cab4b8ac85f 100644
--- a/multimedia/mlt/pkg-plist
+++ b/multimedia/mlt/pkg-plist
@@ -72,7 +72,6 @@ lib/mlt/libmltoldfilm.so
%%OPENGL%%lib/mlt/libmltopengl.so
lib/mlt/libmltplus.so
lib/mlt/libmltplusgpl.so
-%%QT%%lib/mlt/libmltqt.so
%%SAMPLERATE%%lib/mlt/libmltresample.so
lib/mlt/libmltsdl.so
%%SOX%%lib/mlt/libmltsox.so
@@ -414,15 +413,6 @@ man/man1/melt.1.gz
%%DATADIR%%/profiles/uhd_2160p_60
%%DATADIR%%/profiles/vcd_ntsc
%%DATADIR%%/profiles/vcd_pal
-%%QT%%%%DATADIR%%/qt/filter_audiospectrum.yml
-%%QT%%%%DATADIR%%/qt/filter_audiowaveform.yml
-%%QT%%%%DATADIR%%/qt/filter_lightshow.yml
-%%QT%%%%DATADIR%%/qt/filter_qtblend.yml
-%%QT%%%%DATADIR%%/qt/producer_kdenlivetitle.yml
-%%QT%%%%DATADIR%%/qt/producer_qimage.yml
-%%QT%%%%DATADIR%%/qt/producer_qtext.yml
-%%QT%%%%DATADIR%%/qt/transition_qtblend.yml
-%%QT%%%%DATADIR%%/qt/transition_vqm.yml
%%SAMPLERATE%%%%DATADIR%%/resample/filter_resample.yml
%%DATADIR%%/sdl/consumer_sdl.yml
%%DATADIR%%/sdl/consumer_sdl_audio.yml
diff --git a/multimedia/py-mlt/Makefile b/multimedia/py-mlt/Makefile
index b6005251a3d3..0554430376f4 100644
--- a/multimedia/py-mlt/Makefile
+++ b/multimedia/py-mlt/Makefile
@@ -5,47 +5,27 @@ PORTREVISION= 0
CATEGORIES= multimedia python
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
-MAINTAINER= avilla@FreeBSD.org
-COMMENT= Python bindings for the MLT multimedia framework
-
-LICENSE= GPLv2
-LICENSE_COMB= single
-
-LIB_DEPENDS= libmlt.so:${MASTER_PORT}
-BUILD_DEPENDS= swig:devel/swig13 \
- python:lang/python
+BUILD_DEPENDS= python:lang/python
USES= python:2
-MASTERDIR= ${.CURDIR:H:H}/multimedia/mlt
+MASTERDIR= ${.CURDIR:H}/mlt
+SLAVEPORT= swig Python
-EXAMPLESDIR= ${PREFIX}/share/examples/${PORTNAME}/python
PORTEXAMPLES= *
-PLIST= ${.CURDIR}/pkg-plist
-
-BUILD_WRKSRC= ${WRKSRC}/src/swig/python
-INSTALL_WRKSRC= ${BUILD_WRKSRC}
-
OPTIONS_DEFINE= EXAMPLES
-.include <bsd.port.options.mk>
-
-post-patch:
- @${REINPLACE_CMD} -e 's|-L../../mlt++|-L${LOCALBASE}/lib|' \
- ${BUILD_WRKSRC}/build
-
-do-build:
- @cd ${BUILD_WRKSRC} && ${SETENV} ${MAKE_ENV} ${SH} build
-
do-install:
@${MKDIR} ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}
${INSTALL_LIB} ${INSTALL_WRKSRC}/_mlt.so ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}
${INSTALL_SCRIPT} ${INSTALL_WRKSRC}/mlt.py ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}
@cd ${STAGEDIR}${PYTHON_SITELIBDIR} && ${PYTHON_CMD} -c 'import mlt'
@cd ${STAGEDIR}${PYTHON_SITELIBDIR} && ${PYTHON_CMD} -Oc 'import mlt'
+
+post-install-EXAMPLES-on:
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
-. for f in codecs getimage play switcher waveforms webvfx_generator
+.for f in codecs getimage play switcher waveforms webvfx_generator
${INSTALL_DATA} ${INSTALL_WRKSRC}/${f}.py ${STAGEDIR}${EXAMPLESDIR}
-. endfor
+.endfor
.include "${MASTERDIR}/Makefile"