← Back to team overview

maria-developers team mailing list archive

crosscompiling in buildroot: cannot find -laio and other link error



I'm trying to get the latest version of mariadb-galera (10.0.21) into
buildroot. I'm running into two errors which I have a feeling are
related. But I may be wrong.

These problems arise during the build of the host variant of the
package. I get the two following errors (build does not stop at the
first one because they happen in parallel jobs):

Linking CXX shared module ha_connect.so
error adding symbols: File in wrong format

 --> for host variant ha_connect.so should be linked against

Linking CXX shared module ha_innodb.so
/usr/bin/ld: cannot find -laio

The thing is, libaio and libxml2 are both present in

The link command present in
(http://pastebin.com/Qn1ZCw2X) contains:
which is incorrect, should be:

The link command present in
(http://pastebin.com/it6W9WVs) does not contain
-L/home/sylvain/git/br/output/host/usr/lib/. I think it should. At
least, when I manually run this command adding
-L/home/sylvain/git/br/output/host/usr/lib, it works.

I'm really not sure how these link.txt are generated. I checked
connect/CMakeLists.txt and innobase/CMakeLists.txt and could not find
anything obvious problem. Beside, toplevel CMakeCache.txt does contain:
which seems correct. I don't know why this setting does not reach
storage/innobase and I'm also not sure why ha_connect.so tries to link
against target variant of libxml2.

It basically comes down to have cmake look for shared libraries in the
right place, but I don't seem to be able to determine which lever to
pull. Any hint as to how to achieve that is therefore welcome.


Sylvain Raybaud

Follow ups