FindPostgreSQL¶
尋找 PostgreSQL 安裝位置。
匯入的目標 (IMPORTED Targets)¶
在 3.14 版本中新增。
如果找到 PostgreSQL,此模組會定義 IMPORTED
目標 PostgreSQL::PostgreSQL
。
結果變數 (Result Variables)¶
此模組會在您的專案中設定以下變數
PostgreSQL_FOUND
如果找到 PostgreSQL,則為 True。
PostgreSQL_LIBRARIES
連結所需的 PostgreSQL 函式庫
PostgreSQL_INCLUDE_DIRS
PostgreSQL 標頭檔的目錄
PostgreSQL_LIBRARY_DIRS
PostgreSQL 函式庫的連結目錄
PostgreSQL_VERSION_STRING
找到的 PostgreSQL 版本字串
PostgreSQL_TYPE_INCLUDE_DIR
PostgreSQL 伺服器標頭檔的目錄
組件 (Components)¶
此模組包含額外的 Server
組件,會強制檢查伺服器標頭檔是否存在。請注意,無論 find_package 呼叫中是否有 Server
組件,都會設定 PostgreSQL_TYPE_INCLUDE_DIR
。