diff options
| author | Tobias Brückner <toxe@toxe.net> | 2020-02-29 06:56:22 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-02-28 21:56:22 -0800 |
| commit | 64f7f2590dd71fa64a64287e330ef536606d213a (patch) | |
| tree | 229fc3ba648484f03d766935dd54565fa5f64762 | |
| parent | 053ade685f73da9fb87ebb8c30482880f09f9acd (diff) | |
| download | vcpkg-64f7f2590dd71fa64a64287e330ef536606d213a.tar.gz vcpkg-64f7f2590dd71fa64a64287e330ef536606d213a.zip | |
[libmysql] Fix for missing "ADD_COMPILE_FLAGS" command (#10162)
* [libmysql] Apply patch to prevent configuration error in extra/re2
Configuration of the embedded extra/re2 produces an error on Mac with Clang:
CMake Error at extra/re2/CMakeLists.txt:74 (ADD_COMPILE_FLAGS):
Unknown CMake command "ADD_COMPILE_FLAGS".
cmake/compile_flags.cmake was not included.
* [libmysql] Remove empty directory /lib/plugin/debug after installation
* [libmysql] Update version to 8.0.4-6
* [libmysql] Remove deprecated include(vcpkg_common_functions)
* [libmysql] x64-osx is now expected to pass CI
* [libmysql] Simplify copying of copyright file
* [libmysql] Handle unsupported triplets with vcpkg_fail_port_install
| -rw-r--r-- | ports/libmysql/CONTROL | 2 | ||||
| -rw-r--r-- | ports/libmysql/portfile.cmake | 19 | ||||
| -rw-r--r-- | ports/libmysql/re2_add_compile_flags.patch | 12 | ||||
| -rw-r--r-- | scripts/ci.baseline.txt | 9 |
4 files changed, 23 insertions, 19 deletions
diff --git a/ports/libmysql/CONTROL b/ports/libmysql/CONTROL index 1195fecc2..f3791e9d5 100644 --- a/ports/libmysql/CONTROL +++ b/ports/libmysql/CONTROL @@ -1,5 +1,5 @@ Source: libmysql -Version: 8.0.4-5 +Version: 8.0.4-6 Homepage: https://github.com/mysql/mysql-server Build-Depends: boost-algorithm, boost-geometry, boost-optional, boost-functional, boost-graph, openssl, icu, libevent, liblzma, lz4, zlib Description: A MySQL client library for C development. diff --git a/ports/libmysql/portfile.cmake b/ports/libmysql/portfile.cmake index e179ca714..791a9c5db 100644 --- a/ports/libmysql/portfile.cmake +++ b/ports/libmysql/portfile.cmake @@ -1,21 +1,13 @@ +vcpkg_fail_port_install(ON_TARGET "UWP" ON_ARCH "x86") + if (EXISTS "${CURRENT_INSTALLED_DIR}/include/mysql/mysql.h") message(FATAL_ERROR "FATAL ERROR: libmysql and libmariadb are incompatible.") endif() -if(VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore") - message(FATAL_ERROR "libmysql cannot currently be cross-compiled for UWP") -endif() - -if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x86" AND NOT CMAKE_SYSTEM_NAME OR CMAKE_SYSTEM_NAME STREQUAL "WindowsStore") - message(FATAL_ERROR "Oracle has dropped support in libmysql for 32-bit Windows.") -endif() - if (VCPKG_CMAKE_SYSTEM_NAME STREQUAL "Linux") message(WARNING "libmysql needs ncurses on LINUX, please install ncurses first.\nOn Debian/Ubuntu, package name is libncurses5-dev, on Redhat and derivates it is ncurses-devel.") endif() -include(vcpkg_common_functions) - vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO mysql/mysql-server @@ -26,6 +18,7 @@ vcpkg_from_github( ignore-boost-version.patch system-libs.patch linux_libmysql.patch + re2_add_compile_flags.patch ) file(REMOVE_RECURSE ${SOURCE_PATH}/include/boost_1_65_0) @@ -74,7 +67,8 @@ file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/bin ${CURRENT_PACKAGES_DIR}/docs ${CURRENT_PACKAGES_DIR}/debug/docs - ${CURRENT_PACKAGES_DIR}/lib/debug) + ${CURRENT_PACKAGES_DIR}/lib/debug + ${CURRENT_PACKAGES_DIR}/lib/plugin/debug) # remove misc files file(REMOVE @@ -120,5 +114,4 @@ string(REPLACE "#include <mysql/udf_registration_types.h>" "#include \"mysql/udf file(WRITE ${CURRENT_PACKAGES_DIR}/include/mysql/mysql_com.h "${_contents}") # copy license -file(COPY ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/libmysql) -file(RENAME ${CURRENT_PACKAGES_DIR}/share/libmysql/LICENSE ${CURRENT_PACKAGES_DIR}/share/libmysql/copyright) +file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright) diff --git a/ports/libmysql/re2_add_compile_flags.patch b/ports/libmysql/re2_add_compile_flags.patch new file mode 100644 index 000000000..4734e84f6 --- /dev/null +++ b/ports/libmysql/re2_add_compile_flags.patch @@ -0,0 +1,12 @@ +diff --git a/extra/re2/CMakeLists.txt b/extra/re2/CMakeLists.txt +index ca39db726..965f2c8dc 100644 +--- a/extra/re2/CMakeLists.txt ++++ b/extra/re2/CMakeLists.txt +@@ -71,6 +71,7 @@ IF(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang") + HAVE_TAUTOLOGICAL_UNDEFINED_COMPARE) + IF(HAVE_TAUTOLOGICAL_UNDEFINED_COMPARE) + # Boost source has unused local typedefs. ++ INCLUDE(${MYSQL_CMAKE_SCRIPT_DIR}/compile_flags.cmake) + ADD_COMPILE_FLAGS(${RE2_SOURCES} + COMPILE_FLAGS "-Wno-tautological-undefined-compare") + ENDIF() diff --git a/scripts/ci.baseline.txt b/scripts/ci.baseline.txt index c56c99825..2d51cf546 100644 --- a/scripts/ci.baseline.txt +++ b/scripts/ci.baseline.txt @@ -7,10 +7,10 @@ ## fail - the port does not build in the CI system.
## This is not necessarily the same as if a port is expected to build
## on a developers machine because it may fail due to the machine
-## configuration. When set to fail the CI system will still attempt
+## configuration. When set to fail the CI system will still attempt
## to build the port and will report a CI failure until this file is updated.
## skip - Do not build this port in the CI system.
-## This is added to ports that may be flaky or conflict with other
+## This is added to ports that may be flaky or conflict with other
## ports. Please comment for why a port is skipped so it can be
## removed when the issue is resolved.
## ignore - attempt to build the port, but do not fail the CI test if the
@@ -27,7 +27,7 @@ ## x64-windows
## x64-windows-static
## x86-windows
-##
+##
# Add new items alphabetically
@@ -833,7 +833,6 @@ libmodplug:arm-uwp=fail libmodplug:x64-uwp=fail
libmupdf:x64-linux=fail
libmupdf:x64-osx=fail
-libmysql:x64-osx=fail
libmysql:x86-windows=fail
libnice:x64-linux=fail
libnice:x64-osx=fail
@@ -1540,7 +1539,7 @@ rpclib:x86-windows=ignore rpclib:x64-windows-static=ignore
rttr:arm-uwp=fail
rttr:x64-uwp=fail
-rxspencer:x64-uwp=fail
+rxspencer:x64-uwp=fail
rxspencer:arm-uwp=fail
scintilla:arm-uwp=fail
scintilla:x64-linux=fail
|
