Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mysqlcpp: add recipe #24678

Open
wants to merge 124 commits into
base: master
Choose a base branch
from
Open

mysqlcpp: add recipe #24678

wants to merge 124 commits into from

Conversation

husitawi
Copy link

@husitawi husitawi commented Jul 21, 2024

Summary

Add new recipe: mysqlcpp/9.0.0

Motivation

No C++ MySQL connector recipe available.

Details

No changes. New recipe with test package.

closes samuaz#2
closes #16312
closes #374
closes #17594


@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@husitawi husitawi marked this pull request as ready for review July 26, 2024 06:13
@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@CLAassistant
Copy link

CLAassistant commented Jul 26, 2024

CLA assistant check
All committers have signed the CLA.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@valgur valgur mentioned this pull request Sep 6, 2024
3 tasks
@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@valgur
Copy link
Contributor

valgur commented Sep 9, 2024

@husitawi I looked into the recipe for the project and found the two culprits for most of the issues you are encountering. See #25170.

@conan-center-bot
Copy link
Collaborator

Conan v1 pipeline ❌

Failure in build 125 (1103fdc02188bb27ede5e32041c00c66f72b28e8):

  • mysql-connector-cpp/9.0.0:
    CI failed to create some packages (All logs)

    Logs for packageID f47b14d9bc6110f83e6e268a34c1413b3c1c0987:
    [settings]
    arch=x86_64
    build_type=Debug
    compiler=gcc
    compiler.libcxx=libstdc++11
    compiler.version=11
    os=Linux
    [options]
    mysql-connector-cpp:shared=False
    
    [...]
    mysql-connector-cpp/9.0.0: 
    CMake Deprecation Warning at CMakeLists.txt:32 (CMAKE_POLICY):
      Compatibility with CMake < 3.5 will be removed from a future version of
      CMake.
    
      Update the VERSION argument <min> value or use a ...<max> suffix to tell
      CMake that the project does not need compatibility with older versions.
    
    
    === Booststrap ===
    -- generator: Unix Makefiles
    -- build type: Debug
    -- ----
    === Booststrap done ===
    Building version 9.0.0
    Building on system: Linux-6.1.85+ (x86_64)
    Using cmake generator: Unix Makefiles
    Using toolset: 
    Building 64bit code
    Building static connector library
    CMake Deprecation Warning at cdk/CMakeLists.txt:33 (cmake_policy):
      Compatibility with CMake < 3.5 will be removed from a future version of
      CMake.
    
      Update the VERSION argument <min> value or use a ...<max> suffix to tell
      CMake that the project does not need compatibility with older versions.
    
    
    Configuring CDK as part of MySQL_CONCPP project
    Skipping second declaration of config option: THROW_AS_ASSERT (found in: /home/conan/workspace/prod-v1/bsr/94658/fbacf/.conan/data/mysql-connector-cpp/9.0.0/_/_/build/f47b14d9bc6110f83e6e268a34c1413b3c1c0987/src/cdk/CMakeLists.txt)
    CMake Error at cdk/cmake/dependency.cmake:512 (find_library):
      Could not find library using the following names: protobuf, libprotobuf
    Call Stack (most recent call first):
      cdk/cmake/dependency.cmake:422 (add_ext_lib)
      cdk/cmake/DepFindProtobuf.cmake:62 (add_ext_targets)
      cdk/cmake/dependency.cmake:47 (include)
      cdk/protocol/mysqlx/CMakeLists.txt:29 (find_dependency)
    
    
    WARN: *** Conan 1 is legacy and on a deprecation path ***
    WARN: *** Please upgrade to Conan 2 ***
    WARN: openssl/3.3.1: requirement zlib/[>=1.2.11 <2] overridden by mysql-connector-cpp/9.0.0 to zlib/1.3.1 
    WARN: protobuf/3.21.12: requirement zlib/[>=1.2.11 <2] overridden by mysql-connector-cpp/9.0.0 to zlib/1.3.1 
    mysql-connector-cpp/9.0.0: WARN: Using the new toolchains and generators without specifying a build profile (e.g: -pr:b=default) is discouraged and might cause failures and unexpected behavior
    mysql-connector-cpp/9.0.0: WARN: Using the new toolchains and generators without specifying a build profile (e.g: -pr:b=default) is discouraged and might cause failures and unexpected behavior
    mysql-connector-cpp/9.0.0: ERROR: Package 'f47b14d9bc6110f83e6e268a34c1413b3c1c0987' build failed
    mysql-connector-cpp/9.0.0: WARN: Build folder /home/conan/workspace/prod-v1/bsr/94658/fbacf/.conan/data/mysql-connector-cpp/9.0.0/_/_/build/f47b14d9bc6110f83e6e268a34c1413b3c1c0987/build/Debug
    ERROR: mysql-connector-cpp/9.0.0: Error in build() method, line 199
    	cmake.configure()
    	ConanException: Error 1 while executing cmake -G "Unix Makefiles" -DCMAKE_TOOLCHAIN_FILE="/home/conan/workspace/prod-v1/bsr/94658/fbacf/.conan/data/mysql-connector-cpp/9.0.0/_/_/build/f47b14d9bc6110f83e6e268a34c1413b3c1c0987/build/Debug/generators/conan_toolchain.cmake" -DCMAKE_INSTALL_PREFIX="/home/conan/workspace/prod-v1/bsr/94658/fbacf/.conan/data/mysql-connector-cpp/9.0.0/_/_/package/f47b14d9bc6110f83e6e268a34c1413b3c1c0987" -DWITH_SSL="/home/conan/workspace/prod-v1/bsr/94658/fbacf/.conan/data/openssl/3.3.1/_/_/package/ea45daa7db3dac72b5ae25271b378c1b20061dea" -DOPENSSL_ROOT_DIR="/home/conan/workspace/prod-v1/bsr/94658/fbacf/.conan/data/openssl/3.3.1/_/_/package/ea45daa7db3dac72b5ae25271b378c1b20061dea" -DWITH_LZ4="/home/conan/workspace/prod-v1/bsr/94658/fbacf/.conan/data/lz4/1.10.0/_/_/package/be27726f9885116da1158027505be62e913cd585" -DWITH_ZLIB="/home/conan/workspace/prod-v1/bsr/94658/fbacf/.conan/data/zlib/1.3.1/_/_/package/be27726f9885116da1158027505be62e913cd585" -DWITH_ZSTD="/home/conan/workspace/prod-v1/bsr/94658/fbacf/.conan/data/zstd/1.5.6/_/_/package/2177ebad8f53eadc62cd13ac2535f24587cb3ca5" -DBUILD_STATIC="ON" -DBUILD_SHARED_LIBS="OFF" -DBOOST_DIR="FALSE" -DWITH_PROTOBUF="/home/conan/workspace/prod-v1/bsr/94658/fbacf/.conan/data/protobuf/3.21.12/_/_/package/d0dc15bd1c53d3bfb809f9d49d6162baddf534f4" -DRAPIDJSON_INCLUDE_DIR="/home/conan/workspace/prod-v1/bsr/94658/fbacf/.conan/data/rapidjson/1.1.0/_/_/package/5ab84d6acfe1f23c4fae0ab88f26e3a396351ac9/include" -DCMAKE_POLICY_DEFAULT_CMP0091="NEW" -DCMAKE_BUILD_TYPE="Debug" "/home/conan/workspace/prod-v1/bsr/94658/fbacf/.conan/data/mysql-connector-cpp/9.0.0/_/_/build/f47b14d9bc6110f83e6e268a34c1413b3c1c0987/src"
    

Note: To save resources, CI tries to finish as soon as an error is found. For this reason you might find that not all the references have been launched or not all the configurations for a given reference. Also, take into account that we cannot guarantee the order of execution as it depends on CI workload and workers availability.


Conan v2 pipeline ❌

Note: Conan v2 builds are now mandatory. Please read our discussion about it.

The v2 pipeline failed. Please, review the errors and note this is required for pull requests to be merged. In case this recipe is still not ported to Conan 2.x, please, ping @conan-io/barbarians on the PR and we will help you.

Failure in build 125 (1103fdc02188bb27ede5e32041c00c66f72b28e8):

  • mysql-connector-cpp/9.0.0:
    CI failed to create some packages (All logs)

    Logs for packageID 3acb189eb808929f3ad751e72be2d5704d2e9508:
    [settings]
    arch=x86_64
    build_type=Release
    compiler=apple-clang
    compiler.cppstd=17
    compiler.libcxx=libc++
    compiler.version=13
    os=Macos
    [options]
    */*:shared=False
    
    [...]
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/b/mysql48f73dd3c30e3/p/lib/libmysqlcppconnx-static.a(libcrypto-lib-eng_lib.o)
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/opensd6b8f43d10789/p/lib/libcrypto.a(libcrypto-lib-eng_lib.o)
    duplicate symbol '_ENGINE_get_ex_data' in:
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/b/mysql48f73dd3c30e3/p/lib/libmysqlcppconnx-static.a(libcrypto-lib-eng_lib.o)
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/opensd6b8f43d10789/p/lib/libcrypto.a(libcrypto-lib-eng_lib.o)
    duplicate symbol '_do_engine_lock_init_ossl_ret_' in:
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/b/mysql48f73dd3c30e3/p/lib/libmysqlcppconnx-static.a(libcrypto-lib-eng_lib.o)
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/opensd6b8f43d10789/p/lib/libcrypto.a(libcrypto-lib-eng_lib.o)
    duplicate symbol '_do_engine_lock_init_ossl_' in:
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/b/mysql48f73dd3c30e3/p/lib/libmysqlcppconnx-static.a(libcrypto-lib-eng_lib.o)
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/opensd6b8f43d10789/p/lib/libcrypto.a(libcrypto-lib-eng_lib.o)
    duplicate symbol '_OPENSSL_wipe_cpu' in:
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/b/mysql48f73dd3c30e3/p/lib/libmysqlcppconnx-static.a(libcrypto-lib-x86_64cpuid.o)
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/opensd6b8f43d10789/p/lib/libcrypto.a(libcrypto-lib-x86_64cpuid.o)
    duplicate symbol '_OPENSSL_instrument_bus' in:
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/b/mysql48f73dd3c30e3/p/lib/libmysqlcppconnx-static.a(libcrypto-lib-x86_64cpuid.o)
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/opensd6b8f43d10789/p/lib/libcrypto.a(libcrypto-lib-x86_64cpuid.o)
    duplicate symbol '_OPENSSL_ia32_rdrand_bytes' in:
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/b/mysql48f73dd3c30e3/p/lib/libmysqlcppconnx-static.a(libcrypto-lib-x86_64cpuid.o)
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/opensd6b8f43d10789/p/lib/libcrypto.a(libcrypto-lib-x86_64cpuid.o)
    duplicate symbol '_OPENSSL_ia32_rdseed_bytes' in:
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/b/mysql48f73dd3c30e3/p/lib/libmysqlcppconnx-static.a(libcrypto-lib-x86_64cpuid.o)
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/opensd6b8f43d10789/p/lib/libcrypto.a(libcrypto-lib-x86_64cpuid.o)
    duplicate symbol '_CRYPTO_memcmp' in:
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/b/mysql48f73dd3c30e3/p/lib/libmysqlcppconnx-static.a(libcrypto-lib-x86_64cpuid.o)
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/opensd6b8f43d10789/p/lib/libcrypto.a(libcrypto-lib-x86_64cpuid.o)
    duplicate symbol '_OPENSSL_cleanse' in:
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/b/mysql48f73dd3c30e3/p/lib/libmysqlcppconnx-static.a(libcrypto-lib-x86_64cpuid.o)
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/opensd6b8f43d10789/p/lib/libcrypto.a(libcrypto-lib-x86_64cpuid.o)
    duplicate symbol '_OPENSSL_ia32_cpuid' in:
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/b/mysql48f73dd3c30e3/p/lib/libmysqlcppconnx-static.a(libcrypto-lib-x86_64cpuid.o)
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/opensd6b8f43d10789/p/lib/libcrypto.a(libcrypto-lib-x86_64cpuid.o)
    duplicate symbol '_OPENSSL_atomic_add' in:
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/b/mysql48f73dd3c30e3/p/lib/libmysqlcppconnx-static.a(libcrypto-lib-x86_64cpuid.o)
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/opensd6b8f43d10789/p/lib/libcrypto.a(libcrypto-lib-x86_64cpuid.o)
    duplicate symbol '_OPENSSL_rdtsc' in:
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/b/mysql48f73dd3c30e3/p/lib/libmysqlcppconnx-static.a(libcrypto-lib-x86_64cpuid.o)
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/opensd6b8f43d10789/p/lib/libcrypto.a(libcrypto-lib-x86_64cpuid.o)
    duplicate symbol '_OPENSSL_instrument_bus2' in:
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/b/mysql48f73dd3c30e3/p/lib/libmysqlcppconnx-static.a(libcrypto-lib-x86_64cpuid.o)
        /Users/jenkins/workspace/prod-v2/bsr/84708/cdcbe/p/opensd6b8f43d10789/p/lib/libcrypto.a(libcrypto-lib-x86_64cpuid.o)
    ld: 95 duplicate symbols for architecture x86_64
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    make[2]: *** [PackageTest] Error 1
    make[1]: *** [CMakeFiles/PackageTest.dir/all] Error 2
    make: *** [all] Error 2
    
    ERROR: mysql-connector-cpp/9.0.0 (test package): Error in build() method, line 18
    	cmake.build()
    	ConanException: Error 2 while executing
    

Note: To save resources, CI tries to finish as soon as an error is found. For this reason you might find that not all the references have been launched or not all the configurations for a given reference. Also, take into account that we cannot guarantee the order of execution as it depends on CI workload and workers availability.

tc.cache_variables["BUILD_STATIC"] = not self.options.shared
tc.cache_variables["BUILD_SHARED_LIBS"] = self.options.shared
# Disable Boost, only legacy JDBC connector needs it
tc.cache_variables["BOOST_DIR"] = "FALSE"
Copy link

@samuaz samuaz Nov 21, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

are not supporting JDBC? in this PR
#17594
i added support to it.

i think there is still useful to support the old JDBC connector for services that are using mysql server 6x

@samuaz
Copy link

samuaz commented Nov 21, 2024

I really advocate supporting the JDBC connector as I was including in my PR

#17594

There are still a lot of projects using it.

It is one of the reasons I was trying to add this mysql package to Conan also

@perseoGI
Copy link
Contributor

@samuaz I consider it will be better for all if we joint or work in a same PR.
Would you mind to add the JDBC support to this PR and try to make the CI pass?

@valgur
Copy link
Contributor

valgur commented Nov 21, 2024

@perseoGI #25170

@samuaz
Copy link

samuaz commented Nov 21, 2024

@samuaz I consider it will be better for all if we joint or work in a same PR. Would you mind to add the JDBC support to this PR and try to make the CI pass?

@perseoGI
guys, add the JDBC support here is basically retake my PR.

Not offense, but really don't understand why redo the same things many times. My PR was there from May 17, 2023

i don't have a problem working on this… .but is basically cherry-pick my changes so....

So what's the plan, i need to create a branch using this as a base, add JDBC and send a PR to this branch?

@samuaz samuaz mentioned this pull request Nov 21, 2024
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[request] mysql_connector_cpp/8.0.32 [request] mysql-connector-cpp/8.0
7 participants