Bug 257001 - graphics/gdal will not configure if GEOS disabled
Summary: graphics/gdal will not configure if GEOS disabled
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Po-Chuan Hsieh
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-07-05 20:38 UTC by russo
Modified: 2021-07-06 15:12 UTC (History)
2 users (show)

See Also:
bugzilla: maintainer-feedback? (sunpoet)


Attachments
The config.log produced during a build attempt of gdal without GEOS support requested (230.53 KB, text/plain)
2021-07-05 20:38 UTC, russo
no flags Details
New configure patch for --with-scfgal=no (3.23 KB, patch)
2021-07-06 14:37 UTC, Robert Kruus
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description russo 2021-07-05 20:38:03 UTC
Created attachment 226248 [details]
The config.log produced during a build attempt of gdal without GEOS support requested

I am trying to update gdal to 3.3.0, and it fails in configure when I don't have GEOS selected (I do not need GEOS and don't want all the dependencies it brings in).

Configure fails with:

checking Checking for Teigha... disabled
configure: IBM Informix DataBlade not supported.
GEOS support disabled
configure: error: GEOS support explicitly enabled, but geos-config could not be found
===>  Script "configure" failed unexpectedly.
Please report the problem to sunpoet@FreeBSD.org [maintainer] and attach the
"/usr/ports/graphics/gdal/work/gdal-3.3.0/config.log" including the output
of the failure of your make command. Also, it might be a good idea to provide
an overview of all packages installed on your system (e.g. a
/usr/local/sbin/pkg-static info -g -Ea).
*** Error code 1
Comment 1 russo 2021-07-05 20:46:17 UTC
I should note that I'm trying to build a fairly minimal version of GDAL, as I only need some of its features.

I have only EXR, JASPER, KML, and POPPLER selected.  With this small subset, I get the failure reported here.

If I try to enable GEOS, then GEOS gets installed, but I still get a failure in gdal's configure phase.  It's a different one of the same variety:

configure: Using C API from GEOS 3.9.1
SFCGAL support disabled
configure: error: SFCGAL support explicitly enabled, but sfcgal-config could not be found
===>  Script "configure" failed unexpectedly.
Please report the problem to sunpoet@FreeBSD.org [maintainer] and attach the
"/usr/ports/graphics/gdal/work/gdal-3.3.0/config.log" including the output
of the failure of your make command. Also, it might be a good idea to provide
an overview of all packages installed on your system (e.g. a
/usr/local/sbin/pkg-static info -g -Ea).
*** Error code 1


Note that configure is saying that I've got the support disabled, but then immediately fails saying it's explicitly enabled and not found.

If I enable SFCGAL, then gdal's configure works.

There is clearly something wrong with GEOS and SFCGAL options, since it won't let me disable them.
Comment 2 Robert Kruus 2021-07-06 14:37:13 UTC
Created attachment 226269 [details]
New configure patch for --with-scfgal=no
Comment 3 Robert Kruus 2021-07-06 14:41:19 UTC
Comment on attachment 226269 [details]
New configure patch for --with-scfgal=no

I had the same issue with the SFCGAL knob (I have GOES already enabled). I think it has to do with the configure script -- it continues to look for
*-config programs even when the --with-*=no is passed to the configure script.

I was able to patch configure to make it work for sfcgal (see attached), I assume the fix maybe similar for GOES.
Comment 4 Po-Chuan Hsieh freebsd_committer freebsd_triage 2021-07-06 15:12:27 UTC
Fixed in 2e5262c24a1736f49c475a22ec9adbe414384522. Thanks!