diff --git a/x11-packages/kid3/build.sh b/x11-packages/kid3/build.sh new file mode 100644 index 000000000..5a57b0cbf --- /dev/null +++ b/x11-packages/kid3/build.sh @@ -0,0 +1,29 @@ +TERMUX_PKG_HOMEPAGE=https://kid3.kde.org/ +TERMUX_PKG_DESCRIPTION="Efficient ID3 tag editor" +TERMUX_PKG_LICENSE="GPL-2.0" +TERMUX_PKG_MAINTAINER="@termux" +TERMUX_PKG_VERSION=3.9.1 +TERMUX_PKG_SRCURL=https://downloads.sourceforge.net/kid3/kid3-${TERMUX_PKG_VERSION}.tar.gz +TERMUX_PKG_SHA256=e5f126697f773dbaa10476a76810ce91c2f3f60025d38688098e075bdb561dca +TERMUX_PKG_DEPENDS="chromaprint, ffmpeg, id3lib, libc++, libflac, libogg, libvorbis, qt5-qtbase, qt5-qtdeclarative, qt5-qtmultimedia, readline, taglib" +TERMUX_PKG_BUILD_DEPENDS="docbook-xsl, qt5-qtbase-cross-tools, qt5-qtdeclarative-cross-tools, qt5-qttools-cross-tools" +TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" +-DANDROID_NO_TERMUX=OFF +-DWITH_APPS=Qt;CLI +-DWITH_FFMPEG=ON +" + +termux_step_post_get_source() { + # I don't want to make a patch for this: + find . -name CMakeLists.txt -o -name '*.cmake' | \ + xargs -n 1 sed -i \ + -e 's/\([^A-Za-z0-9_]ANDROID\)\([^A-Za-z0-9_]\)/\1_NO_TERMUX\2/g' \ + -e 's/\([^A-Za-z0-9_]ANDROID\)$/\1_NO_TERMUX/g' +} + +termux_step_pre_configure() { + local DOCBOOK_XSL_VER=$(bash -c ". $TERMUX_SCRIPTDIR/packages/docbook-xsl/build.sh; echo \$TERMUX_PKG_VERSION") + TERMUX_PKG_EXTRA_CONFIGURE_ARGS+=" -DWITH_DOCBOOKDIR=$TERMUX_PREFIX/share/xml/docbook/xsl-stylesheets-${DOCBOOK_XSL_VER}" + + LDFLAGS+=" -Wl,-rpath=$TERMUX_PREFIX/lib/kid3" +} diff --git a/x11-packages/kid3/src-core-model-kid3application.cpp.patch b/x11-packages/kid3/src-core-model-kid3application.cpp.patch new file mode 100644 index 000000000..3335713e2 --- /dev/null +++ b/x11-packages/kid3/src-core-model-kid3application.cpp.patch @@ -0,0 +1,11 @@ +--- a/src/core/model/kid3application.cpp ++++ b/src/core/model/kid3application.cpp +@@ -928,7 +928,7 @@ + taggedFile->closeFileHandle(); + } + } +-#if defined Q_OS_LINUX && !defined Q_OS_ANDROID ++#if defined Q_OS_LINUX && !defined Q_OS_ANDROID && !defined __ANDROID__ + if (::malloc_trim(0)) { + qDebug("Memory released by malloc_trim()"); + } diff --git a/x11-packages/kid3/src-plugins-acoustidimport-ffmpegfingerprintdecoder.cpp.patch b/x11-packages/kid3/src-plugins-acoustidimport-ffmpegfingerprintdecoder.cpp.patch new file mode 100644 index 000000000..c78f7e561 --- /dev/null +++ b/x11-packages/kid3/src-plugins-acoustidimport-ffmpegfingerprintdecoder.cpp.patch @@ -0,0 +1,11 @@ +--- a/src/plugins/acoustidimport/ffmpegfingerprintdecoder.cpp ++++ b/src/plugins/acoustidimport/ffmpegfingerprintdecoder.cpp +@@ -232,7 +232,7 @@ + friend class Format; + friend class Converter; + AVCodecContext* m_ptr; +- AVCodec* m_impl; ++ const AVCodec* m_impl; + AVFrame* m_frame; + bool m_opened; + };