[debian-mysql] Bug#933151: mariadb-10.3: FTBFS on riscv64

Aurelien Jarno aurelien at aurel32.net
Mon Sep 28 22:22:40 BST 2020


On 2020-09-28 15:12, Otto Kekäläinen wrote:
> After uploading mariadb-10.5 1:10.5.5-1 to Debian the build still
> fails with these:
> 
> /usr/bin/ld: /usr/include/c++/10/bits/atomic_base.h:464: undefined
> reference to `__atomic_compare_exchange_1'
> 
> The odd thing is that an identical build on Ubuntu Groovy passes OK:
> https://launchpadlibrarian.net/499652421/buildlog_ubuntu-groovy-riscv64.mariadb-10.5_1%3A10.5.5-1~ubuntu20.10.1~1601274184.7ad164279+master_BUILDING.txt.gz

Ubuntu has patched their version of cmake to link with -latomic on
riscv64. While patching cmake is a really good idea, the fix is wrong,
the correct think to do is to link with -pthread instead of -lpthread,
and do that for all architectures.

This is the strategy followed for mariadb-10.5 in the attached patch. I
have tested it and it builds fine on Debian.

Aurelien

-- 
Aurelien Jarno                          GPG: 4096R/1DDD8C9B
aurelien at aurel32.net                 http://www.aurel32.net
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mariadb-10.5.riscv64.patch
Type: text/x-diff
Size: 785 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/pkg-mysql-maint/attachments/20200928/b2ec20b8/attachment.patch>


More information about the pkg-mysql-maint mailing list