CMake/sql find modules: read foo_ROOT env var if available
Even though we set foo_ROOT in the provisioning scripts and CMake is picking it up as the base dir, we should also use it as CMake variable so we can look in other directories below foo_ROOT. Change-Id: I193d8ff1c216a669162569d71891c3eb7b9b030f Reviewed-by: Alexey Edelev <alexey.edelev@qt.io> (cherry picked from commit c68277c41b99d6791e3c1a5998b70c6cbbf6dc15) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
parent
85af817469
commit
5e8feb69df
@ -21,6 +21,12 @@
|
||||
# ``Interbase::Interbase``
|
||||
# The Interbase client library
|
||||
|
||||
if(NOT DEFINED Interbase_ROOT)
|
||||
if(DEFINED ENV{Interbase_ROOT})
|
||||
set(Interbase_ROOT "$ENV{Interbase_ROOT}")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
find_path(Interbase_INCLUDE_DIR
|
||||
NAMES ibase.h
|
||||
HINTS "${Interbase_INCLUDEDIR}" "${Interbase_ROOT}/include"
|
||||
|
@ -40,7 +40,11 @@
|
||||
# The mysql client library
|
||||
|
||||
if(NOT DEFINED MySQL_ROOT)
|
||||
find_package(PkgConfig QUIET)
|
||||
if(DEFINED ENV{MySQL_ROOT})
|
||||
set(MySQL_ROOT "$ENV{MySQL_ROOT}")
|
||||
else()
|
||||
find_package(PkgConfig QUIET)
|
||||
endif()
|
||||
endif()
|
||||
if(PkgConfig_FOUND AND NOT DEFINED MySQL_ROOT)
|
||||
pkg_check_modules(PC_MySQL QUIET "mysqlclient")
|
||||
|
@ -21,6 +21,12 @@
|
||||
# ``Oracle::Oracle``
|
||||
# The oracle instant client library
|
||||
|
||||
if(NOT DEFINED Oracle_ROOT)
|
||||
if(DEFINED ENV{Oracle_ROOT})
|
||||
set(Oracle_ROOT "$ENV{Oracle_ROOT}")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
find_path(Oracle_INCLUDE_DIR
|
||||
NAMES oci.h
|
||||
HINTS ${Oracle_INCLUDE_DIR} "${Oracle_ROOT}" "${Oracle_ROOT}/include" "${Oracle_ROOT}/sdk/include"
|
||||
|
Loading…
x
Reference in New Issue
Block a user