From 622e5f67bd7f9249514c44c7b64f2821a8f74635 Mon Sep 17 00:00:00 2001 From: Fabrice Fontaine Date: Thu, 28 Jul 2022 10:00:16 +0200 Subject: [PATCH] package/gdal: fix json dependency gdal needs json-c, not libjson, resulting in the following build failure since the addition of the package in commit 1e64fa2956171cdc9d6e6c8896b4b589ce573513: configure: error: could not find json-c/json.h While at it, also drop unrecognized options: configure: WARNING: unrecognized options: --disable-gtk-doc, --disable-gtk-doc-html, --disable-doc, --disable-docs, --disable-documentation, --with-xmlto, --with-fop, --disable-dependency-tracking, --enable-ipv6, --disable-nls, --without-dods-root, --without-fme, --without-grass, --without-libgrass, --without-ingres, --without-jasper, --without-charls, --without-mdb, --without-mongocxx, --without-mrsid_lidar, --without-perl Fixes: - http://autobuild.buildroot.org/results/f977675125167806e844a176a4c8c8873557b709 Signed-off-by: Fabrice Fontaine Signed-off-by: Thomas Petazzoni --- package/gdal/Config.in | 6 ++++-- package/gdal/gdal.mk | 15 ++------------- 2 files changed, 6 insertions(+), 15 deletions(-) diff --git a/package/gdal/Config.in b/package/gdal/Config.in index 55a8c7fb83..ee7209566a 100644 --- a/package/gdal/Config.in +++ b/package/gdal/Config.in @@ -1,6 +1,7 @@ config BR2_PACKAGE_GDAL bool "gdal" - depends on BR2_INSTALL_LIBSTDCPP # proj, libjson + depends on BR2_TOOLCHAIN_HAS_SYNC_4 # json-c + depends on BR2_INSTALL_LIBSTDCPP # proj # configure can't find proj, when linking statically depends on !BR2_STATIC_LIBS depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_7 # C++11, proj @@ -8,8 +9,8 @@ config BR2_PACKAGE_GDAL depends on BR2_TOOLCHAIN_HAS_THREADS # proj depends on BR2_USE_WCHAR # proj select BR2_PACKAGE_JPEG + select BR2_PACKAGE_JSON_C select BR2_PACKAGE_LIBGEOTIFF - select BR2_PACKAGE_LIBJSON select BR2_PACKAGE_LIBPNG select BR2_PACKAGE_PROJ select BR2_PACKAGE_ZLIB @@ -24,6 +25,7 @@ config BR2_PACKAGE_GDAL https://gdal.org/ comment "gdal needs a toolchain w/ C++, dynamic library, gcc >= 4.7, not binutils bug 27597, threads, wchar" + depends on BR2_TOOLCHAIN_HAS_SYNC_4 depends on !BR2_INSTALL_LIBSTDCPP || BR2_STATIC_LIBS || \ !BR2_TOOLCHAIN_GCC_AT_LEAST_4_7 || \ BR2_TOOLCHAIN_HAS_BINUTILS_BUG_27597 || \ diff --git a/package/gdal/gdal.mk b/package/gdal/gdal.mk index c75b7743ce..33e7ba724a 100644 --- a/package/gdal/gdal.mk +++ b/package/gdal/gdal.mk @@ -18,14 +18,14 @@ GDAL_CONFIG_SCRIPTS = gdal-config # enabled but it seems, in contrast to mrf driver support, that they # can be implicitly disabled, by configuring gdal without their # respectively needed dependencies. -GDAL_DEPENDENCIES = host-pkgconf jpeg libgeotiff libpng proj tiff zlib +GDAL_DEPENDENCIES = host-pkgconf jpeg json-c libgeotiff libpng proj tiff zlib # Yes, even though they have --with options, these few libraries are # mandatory. If we don't provide them, bundled versions are used. GDAL_CONF_OPTS = \ --with-geotiff \ --with-jpeg \ - --with-libjson-c \ + --with-libjson-c=$(STAGING_DIR)/usr \ --with-libtool \ --with-libz \ --with-png \ @@ -38,45 +38,35 @@ GDAL_CONF_OPTS = \ --without-cryptopp \ --without-curl \ --without-dds \ - --without-dods-root \ --without-ecw \ --without-expat \ --without-exr \ --without-fgdb \ - --without-fme \ --without-freexl \ --without-geos \ --without-gnm \ --without-libkml \ --without-lz4 \ - --without-grass \ - --without-libgrass \ --without-gta \ --without-hdf4 \ --without-hdf5 \ --without-hdfs \ --without-heif \ --without-idb \ - --without-ingres \ --without-jp2lura \ - --without-jasper \ --without-java \ --without-jpeg12 \ --without-jxl \ - --without-charls \ --without-kakadu \ --without-kea \ --without-lerc \ --without-gif \ --without-liblzma \ --without-libdeflate \ - --without-mdb \ - --without-mongocxx \ --without-mongocxxv3 \ --without-mrsid \ --without-jp2mrsid \ --without-macosx-framework \ - --without-mrsid_lidar \ --without-msg \ --without-mysql \ --without-netcdf \ @@ -92,7 +82,6 @@ GDAL_CONF_OPTS = \ --without-pcre \ --without-pcre2 \ --without-pdfium \ - --without-perl \ --without-podofo \ --without-poppler \ --without-python \