Do not look for pg_config, mysql_config in PATH when cross-compiling
Otherwise it can happen that we pick up the tool for the host system, which will break compilation. Users can still pass -psql_config /path/to/pg_config or -mysql_config /path/to/mysql_config manually. [ChangeLog][QtSql] When cross-compiling pg_config, mysql_config are not looked up in PATH anymore. Pass -psql_config path/to/pg_config or -mysql_config path/to/mysql_config to explicitly enable PSQL or MySQL in this setup. Fixes: QTBUG-73565 Change-Id: I35ff32322bac69f1575ce6c846a56ac2ae3b8d55 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
This commit is contained in:
parent
54efa7e592
commit
1a707be8b4
@ -2,7 +2,7 @@
|
||||
|
||||
defineTest(qtConfLibrary_psqlConfig) {
|
||||
pg_config = $$config.input.psql_config
|
||||
isEmpty(pg_config): \
|
||||
isEmpty(pg_config):!cross_compile: \
|
||||
pg_config = $$qtConfFindInPath("pg_config")
|
||||
!win32:!isEmpty(pg_config) {
|
||||
qtRunLoggedCommand("$$pg_config --libdir", libdir)|return(false)
|
||||
@ -33,7 +33,7 @@ defineTest(qtConfLibrary_psqlEnv) {
|
||||
|
||||
defineTest(qtConfLibrary_mysqlConfig) {
|
||||
mysql_config = $$config.input.mysql_config
|
||||
isEmpty(mysql_config): \
|
||||
isEmpty(mysql_config):!cross_compile: \
|
||||
mysql_config = $$qtConfFindInPath("mysql_config")
|
||||
!isEmpty(mysql_config) {
|
||||
qtRunLoggedCommand("$$mysql_config --version", version)|return(false)
|
||||
|
Loading…
Reference in New Issue
Block a user