FS#71509 - [libretro-dolphin] Failed to open libretro core - undefined symbol

Attached to Project: Community Packages
Opened by Arthur Borsboom (ArthurBorsboom) - Wednesday, 14 July 2021, 19:54 GMT
Last edited by Maxime Gauduin (Alucryd) - Thursday, 29 July 2021, 15:42 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Maxime Gauduin (Alucryd)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

After updating Arch libretro does not seem to work anymore; it returns instantly.

Looking at the error in the retroarch.log I am guessing that libretro-dolphin needs to be recompiled against newer libraries.

[ERROR] Failed to open libretro core: "/usr/lib/libretro/dolphin_libretro.so"
Error(s): /usr/lib/libretro/dolphin_libretro.so: undefined symbol: _ZN3fmt2v76detail10vformat_toIcEEvRNS1_6bufferIT_EENS0_17basic_string_viewIS4_EENS0_17basic_format_argsINS0_20basic_fo

It might also be just a misconfiguration on my system, so please don't take my word for it. ;-)

** retroarch 1.9.6-2
** libretro-dolphin 32990-1

The retroarch.log is attached.

Steps to reproduce:
Start libretro: /usr/bin/retroarch -L /usr/lib/libretro/dolphin_libretro.so /share/roms/wii/myrom.iso
This task depends upon

Closed by  Maxime Gauduin (Alucryd)
Thursday, 29 July 2021, 15:42 GMT
Reason for closing:  Fixed
Additional comments about closing:  32990-3
Comment by Arthur Borsboom (ArthurBorsboom) - Saturday, 17 July 2021, 21:36 GMT
I have tried many things with the libretro-dolphin package which did not fix the problem, such as

* Using GCC 10 instead of Clang
* Downgrading to older versions / older commits

What did work is the following.

* Downgrade package fmt 8.0.0-2 --> 7.1.3-1
* Recompile package libretro-dolphin

Is this an issue in fmt, in libretro-dolphin, or both?
And more importantly how to fix this?
Comment by Arthur Borsboom (ArthurBorsboom) - Saturday, 17 July 2021, 22:15 GMT
I believe I have found the cause and the solution.
The fmt package has been released with a bug (the namespace was unchanged), resulting in all kinds of compile warnings, compile errors and probably run-time errors, like the one in this bug report.

* Source: https://github.com/fmtlib/fmt/issues/2374

Because of this mistake, a new version of fmt has been released.

* Source: https://github.com/fmtlib/fmt/releases/tag/8.0.1

I have upgraded fmt to 8.0.1, which is currently in staging.

* Source: https://archlinux.org/packages/staging/x86_64/fmt/

After that I have recompiled libretro-dolphin and it works.
I guess the solution is to wait until fmt 8.0.1 gets out of staging and then recompile and release the libretro-dolphin package.
Comment by Dan Smith (sekin51929) - Tuesday, 27 July 2021, 02:38 GMT
I believe I can confirm a similar issue seen on my end as well.

I updated from 32989-1 to 32990-3, and noticed the core no longer loads with error logs as follows:
[ERROR] [Core Info] Failed to write to core info cache file: /usr/share/libretro/info/core_info.cache
[ERROR] Failed to open libretro core: "/usr/lib/libretro/dolphin_libretro.so"
[ERROR] Error(s): /usr/lib/libretro/dolphin_libretro.so: undefined symbol: _ZN3fmt2v86detail10basic_dataIvE19left_padding_shiftsE

I'm also using retroarch 1.9.6-3, in case that information is useful for anything.
Comment by Maxime Gauduin (Alucryd) - Wednesday, 28 July 2021, 12:20 GMT
I can't reproduce, is your system fully up to date?
Comment by Arthur Borsboom (ArthurBorsboom) - Wednesday, 28 July 2021, 22:47 GMT
I can't reproduce either (I'm the original poster).
After updating fmt to 8.0.1 the problems have been resolved for me.

Which version of fmt are you using?
Comment by Dan Smith (sekin51929) - Thursday, 29 July 2021, 03:43 GMT
Ah, it would seem the fmt package I was using was out of date. The issues occurred due to using fmt 8.0.0-2 with libretro-dolphin 32990-3.

After doing a system update, which brought fmt to 8.0.1-1, the issue went away.

Loading...