GSSAPI: strengthen configure test and make it a library

This way we can actually filter out times in sitatuations where it
proved to not be available and as a library we can simply "use" it.

Added in the pkgConfig source as well to make sure we can pick it up
on systems where it has a different name.

Fixes: QTBUG-78765
Change-Id: I4754923ddafd9274105e4f93d66a4039872e310c
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: André Klitzing <aklitzing@gmail.com>
This commit is contained in:
Mårten Nordheim 2019-09-30 16:56:01 +02:00
parent ad86c2f0ab
commit 1a8f4a3c8f
2 changed files with 16 additions and 11 deletions

View File

@ -98,6 +98,20 @@
"condition": "!config.msvc"
}
]
},
"gssapi": {
"label": "KRB5 GSSAPI Support",
"test": {
"main": [
"gss_ctx_id_t ctx;",
"gss_context_time(nullptr, ctx, nullptr);"
]
},
"headers": [ "gssapi/gssapi.h" ],
"sources": [
{ "type": "pkgConfig", "args": "krb5-gssapi" },
"-lgssapi_krb5"
]
}
},
@ -200,15 +214,6 @@
},
"use": "openssl"
},
"gssapi": {
"label": "KRB5 GSSAPI support",
"type": "compile",
"test": {
"include": [ "gssapi/gssapi.h" ],
"main": ["gss_ctx_id_t ctx;"],
"qmake": "LIBS += -lgssapi_krb5"
}
},
"netlistmgr": {
"label": "Network List Manager",
"type": "compile",
@ -408,7 +413,7 @@
"label": "GSSAPI",
"purpose": "Enable SPNEGO authentication through GSSAPI",
"section": "Networking",
"condition": "!config.win32 && tests.gssapi",
"condition": "!config.win32 && libs.gssapi",
"output": [ "publicFeature", "feature" ]
},
"sspi": {

View File

@ -83,7 +83,7 @@ macos | ios {
SOURCES += kernel/qnetconmonitor_stub.cpp
}
qtConfig(gssapi): LIBS_PRIVATE += -lgssapi_krb5
qtConfig(gssapi): QMAKE_USE_PRIVATE += gssapi
uikit:HEADERS += kernel/qnetworkinterface_uikit_p.h
osx:SOURCES += kernel/qnetworkproxy_mac.cpp