diff options
author | ormorph <[email protected]> | 2021-11-18 18:26:12 +0300 |
---|---|---|
committer | ormorph <[email protected]> | 2021-11-18 18:30:08 +0300 |
commit | d7dc389201817dc15e7fbc7b3e14afc72c1bf958 (patch) | |
tree | 087942dcf179c08c109f465246ea829967881066 | |
parent | 33e001b3320930daf907f706d44ac91ef27ad408 (diff) | |
download | tde-packaging-gentoo-d7dc389201817dc15e7fbc7b3e14afc72c1bf958.tar.gz tde-packaging-gentoo-d7dc389201817dc15e7fbc7b3e14afc72c1bf958.zip |
Added support for building mariadb in kexi and removed the IUSE variable in the kformula ebuild
Signed-off-by: ormorph <[email protected]>
-rw-r--r-- | trinity-apps/kexi/kexi-14.0.11.ebuild | 24 | ||||
-rw-r--r-- | trinity-apps/kexi/kexi-9999.ebuild | 24 | ||||
-rw-r--r-- | trinity-apps/kexi/metadata.xml | 3 | ||||
-rw-r--r-- | trinity-apps/kformula/kformula-14.0.11.ebuild | 1 | ||||
-rw-r--r-- | trinity-apps/kformula/kformula-9999.ebuild | 1 |
5 files changed, 44 insertions, 9 deletions
diff --git a/trinity-apps/kexi/kexi-14.0.11.ebuild b/trinity-apps/kexi/kexi-14.0.11.ebuild index e4905255..0beec69f 100644 --- a/trinity-apps/kexi/kexi-14.0.11.ebuild +++ b/trinity-apps/kexi/kexi-14.0.11.ebuild @@ -19,12 +19,15 @@ SLOT="14" if [[ ${PV} != *9999* ]] ; then KEYWORDS="~amd64 ~x86" fi -IUSE="mysql postgres" +IUSE="mariadb mysql postgres" + +REQUIRED_USE="mysql? ( !mariadb )" DEPEND="~trinity-base/tdelibs-${PV} ~trinity-apps/koffice-libs-${PV} sys-libs/readline - mysql? ( virtual/mysql ) + mysql? ( dev-db/mysql-connector-c:= ) + mariadb? ( dev-db/mariadb-connector-c:= ) postgres? ( dev-libs/libpqxx )" RDEPEND="$DEPEND" @@ -70,6 +73,15 @@ src_prepare() { sed -i "${S}/kexi/migration/keximigratetest.cpp" \ -e "/TDEApplication/ s|\");|\", true, true, true);|" + if use mariadb ; then + sed -i 's/-lmysqlclient/-lmariadb/' "${S}/kexi/migration/mysql/Makefile.am" || die + sed -i 's/-lmysqlclient/-lmariadb/' "${S}/kexi/kexidb/drivers/mySQL/Makefile.am" || die + sed -i 's/mysql_version.h/mariadb_version.h/' "${S}/kexi/migration/mysql/mysqlmigrate.cpp" || die + sed -i 's/mysql_version.h/mariadb_version.h/' "${S}/kexi/kexidb/drivers/mySQL/mysqlconnection_p.h" || die + sed -i 's/mysql_version.h/mariadb_version.h/' "${S}/kexi/kexidb/drivers/mySQL/mysqldriver.cpp" || die + sed -i 's/mysql_config/mariadb_config/' "${S}/kexi/kexidb/drivers/configure.in.in" || die + fi + trinity-meta-2_src_prepare echo 'all:' > ${S}/Makefile.am @@ -80,8 +92,14 @@ src_prepare() { src_configure() { append-cxxflags "-std=c++11" local myconf=( - $(use_enable mysql) $(use_enable postgres pgsql) ) + if use mysql ; then + myconf+=' --enable-mysql ' + elif use mariadb ; then + myconf+=' --enable-mysql ' + else + myconf+=' --disable-mysql ' + fi trinity-econf ${myconf[@]} } diff --git a/trinity-apps/kexi/kexi-9999.ebuild b/trinity-apps/kexi/kexi-9999.ebuild index e4905255..0beec69f 100644 --- a/trinity-apps/kexi/kexi-9999.ebuild +++ b/trinity-apps/kexi/kexi-9999.ebuild @@ -19,12 +19,15 @@ SLOT="14" if [[ ${PV} != *9999* ]] ; then KEYWORDS="~amd64 ~x86" fi -IUSE="mysql postgres" +IUSE="mariadb mysql postgres" + +REQUIRED_USE="mysql? ( !mariadb )" DEPEND="~trinity-base/tdelibs-${PV} ~trinity-apps/koffice-libs-${PV} sys-libs/readline - mysql? ( virtual/mysql ) + mysql? ( dev-db/mysql-connector-c:= ) + mariadb? ( dev-db/mariadb-connector-c:= ) postgres? ( dev-libs/libpqxx )" RDEPEND="$DEPEND" @@ -70,6 +73,15 @@ src_prepare() { sed -i "${S}/kexi/migration/keximigratetest.cpp" \ -e "/TDEApplication/ s|\");|\", true, true, true);|" + if use mariadb ; then + sed -i 's/-lmysqlclient/-lmariadb/' "${S}/kexi/migration/mysql/Makefile.am" || die + sed -i 's/-lmysqlclient/-lmariadb/' "${S}/kexi/kexidb/drivers/mySQL/Makefile.am" || die + sed -i 's/mysql_version.h/mariadb_version.h/' "${S}/kexi/migration/mysql/mysqlmigrate.cpp" || die + sed -i 's/mysql_version.h/mariadb_version.h/' "${S}/kexi/kexidb/drivers/mySQL/mysqlconnection_p.h" || die + sed -i 's/mysql_version.h/mariadb_version.h/' "${S}/kexi/kexidb/drivers/mySQL/mysqldriver.cpp" || die + sed -i 's/mysql_config/mariadb_config/' "${S}/kexi/kexidb/drivers/configure.in.in" || die + fi + trinity-meta-2_src_prepare echo 'all:' > ${S}/Makefile.am @@ -80,8 +92,14 @@ src_prepare() { src_configure() { append-cxxflags "-std=c++11" local myconf=( - $(use_enable mysql) $(use_enable postgres pgsql) ) + if use mysql ; then + myconf+=' --enable-mysql ' + elif use mariadb ; then + myconf+=' --enable-mysql ' + else + myconf+=' --disable-mysql ' + fi trinity-econf ${myconf[@]} } diff --git a/trinity-apps/kexi/metadata.xml b/trinity-apps/kexi/metadata.xml index d95ac630..a97535d7 100644 --- a/trinity-apps/kexi/metadata.xml +++ b/trinity-apps/kexi/metadata.xml @@ -3,7 +3,8 @@ <pkgmetadata> <!-- maintainer-needed --> <use> - <flag name="mysql">Build with support for <pkg>virtual/mysql</pkg></flag> + <flag name="mariadb">Build with support for <pkg>dev-db/mariadb-connector-c</pkg></flag> + <flag name="mysql">Build with support for <pkg>dev-db/mysql-connector-c</pkg></flag> <flag name="postgres">Build with support for <pkg>dev-libs/libpqxx</pkg></flag> </use> </pkgmetadata> diff --git a/trinity-apps/kformula/kformula-14.0.11.ebuild b/trinity-apps/kformula/kformula-14.0.11.ebuild index 5ed0b9d8..d1c96472 100644 --- a/trinity-apps/kformula/kformula-14.0.11.ebuild +++ b/trinity-apps/kformula/kformula-14.0.11.ebuild @@ -19,7 +19,6 @@ SLOT="14" if [[ ${PV} != *9999* ]] ; then KEYWORDS="~amd64 ~x86" fi -IUSE="mysql postgres" DEPEND="~trinity-apps/koffice-libs-${PV} ~trinity-base/kcontrol-${PV}" diff --git a/trinity-apps/kformula/kformula-9999.ebuild b/trinity-apps/kformula/kformula-9999.ebuild index 5ed0b9d8..d1c96472 100644 --- a/trinity-apps/kformula/kformula-9999.ebuild +++ b/trinity-apps/kformula/kformula-9999.ebuild @@ -19,7 +19,6 @@ SLOT="14" if [[ ${PV} != *9999* ]] ; then KEYWORDS="~amd64 ~x86" fi -IUSE="mysql postgres" DEPEND="~trinity-apps/koffice-libs-${PV} ~trinity-base/kcontrol-${PV}" |