2020-06-24 04:03:23 +08:00
|
|
|
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
2023-10-03 11:48:58 +08:00
|
|
|
index fbe2288..d7218a6 100755
|
2020-06-24 04:03:23 +08:00
|
|
|
--- a/CMakeLists.txt
|
|
|
|
+++ b/CMakeLists.txt
|
2023-10-03 11:48:58 +08:00
|
|
|
@@ -367,11 +367,10 @@ endif (NOT WIN32)
|
2020-11-03 05:58:02 +08:00
|
|
|
|
2021-04-13 02:12:20 +08:00
|
|
|
if (BUILD_POSTGRESQL)
|
|
|
|
# find postgres
|
|
|
|
- find_package(pg)
|
|
|
|
- if (pg_FOUND)
|
|
|
|
- message(STATUS "libpq inc path:" ${PG_INCLUDE_DIRS})
|
|
|
|
- message(STATUS "libpq lib:" ${PG_LIBRARIES})
|
|
|
|
- target_link_libraries(${PROJECT_NAME} PRIVATE pg_lib)
|
|
|
|
+ find_package(PostgreSQL REQUIRED)
|
|
|
|
+ if(PostgreSQL_FOUND)
|
2023-03-25 12:43:03 +08:00
|
|
|
+ set(pg_FOUND true)
|
|
|
|
+ target_link_libraries(${PROJECT_NAME} PRIVATE PostgreSQL::PostgreSQL)
|
2021-11-05 21:01:35 +01:00
|
|
|
set(DROGON_SOURCES
|
|
|
|
${DROGON_SOURCES}
|
2023-03-25 12:43:03 +08:00
|
|
|
orm_lib/src/postgresql_impl/PostgreSQLResultImpl.cc
|
2023-10-03 11:48:58 +08:00
|
|
|
@@ -401,7 +400,7 @@ if (BUILD_POSTGRESQL)
|
2021-11-05 21:01:35 +01:00
|
|
|
${private_headers}
|
|
|
|
orm_lib/src/postgresql_impl/PgConnection.h)
|
2021-04-13 02:12:20 +08:00
|
|
|
endif (libpq_supports_batch)
|
|
|
|
- endif (pg_FOUND)
|
|
|
|
+ endif (PostgreSQL_FOUND)
|
|
|
|
endif (BUILD_POSTGRESQL)
|
|
|
|
|
|
|
|
if (BUILD_MYSQL)
|