Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 710082 - dev-db/mysql++-2,3,2-r1 compile error with too recent mariadb or mysql
Summary: dev-db/mysql++-2,3,2-r1 compile error with too recent mariadb or mysql
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Linux MySQL bugs team
URL:
Whiteboard:
Keywords:
Depends on: 710362
Blocks:
  Show dependency tree
 
Reported: 2020-02-18 18:29 UTC by Jack
Modified: 2021-03-10 22:42 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jack 2020-02-18 18:29:03 UTC
Compiling dev-db/mysql++-2.3.2-r1 (with mariadb-10.2.29) fails with several

/lib/options.cpp: In member function 'virtual mysqlpp::Option::Error mysqlpp::GuessConnectionOption::set(mysqlpp::DBDriver*)':
./lib/options.cpp:72:20: error: 'MYSQL_OPT_GUESS_CONNECTION' was not declared in this scope; did you mean 'MYSQL_OPT_RECONNECT'?
   72 |    dbd->set_option(MYSQL_OPT_GUESS_CONNECTION) ?
      |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~
      |                    MYSQL_OPT_RECONNEC

Reproducible: Always

Steps to Reproduce:
1. emerge dev-db/mysql++-3.2.3-r1
2.
3.



https://tangentsoft.com/mysqlpp/tktview?name=5e73e7ddd8 is a mysql++ bug from 2018-07-12  "This is due to the removal of the libmysqld embedded DB server feature in MySQL 8.0.1. I don't have that version here at the moment, but I think I've got it fixed on trunk as of checkin [5767708cd6]."  I tried that patch (had to add a/ and b/ to the file names) and it still failed with the same errors, but I'm wondering if that might be because the refer to mariadb versions differently from Gentoo.  I'll keep looking and update if I find anything new.
Comment 1 Jack 2020-02-20 22:26:32 UTC
I think I might have figured it out - but if I'm right, I have no idea how to proceed.  The file which errors out includes (through it's own .h file) mysql.h.  I have two copies of that file on my system.
/usr/include/mariadb/mysql.h (belongs to mariadb-connector-c-3.1.6) which does have MYSQL_OPT_GUESS_CONNECTION, and
/usr/include/mysql/mysql.h (belongs to mysql-connector-c-8.0.19) which does not.  With the patch, it knows that that version of mysql does not have that option defined, but it thinks that mariadb (any version) does have it.

I have mariadb-10.2.29 and no mysql installed.  dev-db/mysql-connector-c-8.0.19 pulled in by:
    dev-db/mysql++-3.2.3-r1 requires dev-db/mysql-connector-c:=
    dev-db/mysql-connector-c++-8.0.19 requires >=dev-db/mysql-connector-c-6.1.8:=, >=dev-db/mysql-connector-c-6.1.8:0/21=
    dev-db/mysql-init-scripts-2.3-r3 requires dev-db/mysql-connector-c
    dev-perl/DBD-mysql-4.50.0 requires dev-db/mysql-connector-c:0/21=, dev-db/mysql-connector-c:=
    dev-qt/qtsql-5.13.2 requires dev-db/mysql-connector-c:=, dev-db/mysql-connector-c:0/21=
    net-analyzer/ntopng-3.8.1-r3 requires dev-db/mysql-connector-c:=, dev-db/mysql-connector-c:0/21=

So is it the case that mariadb-connector-c is not a full replacement for mysql-connector-c or do we need a virtual for mysql-connector-c?  (There is no mariadb-connector-c++.)  Or, should the build mechanism be using "-I /usr/include/mariadb" instead of "-I /usr/include/mysql"?
Comment 2 Thomas Deutschmann (RETIRED) gentoo-dev 2020-02-20 22:35:51 UTC
You need to upgrade to =dev-db/mysql++-3.2.5. Could you please test? If you can confirm that this version works for you I'll start stabilization.
Comment 3 Jack 2020-02-21 00:35:55 UTC
=dev-db/mysql++-3.2.5 emerges without error, but @preserved-rebuild after that fails on dev-db/mysql-workbench-8.0.16, but I see there is already 
https://bugs.gentoo.org/710022 for that, so this can probably be closed pending stabilization of =dev-db/mysql++-3.2.5  (skipping 3.2.4?)
Comment 4 Thomas Deutschmann (RETIRED) gentoo-dev 2020-02-21 00:44:48 UTC
Yeah, we skip 3.2.4. Thanks for testing!
Comment 5 Jack 2021-01-02 20:32:15 UTC
3.2.5 looks stable to me - can this now be closed?  (I am not certain if the mysql-workbench bug was ever truly fixed, but that package has been tree-cleaned due to python2.7 dependency.)
Comment 6 Jack 2021-03-10 21:24:27 UTC
Mainly out of curiosity, are there problems on arch's other than amd64, or is this just low priority?  (I only have amd64, or else I'd help test.)
Comment 7 Thomas Deutschmann (RETIRED) gentoo-dev 2021-03-10 22:42:33 UTC
It was just forgotten to close this bug.