#154 configure: Fix detection of supported NSS db type
Merged by rcritten. Opened by slev.
slev/certmonger detect_nss_db  into  master

For now configure always reports about the lack of support for
any NSS db:
checking if NSS supports "sql:" databases... no
checking if NSS supports "dbm:" databases... no

Actually, there is the linking issue, but AC_TRY_RUN is not
designed to detect this.

The recipe is the obeying the proper linking order:
$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS

Fixes: https://pagure.io/certmonger/issue/153

This triggers the tests placed under HAVE_DBM_NSSDB and HAVE_SQL_NSSDB.

Curious. This should have never worked. What compiler are you using? Maybe it has stricter enforcement of link order.

Right now it is:

gcc --version
x86_64-alt-linux-gcc (GCC) 9.3.1 20200518 (ALT Sisyphus 9.3.1-alt1)

I haven't noticed this until yesterday.
I've checked the build log for 0.79.6 (the end of 2018, oldest I have), there was the same problem.

So pretty much the same version I have. odd, maybe some ld diff. Either way this is obviously correct but I'm going to do some local testing to be sure that at least Fedora is ok with it. Thanks for the patch.

Checks out ok, merging.

Metadata Update from @rcritten:
- Request assigned

Pull-Request has been merged by rcritten

Metadata