diff options
author | Nick Hainke <vincent@systemli.org> | 2022-07-04 09:52:43 +0200 |
---|---|---|
committer | Hauke Mehrtens <hauke@hauke-m.de> | 2022-07-04 20:24:06 +0200 |
commit | a0c5b03e02528b938f1c6d411a582b67b7e9fe7b (patch) | |
tree | 4c10bf22bbfe96352bca0f7b35cd8c9024b183f7 /package/utils/f2fs-tools/patches/101-configure.ac-fix-cross-compilation.patch | |
parent | f58e562b07803192d029a6be8c8c372e1ed11c68 (diff) | |
download | upstream-a0c5b03e02528b938f1c6d411a582b67b7e9fe7b.tar.gz upstream-a0c5b03e02528b938f1c6d411a582b67b7e9fe7b.tar.bz2 upstream-a0c5b03e02528b938f1c6d411a582b67b7e9fe7b.zip |
f2fs-tools: import patch to fix compilation
Disable lz4 and lzo2 manually.
Fixes errors in the form of:
Package f2fsck is missing dependencies for the following libraries:
liblz4.so.1
liblzo2.so.2
Fixes: 8b9e80616011 ("f2fs-tools: update to 1.15.0")
Acked-by: Thomas Huehn <thomas.huehn@hs-nordhausen.de>
Signed-off-by: Nick Hainke <vincent@systemli.org>
Diffstat (limited to 'package/utils/f2fs-tools/patches/101-configure.ac-fix-cross-compilation.patch')
-rw-r--r-- | package/utils/f2fs-tools/patches/101-configure.ac-fix-cross-compilation.patch | 80 |
1 files changed, 80 insertions, 0 deletions
diff --git a/package/utils/f2fs-tools/patches/101-configure.ac-fix-cross-compilation.patch b/package/utils/f2fs-tools/patches/101-configure.ac-fix-cross-compilation.patch new file mode 100644 index 0000000000..b9edd6634b --- /dev/null +++ b/package/utils/f2fs-tools/patches/101-configure.ac-fix-cross-compilation.patch @@ -0,0 +1,80 @@ +From 821a1d3fcce31c234512a8f4dc4fc97dfbd7ae32 Mon Sep 17 00:00:00 2001 +From: Nick Hainke <vincent@systemli.org> +Date: Mon, 4 Jul 2022 09:46:10 +0200 +Subject: [PATCH] configure.ac: fix cross compilation + +AC_CHECK_LIB seems to not work correctly with OpenWrt. Add possibility +to disable lz4 and lzo2 manually. + +Fixes errors in the form of: + Package f2fsck is missing dependencies for the following libraries: + liblz4.so.1 + liblzo2.so.2 + +Signed-off-by: Nick Hainke <vincent@systemli.org> +--- + configure.ac | 44 ++++++++++++++++++++++++++++++++++---------- + 1 file changed, 34 insertions(+), 10 deletions(-) + +--- a/configure.ac ++++ b/configure.ac +@@ -50,6 +50,18 @@ AC_ARG_WITH([blkid], + [], + [with_blkid=check]) + ++AC_ARG_WITH([lzo2], ++ [AS_HELP_STRING([--without-lzo2], ++ [Ignore presence of liblzo2 and disable lzo2 support])], ++ [], ++ [with_lzo2=check]) ++ ++AC_ARG_WITH([lz4], ++ [AS_HELP_STRING([--without-lz4], ++ [Ignore presence of liblz4 and disable lz4 support])], ++ [], ++ [with_lz4=check]) ++ + # Checks for programs. + AC_PROG_CC + AM_PROG_AR +@@ -71,17 +83,29 @@ AS_IF([test "x$with_blkid" != xno], + fi + ], -lblkid)]) + +-AC_CHECK_LIB([lzo2], [main], +- [AC_SUBST([liblzo2_LIBS], ["-llzo2"]) +- AC_DEFINE([HAVE_LIBLZO2], [1], +- [Define if you have liblzo2]) +- ], [], []) +- +-AC_CHECK_LIB([lz4], [main], +- [AC_SUBST([liblz4_LIBS], ["-llz4"]) +- AC_DEFINE([HAVE_LIBLZ4], [1], +- [Define if you have liblz4]) +- ], [], []) ++AS_IF([test "x$with_lzo2" != xno], ++ [AC_CHECK_LIB([lzo2], [main], ++ [AC_SUBST([liblzo2_LIBS], ["-llzo2"]) ++ AC_DEFINE([HAVE_LIBLZO2], [1], ++ [Define if you have liblzo2]) ++ ], ++ [if test "x$with_lzo2" != xcheck; then ++ AC_MSG_FAILURE( ++ [--with-lzo2 was given, but test for lzo2 failed]) ++ fi ++ ], -llzo2)]) ++ ++AS_IF([test "x$with_lz4" != xno], ++ [AC_CHECK_LIB([lz4], [main], ++ [AC_SUBST([liblz4_LIBS], ["-llz4"]) ++ AC_DEFINE([HAVE_LIBLZ4], [1], ++ [Define if you have liblz4]) ++ ], ++ [if test "x$with_lz4" != xcheck; then ++ AC_MSG_FAILURE( ++ [--with-lz4 was given, but test for lz4 failed]) ++ fi ++ ], -llz4)]) + + AS_IF([test "x$with_selinux" != xno], + [AC_CHECK_LIB([selinux], [getcon], |