libmtp: allow build with gettext-0.24.1

ref: https://sourceforge.net/p/libmtp/code/merge-requests/10/
This commit is contained in:
Rudi Heitbaum 2025-05-04 03:52:25 +00:00
parent 3bba622b11
commit 9303ffb49c
2 changed files with 128 additions and 1 deletions

View File

@ -7,7 +7,7 @@ PKG_SHA256="c3fcf411aea9cb9643590cbc9df99fa5fe30adcac695024442973d76fa5f87bc"
PKG_LICENSE="GPL" PKG_LICENSE="GPL"
PKG_SITE="http://libmtp.sourceforge.net/" PKG_SITE="http://libmtp.sourceforge.net/"
PKG_URL="${SOURCEFORGE_SRC}/project/${PKG_NAME}/${PKG_NAME}/${PKG_VERSION}/${PKG_NAME}-${PKG_VERSION}.tar.gz" PKG_URL="${SOURCEFORGE_SRC}/project/${PKG_NAME}/${PKG_NAME}/${PKG_VERSION}/${PKG_NAME}-${PKG_VERSION}.tar.gz"
PKG_DEPENDS_TARGET="toolchain libusb" PKG_DEPENDS_TARGET="toolchain libusb gettext"
PKG_LONGDESC="An Initiator implementation of the Media Transfer Protocol (MTP)." PKG_LONGDESC="An Initiator implementation of the Media Transfer Protocol (MTP)."
PKG_TOOLCHAIN="autotools" PKG_TOOLCHAIN="autotools"

View File

@ -0,0 +1,127 @@
From 5e53ee68e61cc6547476b942b6aa9776da5d4eda Mon Sep 17 00:00:00 2001
From: Rudi Heitbaum <rudi@heitbaum.com>
Date: Sun, 4 May 2025 03:39:07 +0000
Subject: [PATCH] allow build with gettext 0.24.1
make sure iconv.m4 is available for autoconf to find it
fixes build error below:
autoreconf: export WARNINGS=
autoreconf: Entering directory '/b/build/libmtp-1.1.22'
autoreconf: configure.ac: not using Gettext
autoreconf: running: /b/toolchain/bin/aclocal -I /b/toolchain/x86_64-libreelec-linux-gnu/sysroot/usr/share/aclocal -I /b/toolchain/x86_64-libreelec-linux-gnu/sysroot/usr/share/aclocal --force -I m4
autoreconf: configure.ac: tracing
autoreconf: running: /b/toolchain/bin/libtoolize --copy --force
libtoolize: putting auxiliary files in '.'.
libtoolize: copying file './ltmain.sh'
libtoolize: putting macros in AC_CONFIG_MACRO_DIRS, 'm4'.
libtoolize: copying file 'm4/libtool.m4'
libtoolize: copying file 'm4/ltoptions.m4'
libtoolize: copying file 'm4/ltsugar.m4'
libtoolize: copying file 'm4/ltversion.m4'
libtoolize: copying file 'm4/lt~obsolete.m4'
autoreconf: configure.ac: not using Intltool
autoreconf: configure.ac: not using Gtkdoc
autoreconf: running: /b/toolchain/bin/aclocal -I /b/toolchain/x86_64-libreelec-linux-gnu/sysroot/usr/share/aclocal -I /b/toolchain/x86_64-libreelec-linux-gnu/sysroot/usr/share/aclocal --force -I m4
autoreconf: running: /b/toolchain/bin/autoconf --include=/b/toolchain/x86_64-libreelec-linux-gnu/sysroot/usr/share/aclocal --force
configure.ac:7: warning: 'AM_CONFIG_HEADER': this macro is obsolete.
configure.ac:7: You should use the 'AC_CONFIG_HEADERS' macro instead.
aclocal.m4:707: AM_CONFIG_HEADER is expanded from...
configure.ac:7: the top level
configure.ac:14: warning: The macro 'AC_LIBTOOL_WIN32_DLL' is obsolete.
configure.ac:14: You should run autoupdate.
aclocal.m4:9953: AC_LIBTOOL_WIN32_DLL is expanded from...
configure.ac:14: the top level
configure.ac:14: warning: AC_LIBTOOL_WIN32_DLL: Remove this warning and the call to _LT_SET_OPTION when you
configure.ac:14: put the 'win32-dll' option into LT_INIT's first parameter.
/b/build/autoconf-2.72/lib/autoconf/general.m4:2434: AC_DIAGNOSE is expanded from...
aclocal.m4:9953: AC_LIBTOOL_WIN32_DLL is expanded from...
configure.ac:14: the top level
configure.ac:15: warning: The macro 'AC_PROG_LIBTOOL' is obsolete.
configure.ac:15: You should run autoupdate.
aclocal.m4:1439: AC_PROG_LIBTOOL is expanded from...
configure.ac:15: the top level
configure.ac:16: warning: AC_LIB_PREPARE_PREFIX is m4_require'd but not m4_defun'd
m4/iconv.m4:9: AM_ICONV_LINKFLAGS_BODY is expanded from...
m4/iconv.m4:20: AM_ICONV_LINK is expanded from...
m4/iconv.m4:169: AM_ICONV is expanded from...
configure.ac:16: the top level
configure.ac:16: warning: AC_LIB_RPATH is m4_require'd but not m4_defun'd
m4/iconv.m4:9: AM_ICONV_LINKFLAGS_BODY is expanded from...
m4/iconv.m4:20: AM_ICONV_LINK is expanded from...
m4/iconv.m4:169: AM_ICONV is expanded from...
configure.ac:16: the top level
configure.ac:16: warning: The macro 'AC_TRY_LINK' is obsolete.
configure.ac:16: You should run autoupdate.
/b/build/autoconf-2.72/lib/autoconf/general.m4:2918: AC_TRY_LINK is expanded from...
/b/build/autoconf-2.72/lib/m4sugar/m4sh.m4:690: _AS_IF_ELSE is expanded from...
/b/build/autoconf-2.72/lib/m4sugar/m4sh.m4:697: AS_IF is expanded from...
/b/build/autoconf-2.72/lib/autoconf/general.m4:2249: AC_CACHE_VAL is expanded from...
/b/build/autoconf-2.72/lib/autoconf/general.m4:2270: AC_CACHE_CHECK is expanded from...
m4/iconv.m4:20: AM_ICONV_LINK is expanded from...
m4/iconv.m4:169: AM_ICONV is expanded from...
configure.ac:16: the top level
configure.ac:16: warning: The macro 'AC_TRY_RUN' is obsolete.
configure.ac:16: You should run autoupdate.
/b/build/autoconf-2.72/lib/autoconf/general.m4:2995: AC_TRY_RUN is expanded from...
/b/build/autoconf-2.72/lib/m4sugar/m4sh.m4:690: _AS_IF_ELSE is expanded from...
/b/build/autoconf-2.72/lib/m4sugar/m4sh.m4:697: AS_IF is expanded from...
/b/build/autoconf-2.72/lib/autoconf/general.m4:2249: AC_CACHE_VAL is expanded from...
/b/build/autoconf-2.72/lib/autoconf/general.m4:2270: AC_CACHE_CHECK is expanded from...
m4/iconv.m4:20: AM_ICONV_LINK is expanded from...
m4/iconv.m4:169: AM_ICONV is expanded from...
configure.ac:16: the top level
configure.ac:16: warning: The macro 'AC_TRY_COMPILE' is obsolete.
configure.ac:16: You should run autoupdate.
/b/build/autoconf-2.72/lib/autoconf/general.m4:2845: AC_TRY_COMPILE is expanded from...
/b/build/autoconf-2.72/lib/m4sugar/m4sh.m4:690: _AS_IF_ELSE is expanded from...
/b/build/autoconf-2.72/lib/m4sugar/m4sh.m4:697: AS_IF is expanded from...
/b/build/autoconf-2.72/lib/autoconf/general.m4:2249: AC_CACHE_VAL is expanded from...
m4/iconv.m4:169: AM_ICONV is expanded from...
configure.ac:16: the top level
configure.ac:154: warning: The macro 'AC_TRY_COMPILE' is obsolete.
configure.ac:154: You should run autoupdate.
/b/build/autoconf-2.72/lib/autoconf/general.m4:2845: AC_TRY_COMPILE is expanded from...
configure.ac:154: the top level
configure.ac:244: warning: The macro 'AC_HEADER_STDC' is obsolete.
configure.ac:244: You should run autoupdate.
/b/build/autoconf-2.72/lib/autoconf/headers.m4:663: AC_HEADER_STDC is expanded from...
configure.ac:244: the top level
configure.ac:245: warning: The macro 'AC_HEADER_TIME' is obsolete.
configure.ac:245: You should run autoupdate.
/b/build/autoconf-2.72/lib/autoconf/headers.m4:702: AC_HEADER_TIME is expanded from...
configure.ac:245: the top level
configure.ac:263: warning: The macro 'AC_TYPE_SIGNAL' is obsolete.
configure.ac:263: You should run autoupdate.
/b/build/autoconf-2.72/lib/autoconf/types.m4:805: AC_TYPE_SIGNAL is expanded from...
configure.ac:263: the top level
configure.ac:265: warning: The macro 'AC_STRUCT_ST_BLKSIZE' is obsolete.
configure.ac:265: You should run autoupdate.
/b/build/autoconf-2.72/lib/autoconf/types.m4:1029: AC_STRUCT_ST_BLKSIZE is expanded from...
configure.ac:265: the top level
configure:14216: error: possibly undefined macro: AC_LIB_PREPARE_PREFIX
If this token and others are legitimate, please use m4_pattern_allow.
See the Autoconf documentation.
configure:14217: error: possibly undefined macro: AC_LIB_RPATH
configure:14222: error: possibly undefined macro: AC_LIB_LINKFLAGS_BODY
configure:14230: error: possibly undefined macro: AC_LIB_APPENDTOVAR
autoreconf: error: /b/toolchain/bin/autoconf failed with exit status: 1
---
configure.ac | 1 +
1 file changed, 1 insertion(+)
diff --git a/configure.ac b/configure.ac
index 40bdaaa..9f8d670 100644
--- a/configure.ac
+++ b/configure.ac
@@ -13,6 +13,7 @@ AC_PROG_LN_S
AC_CHECK_TOOL([HOST_MTP_HOTPLUG],[mtp-hotplug],[:])
AC_LIBTOOL_WIN32_DLL
AC_PROG_LIBTOOL
+AM_GNU_GETTEXT_VERSION([0.11.5])
AM_ICONV
# Optionally set install location of udev
--
2.43.0