Issue_0048 

Fuego wiki

Login or create account

Issue 0048

Summary
installation of libaio-dev for an emdebian toolchain removes other instances (causing Functional.LTP builds to fail for other boards)
Owner
Tim
Reporter
Tim
Status
closed
Priority
very high

Description [edit section]

'install_cross_toolchain.sh armhf' will install the emdebian armhf toolchain, including the Debian package: libaio-dev:armhf.

In the process, this removes any other libaio-dev package installed in the container. Almost all the files in these packages are identical (man pages, doc, and even /usr/include/libaio.h). However, the /usr/lib/<toolchain_or_arch>/libaio.so symlink is not.

In libaio-dev_0.3.110-1_armfs.deb, it has:

-rw-r--r-- root/root     11630 2014-10-09 04:32 ./usr/lib/arm-linux-gnueabihf/libaio.a
lrwxrwxrwx root/root         0 2014-10-09 04:32 ./usr/lib/arm-linux-gnueabihf/libaio.so -> /lib/arm-linux-gnueabihf/libaio.so.1.0.1

and in libaio-dev_0.3.110-1.amd64.deb is has:

-rw-r--r-- root/root     17358 2014-10-09 04:29 ./usr/lib/x86_64-linux-gnu/libaio.a
lrwxrwxrwx root/root         0 2014-10-09 04:29 ./usr/lib/x86_64-linux-gnu/libaio.so -> /lib/x86_64-linux-gnu/libaio.so.1.0.1

Even though those these particular files (the most important ones) don't conflict, 'apt-get install' will automatically remove the other package before installing the new one, due to overlap of the other files in the packages

'apt-get install' provides no support for overriding this autoremove functionality.

Here are some ideas for fixing this issue:

idea 1 [edit section]

install it with dpkg instead of apt-get.

One possible workaround is to download the new package, and install it with dpkg (ignoring apt's dependencies).

A possible problem with this is if /usr/include/libaio.h ever differed between architectures. This file is shared between all architectures, and would cause hard-to-find compilation problems between different arches.

Nope - that doesn't work (TRB: 2017-08-03). dpkg -i also deletes the other package.

idea 2 [edit section]

extract only the .a and the .so link from the .deb, and install those

Write a custom tool to extract the items from the .deb that are unique to the libaio-dev package for a particular architecture, and install only those.

This ended up being the solution that worked. I put the support directly into install_cross_toolchain.sh. See that script for details of the method used.

Notes [edit section]

This problem might crop up with other '-dev' packages. We should probably see if there are other issues like this lurking with our use of emdebian toolchains.

See https://bitbucket.org/fuegotest/fuego/commits/f3899e414f56eadbf8980ab985b3d309a0dcffa6?at=next for the resolution to this bug.

backlink

Fuego Issues List

TBWiki engine 1.8.3 by Tim Bird