Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 667750 - media-tv/kodi-17.6-r5: emerge fails with "Could NOT find MySqlClient..."
Summary: media-tv/kodi-17.6-r5: emerge fails with "Could NOT find MySqlClient..."
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Craig Andrews
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-10-04 17:40 UTC by Tiziano Müller (RETIRED)
Modified: 2018-10-09 20:50 UTC (History)
0 users

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 Tiziano Müller (RETIRED) gentoo-dev 2018-10-04 17:40:11 UTC
first update seems to have worked, but after an `emerge --depclean`, `ldd /usr/lib64/kodi/kodi.bin` gives me:

  [...]
  libmysqlclient.so.18 => not found
  [...]

and when trying to reinstall the package, I get:

[...]
-- Found MicroHttpd: /usr/lib/libmicrohttpd.so (found version "0.9.59") 
CMake Error at /usr/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:137 (message):
  Could NOT find MySqlClient (missing: MYSQLCLIENT_LIBRARY
  MYSQLCLIENT_INCLUDE_DIR)
Call Stack (most recent call first):
  /usr/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
  modules/FindMySqlClient.cmake:42 (find_package_handle_standard_args)
  scripts/common/Macros.cmake:399 (find_package)
  CMakeLists.txt:144 (core_optional_dep)
Comment 1 Craig Andrews gentoo-dev 2018-10-04 17:45:27 UTC
Can you please post your builds log? I'm curious to learn what use flags are being used fro media-tv/kodi

Also, do you have either of dev-db/mysql-connector-c or dev-db/mariadb-connector-c installed (if so, which)?
Comment 2 Tiziano Müller (RETIRED) gentoo-dev 2018-10-04 17:59:47 UTC
I've used USE="mysql mariadb", therefore dev-db/mariadb-connector-c is/was installed. After installing "dev-db/mysql-connector-c" compilation succeeded (did not need full mariadb).

The problem are the hardcoded paths here:
  https://github.com/xbmc/xbmc/blob/Krypton/project/cmake/modules/FindMySqlClient.cmake#L24 

For mariadb this should be "mariadb/mysql.h".
Comment 3 Craig Andrews gentoo-dev 2018-10-04 18:12:08 UTC
Could you please test this patch https://github.com/xbmc/xbmc/commit/db0a931f3dd2ed6012d1c7f6bd5ca94b86bde860.patch and see if it resolves the compatbility problem with dev-db/mariadb-connector-c ?
Comment 4 Tiziano Müller (RETIRED) gentoo-dev 2018-10-04 19:48:32 UTC
No, it doesn't. While it can now find the include directory, it fails with the library:

CMake Error at /usr/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:137 (message):
  Could NOT find MySqlClient (missing: MYSQLCLIENT_LIBRARY)
Call Stack (most recent call first):
  /usr/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
  modules/FindMySqlClient.cmake:42 (find_package_handle_standard_args)
  scripts/common/Macros.cmake:399 (find_package)
  CMakeLists.txt:144 (core_optional_dep)

From here: https://github.com/xbmc/xbmc/blob/7e52c1d94d0cbc3f8ace57b1fc74ae1582c5a869/project/cmake/modules/FindMySqlClient.cmake#L25

... the library is named:
/usr/lib64/libmariadb.so.3

btw, the problem with that patch is that it will pick up first mysql-connector-c if that is installed. Maybe better backport from the next kodi version instead, where it is solved properly?

https://github.com/xbmc/xbmc/blob/master/CMakeLists.txt#L178
https://github.com/xbmc/xbmc/blob/master/cmake/modules/FindMariaDBClient.cmake
Comment 5 Craig Andrews gentoo-dev 2018-10-08 18:37:41 UTC
Backporting this won't be a lot of fun, Kodi build system changes a lot between versions 17 and 18. I'm tempted to just removed mariadb support from Kodi 17.

BTW, as you said, this should work well with Kodi 18, so you can try that version too.
Comment 6 Craig Andrews gentoo-dev 2018-10-09 18:15:46 UTC
Can you please try again but with the "mysqlcompat" use flag set on dev-db/mariadb-connector-c? I suspect media-tv/kodi-17.6-r5 will then work fine.
Comment 7 Larry the Git Cow gentoo-dev 2018-10-09 20:50:33 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=99380603e8cb5ff015392163ea23e78a87b6e04f

commit 99380603e8cb5ff015392163ea23e78a87b6e04f
Author:     Craig Andrews <candrews@gentoo.org>
AuthorDate: 2018-10-09 18:21:07 +0000
Commit:     Craig Andrews <candrews@gentoo.org>
CommitDate: 2018-10-09 20:50:23 +0000

    media-tv/kodi: Consistency of mysql/mariadb use flags, fix mariadb
    
    Bug: https://bugs.gentoo.org/667918
    Closes: https://bugs.gentoo.org/667750
    Signed-off-by: Craig Andrews <candrews@gentoo.org>
    Package-Manager: Portage-2.3.50, Repoman-2.3.11

 media-tv/kodi/kodi-17.6-r6.ebuild | 295 ++++++++++++++++++++++++++++++++++++++
 media-tv/kodi/kodi-17.6.ebuild    |   2 +-
 2 files changed, 296 insertions(+), 1 deletion(-)