diff --git a/dev-db/soci/files/FindMySQL.cmake b/dev-db/soci/files/FindMySQL.cmake new file mode 100644 index 0000000000000..7860c9f8b1258 --- /dev/null +++ b/dev-db/soci/files/FindMySQL.cmake @@ -0,0 +1,8 @@ +if (NOT TARGET MySQL::MySQL) + set(MySQL_FOUND TRUE) + add_library(MySQL INTERFACE) + target_link_libraries(MySQL INTERFACE ${MySQL_LIBRARIES}) + target_include_directories(MySQL SYSTEM INTERFACE ${MySQL_INCLUDE_DIRS}) + add_library(MySQL::MySQL ALIAS MySQL) +endif() + diff --git a/dev-db/soci/metadata.xml b/dev-db/soci/metadata.xml index 952ddbea1f666..a350429393134 100644 --- a/dev-db/soci/metadata.xml +++ b/dev-db/soci/metadata.xml @@ -16,4 +16,7 @@ soci + + Enable mysql plugin with dev-db/mariadb-connector-c as the client library + diff --git a/dev-db/soci/soci-4.1.2-r1.ebuild b/dev-db/soci/soci-4.1.2-r1.ebuild deleted file mode 100644 index 59941ec9120a1..0000000000000 --- a/dev-db/soci/soci-4.1.2-r1.ebuild +++ /dev/null @@ -1,47 +0,0 @@ -# Copyright 2024-2025 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -inherit cmake - -DESCRIPTION="SOCI - The C++ Database Access Library" -HOMEPAGE="https://sourceforge.net/projects/soci/" -SRC_URI="https://sourceforge.net/projects/soci/files/soci/${P}/${P}.tar.gz/download -> ${P}.tar.gz" - -LICENSE="Boost-1.0" -SLOT="0" -KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86" -IUSE="mysql odbc oracle postgres sqlite static-libs test" -RESTRICT="!test? ( test )" - -CMAKE_SKIP_TESTS=( - soci_odbc_test_mssql - soci_odbc_test_mssql_static - soci_odbc_test_mysql - soci_odbc_test_mysql_static - soci_odbc_test_postgresql - soci_odbc_test_postgresql_static - soci_postgresql_test - soci_postgresql_test_static - soci_mysql_test - soci_mysql_test_static -) - -RDEPEND=" - >=dev-libs/boost-1.85.0-r1 - mysql? ( dev-db/mysql:* ) - odbc? ( dev-db/unixODBC ) - oracle? ( dev-db/oracle-instantclient:=[sdk] ) - postgres? ( dev-db/postgresql:= ) - sqlite? ( dev-db/sqlite ) -" -DEPEND="${RDEPEND}" - -src_configure() { - local mycmakeargs=( - -DSOCI_STATIC="$(usex static-libs)" - -DSOCI_TESTS="$(usex test)" - ) - cmake_src_configure -} diff --git a/dev-db/soci/soci-4.1.2-r2.ebuild b/dev-db/soci/soci-4.1.2-r2.ebuild new file mode 100644 index 0000000000000..43c6c2bb66f5a --- /dev/null +++ b/dev-db/soci/soci-4.1.2-r2.ebuild @@ -0,0 +1,79 @@ +# Copyright 2024-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake toolchain-funcs + +DESCRIPTION="SOCI - The C++ Database Access Library" +HOMEPAGE="https://sourceforge.net/projects/soci/" +SRC_URI="https://sourceforge.net/projects/soci/files/soci/${P}/${P}.tar.gz/download -> ${P}.tar.gz" + +LICENSE="Boost-1.0" +SLOT="0" +KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86" +IUSE="mariadb mysql odbc oracle postgres sqlite test" +REQUIRED_USE="?? ( mysql mariadb )" +RESTRICT="!test? ( test )" + +CMAKE_SKIP_TESTS=( + soci_odbc_test_mssql + soci_odbc_test_mssql_static + soci_odbc_test_mysql + soci_odbc_test_mysql_static + soci_odbc_test_postgresql + soci_odbc_test_postgresql_static + soci_postgresql_test + soci_postgresql_test_static + soci_mysql_test + soci_mysql_test_static +) + +RDEPEND=" + >=dev-libs/boost-1.85.0-r1:= + mysql? ( dev-db/mysql-connector-c:0= ) + mariadb? ( dev-db/mariadb-connector-c:0= ) + odbc? ( dev-db/unixODBC ) + oracle? ( dev-db/oracle-instantclient:=[sdk] ) + postgres? ( dev-db/postgresql:= ) + sqlite? ( dev-db/sqlite ) +" +DEPEND="${RDEPEND}" +BDEPEND=" + virtual/pkgconfig +" + +src_prepare() { + cmake_src_prepare + cp "${FILESDIR}/FindMySQL.cmake" "cmake/find_modules" || die +} + +src_configure() { + local mysql_backend_driver="$(usex mysql 'mysqlclient' "$(usev mariadb 'libmariadb')")" + local mysql_backend_cmake_args=( + ) + if [[ -n "$mysql_backend_driver" ]]; then + local mysql_backend_include="$($(tc-getPKG_CONFIG) --cflags-only-I $mysql_backend_driver)" + local mysql_backend_libs="$($(tc-getPKG_CONFIG) --libs $mysql_backend_driver)" + if [[ -z "$mysql_backend_include" ]] || [[ -z "$mysql_backend_libs" ]]; then + die + fi + mysql_backend_cmake_args=( + -DMySQL_INCLUDE_DIRS="$(echo "$mysql_backend_include" | sed -e 's/-I//')" + -DMySQL_LIBRARIES="$mysql_backend_libs" + ) + fi + local mycmakeargs=( + -DSOCI_STATIC=OFF + -DSOCI_TESTS="$(usex test)" + -DSOCI_DB2=OFF + -DSOCI_FIREBIRD=OFF + -DSOCI_MYSQL="$(usex mysql 'yes' $(usex mariadb))" + -DSOCI_ODBC="$(usex odbc)" + -DSOCI_ORACLE="$(usex oracle)" + -DSOCI_POSTGRESQL="$(usex postgres)" + -DSOCI_SQLITE3="$(usex sqlite)" + "${mysql_backend_cmake_args[@]}" + ) + cmake_src_configure +} diff --git a/net-voip/mumble/mumble-1.6.0_pre20250920-r1.ebuild b/net-voip/mumble/mumble-1.6.0_pre20250920-r2.ebuild similarity index 98% rename from net-voip/mumble/mumble-1.6.0_pre20250920-r1.ebuild rename to net-voip/mumble/mumble-1.6.0_pre20250920-r2.ebuild index d46c83867cf43..a4559593b9144 100644 --- a/net-voip/mumble/mumble-1.6.0_pre20250920-r1.ebuild +++ b/net-voip/mumble/mumble-1.6.0_pre20250920-r2.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2025 Gentoo Authors +# Copyright 1999-2026 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -44,7 +44,7 @@ RESTRICT="!test? ( test )" RDEPEND=" dev-cpp/cli11 - >=dev-db/soci-4.1.0[sqlite] + >=dev-db/soci-4.1.2-r2[sqlite] >=dev-libs/openssl-1.0.0b:0= dev-libs/poco:=[util,xml,zip] >=dev-libs/protobuf-2.2.0:= diff --git a/net-voip/mumble/mumble-9999.ebuild b/net-voip/mumble/mumble-9999.ebuild index d46c83867cf43..a4559593b9144 100644 --- a/net-voip/mumble/mumble-9999.ebuild +++ b/net-voip/mumble/mumble-9999.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2025 Gentoo Authors +# Copyright 1999-2026 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -44,7 +44,7 @@ RESTRICT="!test? ( test )" RDEPEND=" dev-cpp/cli11 - >=dev-db/soci-4.1.0[sqlite] + >=dev-db/soci-4.1.2-r2[sqlite] >=dev-libs/openssl-1.0.0b:0= dev-libs/poco:=[util,xml,zip] >=dev-libs/protobuf-2.2.0:= diff --git a/net-voip/murmur/murmur-1.6.0_pre20250920-r2.ebuild b/net-voip/murmur/murmur-1.6.0_pre20250920-r3.ebuild similarity index 99% rename from net-voip/murmur/murmur-1.6.0_pre20250920-r2.ebuild rename to net-voip/murmur/murmur-1.6.0_pre20250920-r3.ebuild index d7b202d14c942..0628581b280ad 100644 --- a/net-voip/murmur/murmur-1.6.0_pre20250920-r2.ebuild +++ b/net-voip/murmur/murmur-1.6.0_pre20250920-r3.ebuild @@ -49,7 +49,7 @@ RDEPEND=" acct-user/murmur dev-cpp/cli11 dev-cpp/nlohmann_json - >=dev-db/soci-4.1.0[mysql?,postgres?,sqlite?] + >=dev-db/soci-4.1.2-r2[mysql?,postgres?,sqlite?] >=dev-libs/openssl-1.0.0b:0= >=dev-libs/protobuf-2.2.0:= dev-libs/spdlog:= diff --git a/net-voip/murmur/murmur-9999.ebuild b/net-voip/murmur/murmur-9999.ebuild index d7b202d14c942..0628581b280ad 100644 --- a/net-voip/murmur/murmur-9999.ebuild +++ b/net-voip/murmur/murmur-9999.ebuild @@ -49,7 +49,7 @@ RDEPEND=" acct-user/murmur dev-cpp/cli11 dev-cpp/nlohmann_json - >=dev-db/soci-4.1.0[mysql?,postgres?,sqlite?] + >=dev-db/soci-4.1.2-r2[mysql?,postgres?,sqlite?] >=dev-libs/openssl-1.0.0b:0= >=dev-libs/protobuf-2.2.0:= dev-libs/spdlog:=