Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pkg-config incompletely called in configure #51

Open
dmacks opened this issue Dec 28, 2020 · 0 comments
Open

pkg-config incompletely called in configure #51

dmacks opened this issue Dec 28, 2020 · 0 comments

Comments

@dmacks
Copy link

dmacks commented Dec 28, 2020

On OS X 10.13 libgeotiff-1.6.0:

./configure --prefix=/sw --with-zip=/usr/include --with-jpeg=/sw --with-libtiff=/sw --disable-doxygen-doc
[...]
checking for PROJ >= 6 library... checking for PROJ... no
checking for proj_create_from_wkt in -lproj... yes
checking proj.h usability... yes
checking proj.h presence... yes
checking for proj.h... yes
configure: proj.h found

But I do have proj.pc and pkg-config can find it normally. Instead, there's a flaw in how PKG_CHECK_MODULES is being called. There are several previous PKG_CHECK_MODULES that are not being called due to the --with-* for their libs. So this is the first P_C_M that is called but not the first in the ./configure script. As a result, some initialization that the autotools do for "the first P_C_M in configure.ac" are not run. It's exactly the bug described at https://autotools.io/pkgconfig/pkg_check_modules.html section 3.4, and the fix described there works for me.

Adding

PKG_PROG_PKG_CONFIG0

to the "Checks for programs" block gives me:

checking for PROJ >= 6 library... checking for proj... yes
checking proj.h usability... yes
checking proj.h presence... yes
checking for proj.h... yes
configure: proj.h found
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant