Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 793740 - app-misc/mosquitto (all versions) cannot be cross-compiled by arm
Summary: app-misc/mosquitto (all versions) cannot be cross-compiled by arm
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Matt Turner
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: tc-directly
  Show dependency tree
 
Reported: 2021-06-01 18:05 UTC by Jean-Claude Gervais
Modified: 2021-11-07 02:17 UTC (History)
1 user (show)

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


Attachments
build.log (build.log,30.64 KB, text/plain)
2021-06-01 18:18 UTC, Jean-Claude Gervais
Details
Output of aarch64-unknown-linux-gnu-emerge --info (emerge.info,2.71 KB, application/x-info)
2021-06-01 18:20 UTC, Jean-Claude Gervais
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jean-Claude Gervais 2021-06-01 18:05:59 UTC
Invoking a crossdev make of mosquitto (all versions)
aarch64-unknown-linux-gnu-emerge mosquitto

In all cases, build terminates like so

c++ -I. -I.. -I../include -I../../include -DWITH_THREADING -DWITH_SOCKS -DWITH_UNIX_SOCKETS -I../deps -O2 -pipe -fomit-frame-pointer -fPIC -c mosquittopp.cpp -o mosquittopp.o
c++ -shared -Wl,-soname,libmosquittopp.so.1 mosquittopp.o -o libmosquittopp.so.1 ../libmosquitto.so.1
/usr/lib/gcc/x86_64-pc-linux-gnu/9.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: ../libmosquitto.so.1: error adding symbols: file in wrong format
collect2: error: ld returned 1 exit status

At link, the ebuild seems to ignore the cross-compile settings and instead directly invokes the default system compiler/linker
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-06-01 18:07:54 UTC
Please include the full build.log and emerge --info.
Comment 2 Jean-Claude Gervais 2021-06-01 18:18:08 UTC
Created attachment 713187 [details]
build.log
Comment 3 Jean-Claude Gervais 2021-06-01 18:20:25 UTC
Created attachment 713190 [details]
Output of aarch64-unknown-linux-gnu-emerge --info
Comment 4 Larry the Git Cow gentoo-dev 2021-11-07 02:17:57 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=91587a4954346e8c465173a85a13f470d9329fa4

commit 91587a4954346e8c465173a85a13f470d9329fa4
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2021-11-07 02:17:30 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2021-11-07 02:17:30 +0000

    app-misc/mosquitto: don't call c++ directly (fixes cross-compilation)
    
    Closes: https://bugs.gentoo.org/793740
    Signed-off-by: Sam James <sam@gentoo.org>

 app-misc/mosquitto/mosquitto-1.6.15.ebuild | 1 +
 app-misc/mosquitto/mosquitto-2.0.11.ebuild | 1 +
 app-misc/mosquitto/mosquitto-2.0.12.ebuild | 1 +
 3 files changed, 3 insertions(+)