mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-25 04:59:00 +08:00
3492464c1c
* Update to 3.1.15 * Modernize portfile * Keep plugins * Always use vcpkg zlib instead vendored copy * Use zlib and openssl modules in pc file * Always install pc file, drop non-relocatable mariadb_config * UWP is not supported * Use schannel SSL backend on windows * Fix exported includedir and libdir * Fixup windows pc file * Disable extra static lib * Disable plugins with extra dependencies * [libmariadb] Namespace targets with unofficial:: * Update versions * Enable CI for x86-windows: no conflict with mysql * Re-enable lib mariadbclient via feature * Use openssl targets to handle multi-config * Update versions * CR request * Update versions
61 lines
1.9 KiB
Diff
61 lines
1.9 KiB
Diff
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
|
index 0be0fb1..33565f5 100644
|
|
--- a/CMakeLists.txt
|
|
+++ b/CMakeLists.txt
|
|
@@ -393,7 +393,7 @@ ENDIF()
|
|
INCLUDE(${CC_SOURCE_DIR}/plugins/CMakeLists.txt)
|
|
ADD_SUBDIRECTORY(include)
|
|
ADD_SUBDIRECTORY(libmariadb)
|
|
-IF(NOT WIN32)
|
|
+IF(1)
|
|
ADD_SUBDIRECTORY(mariadb_config)
|
|
ENDIF()
|
|
|
|
diff --git a/mariadb_config/CMakeLists.txt b/mariadb_config/CMakeLists.txt
|
|
index 70e619b..7a22fa1 100644
|
|
--- a/mariadb_config/CMakeLists.txt
|
|
+++ b/mariadb_config/CMakeLists.txt
|
|
@@ -30,6 +30,15 @@ IF(${rllength} GREATER 0)
|
|
LIST(REMOVE_DUPLICATES SYSTEM_LIBS)
|
|
ENDIF()
|
|
|
|
+set(REQUIRES_PRIVATE "" CACHE STRING "")
|
|
+if(WITH_SSL STREQUAL "OPENSSL")
|
|
+ list(REMOVE_ITEM SYSTEM_LIBS ${SSL_LIBRARIES})
|
|
+ string(APPEND REQUIRES_PRIVATE " openssl")
|
|
+endif()
|
|
+if(WITH_EXTERNAL_ZLIB)
|
|
+ string(APPEND REQUIRES_PRIVATE " zlib")
|
|
+endif()
|
|
+
|
|
FOREACH (LIB_NAME ${SYSTEM_LIBS})
|
|
GET_LIB_NAME(${LIB_NAME} LIB_OUT)
|
|
SET(extra_dynamic_LDFLAGS "${extra_dynamic_LDFLAGS} ${LIB_OUT}")
|
|
@@ -50,6 +59,7 @@ CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/mariadb_config.c.in
|
|
CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/libmariadb.pc.in
|
|
${CMAKE_CURRENT_BINARY_DIR}/libmariadb.pc @ONLY)
|
|
|
|
+if(0)
|
|
ADD_EXECUTABLE(mariadb_config ${CMAKE_CURRENT_BINARY_DIR}/mariadb_config.c)
|
|
|
|
IF(CMAKE_SYSTEM_NAME MATCHES AIX)
|
|
@@ -61,6 +71,7 @@ ENDIF()
|
|
INSTALL(TARGETS mariadb_config
|
|
DESTINATION "bin"
|
|
COMPONENT Development)
|
|
+endif()
|
|
|
|
INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/libmariadb.pc
|
|
DESTINATION "${INSTALL_PCDIR}"
|
|
diff --git a/mariadb_config/libmariadb.pc.in b/mariadb_config/libmariadb.pc.in
|
|
index 968181a..3f0410d 100644
|
|
--- a/mariadb_config/libmariadb.pc.in
|
|
+++ b/mariadb_config/libmariadb.pc.in
|
|
@@ -16,5 +16,6 @@ Description: MariaDB Connector/C dynamic library
|
|
Cflags: -I${includedir}
|
|
Libs: -L${libdir} -lmariadb
|
|
Libs.private: @extra_dynamic_LDFLAGS@
|
|
+Requires.private: @REQUIRES_PRIVATE@
|
|
|
|
|