D28284: Add FindMariaDB.cmake module and use it if MySQL is not found

Wolfgang Bauer noreply at phabricator.kde.org
Wed Mar 25 19:23:08 GMT 2020


wbauer added a comment.


  On openSUSE, it doesn't enable MySQLe anymore:
  
     -- Found MySQL: -L/usr/lib64 -lmariadb  
    /usr/bin/mysql_config: unrecognized option '--libmysqld-libs'
    -- Performing Test HAVE_MYSQL_OPT_EMBEDDED_CONNECTION
    -- Performing Test HAVE_MYSQL_OPT_EMBEDDED_CONNECTION - Failed
    -- Could NOT find MySQLe (missing: HAVE_MYSQL_OPT_EMBEDDED_CONNECTION) 
  
  See inline comment for the reason.

INLINE COMMENTS

> FindMySQLe.cmake:82
> +    cmake_push_check_state()
> +    set(CMAKE_REQUIRED_LIBRARIES ${MYSQLE_LIBRARIES})
> +    check_cxx_source_compiles( "#include <mysql.h>\nint main() { int i = MYSQL_OPT_USE_EMBEDDED_CONNECTION; }" HAVE_MYSQL_OPT_EMBEDDED_CONNECTION )

`set(CMAKE_REQUIRED_INCLUDES ${MYSQL_INCLUDE_DIR})` is missing here (it was present in the old FindMySQL.cmake).
Adding it makes the test succeed again here.

REPOSITORY
  R181 Amarok

REVISION DETAIL
  https://phabricator.kde.org/D28284

To: asturmlechner, #amarok, heikobecker, wbauer
Cc: amarok-devel, vmatare, pgomes, nicolamori, jyasi, mfraser, ryanmccoskrie, semareit, eridani, eoinoneill, jackyalcine, nhuisman, paul, domson, yaohanchen, malteveerman, markey, James, tbettler, Smar, ricktimmis, asturmlechner, schweingruber, heikobecker
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/amarok-devel/attachments/20200325/e17f9016/attachment.html>


More information about the Amarok-devel mailing list