FS#78797 - [drumstick] Build fails due to undefined references

Attached to Project: Arch Linux
Opened by Michael Laß (Bevan) - Thursday, 15 June 2023, 19:03 GMT
Last edited by David Runge (dvzrv) - Friday, 16 June 2023, 08:07 GMT
Task Type Bug Report
Category Upstream Bugs
Status Closed
Assigned To David Runge (dvzrv)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

Trying to build drumstick-2.7.2-1 in a clean chroot fails with the following errors (among others):

/usr/bin/ld: CMakeFiles/drumstick-dumpsmf.dir/dumpsmf.cpp.o: in function `QSpySMF::errorHandler(QString const&)':
dumpsmf.cpp:(.text+0x4c): undefined reference to `drumstick::File::QSmf::getFilePos()'
/usr/bin/ld: CMakeFiles/drumstick-dumpsmf.dir/dumpsmf.cpp.o: in function `QSpySMF::QSpySMF()':
dumpsmf.cpp:(.text+0x11f): undefined reference to `drumstick::File::QSmf::QSmf(QObject*)'
/usr/bin/ld: dumpsmf.cpp:(.text+0x12e): undefined reference to `drumstick::File::QSmf::setTextCodec(QTextCodec*)'
/usr/bin/ld: dumpsmf.cpp:(.text+0x135): undefined reference to `drumstick::File::QSmf::signalSMFHeader(int, int, int)'
/usr/bin/ld: dumpsmf.cpp:(.text+0x195): undefined reference to `drumstick::File::QSmf::staticMetaObject'
/usr/bin/ld: dumpsmf.cpp:(.text+0x1e9): undefined reference to `drumstick::File::QSmf::signalSMFTrackStart()'
/usr/bin/ld: dumpsmf.cpp:(.text+0x296): undefined reference to `drumstick::File::QSmf::signalSMFTrackEnd()'
/usr/bin/ld: dumpsmf.cpp:(.text+0x33c): undefined reference to `drumstick::File::QSmf::signalSMFNoteOn(int, int, int)'
/usr/bin/ld: dumpsmf.cpp:(.text+0x3e2): undefined reference to `drumstick::File::QSmf::signalSMFNoteOff(int, int, int)'
/usr/bin/ld: dumpsmf.cpp:(.text+0x488): undefined reference to `drumstick::File::QSmf::signalSMFKeyPress(int, int, int)'
/usr/bin/ld: dumpsmf.cpp:(.text+0x52e): undefined reference to `drumstick::File::QSmf::signalSMFCtlChange(int, int, int)'
/usr/bin/ld: dumpsmf.cpp:(.text+0x5d4): undefined reference to `drumstick::File::QSmf::signalSMFPitchBend(int, int)'
/usr/bin/ld: dumpsmf.cpp:(.text+0x681): undefined reference to `drumstick::File::QSmf::signalSMFProgram(int, int)'
/usr/bin/ld: dumpsmf.cpp:(.text+0x727): undefined reference to `drumstick::File::QSmf::signalSMFChanPress(int, int)'
/usr/bin/ld: dumpsmf.cpp:(.text+0x7cd): undefined reference to `drumstick::File::QSmf::signalSMFSysex(QByteArray const&)'
/usr/bin/ld: dumpsmf.cpp:(.text+0x87f): undefined reference to `drumstick::File::QSmf::signalSMFSeqSpecific(QByteArray const&)'
/usr/bin/ld: dumpsmf.cpp:(.text+0x930): undefined reference to `drumstick::File::QSmf::signalSMFMetaUnregistered(int, QByteArray const&)'
/usr/bin/ld: dumpsmf.cpp:(.text+0x9dd): undefined reference to `drumstick::File::QSmf::signalSMFSequenceNum(int)'
/usr/bin/ld: dumpsmf.cpp:(.text+0xa8f): undefined reference to `drumstick::File::QSmf::signalSMFforcedChannel(int)'
/usr/bin/ld: dumpsmf.cpp:(.text+0xb3a): undefined reference to `drumstick::File::QSmf::signalSMFforcedPort(int)'
/usr/bin/ld: dumpsmf.cpp:(.text+0xbe5): undefined reference to `drumstick::File::QSmf::signalSMFText(int, QString const&)'
/usr/bin/ld: dumpsmf.cpp:(.text+0xc97): undefined reference to `drumstick::File::QSmf::signalSMFendOfTrack()'
/usr/bin/ld: dumpsmf.cpp:(.text+0xd48): undefined reference to `drumstick::File::QSmf::signalSMFTimeSig(int, int, int, int)'
/usr/bin/ld: dumpsmf.cpp:(.text+0xdf5): undefined reference to `drumstick::File::QSmf::signalSMFSmpte(int, int, int, int, int)'
/usr/bin/ld: dumpsmf.cpp:(.text+0xea2): undefined reference to `drumstick::File::QSmf::signalSMFKeySig(int, int)'
/usr/bin/ld: dumpsmf.cpp:(.text+0xf48): undefined reference to `drumstick::File::QSmf::signalSMFTempo(int)'
/usr/bin/ld: dumpsmf.cpp:(.text+0xfd2): undefined reference to `drumstick::File::QSmf::signalSMFError(QString const&)'
/usr/bin/ld: CMakeFiles/drumstick-dumpsmf.dir/dumpsmf.cpp.o: in function `QSpySMF::dump(QString const&, QString const&, QString const&)':
dumpsmf.cpp:(.text+0x1144): undefined reference to `drumstick::File::QSmf::getCurrentTime()'
/usr/bin/ld: dumpsmf.cpp:(.text+0x1173): undefined reference to `drumstick::File::QSmf::getRealTime()'
/usr/bin/ld: CMakeFiles/drumstick-dumpsmf.dir/dumpsmf.cpp.o: in function `/usr/bin/ld: CMakeFiles/drumstick-dumprmi.dir/dumprmi.cpp.o: warning: relocation against `_ZN9drumstick4File4QSmf19signalSMFendOfTrackEv' in read-only section `.text'
QSpySMF::dumpStr(QString const&, QString const&)':
dumpsmf.cpp:(.text+0x126c): undefined reference to `drumstick::File::QSmf::getCurrentTime()'
/usr/bin/ld: dumpsmf.cpp:(.text+0x129c): undefined reference to `drumstick::File::QSmf::getRealTime()'
/usr/bin/ld: CMakeFiles/drumstick-dumpsmf.dir/dumpsmf.cpp.o: in function `QSpySMF::run(QString)':
dumpsmf.cpp:(.text+0x1392): undefined reference to `drumstick::File::QSmf::readFromFile(QString const&)'
/usr/bin/ld: CMakeFiles/drumstick-dumpsmf.dir/dumpsmf.cpp.o: in function `main':
dumpsmf.cpp:(.text.startup+0x4f4): undefined reference to `drumstick::File::QSmf::readFromFile(QString const&)'
/usr/bin/ld: ../../bin/drumstick-dumpsmf: protected symbol `_ZN9drumstick4File4QSmfC1EP7QObject' isn't defined
/usr/bin/ld: final link failed: bad value
collect2: error: ld returned 1 exit status

This is only one of many similar sets of errors. They all are about undefined references to parts of drumstick itself.

Originally, I noticed this issue when trying to compile multiplatform-sonivoxeas (https://github.com/pedrolcl/multiplatform-sonivoxeas/) which links against drumstick. It turns out, very similar errors occur when trying to build vmpk-0.8.8-1 which also links against drumstick.

Interestingly, all those projects build successfully when building them against Qt5 instead of Qt6 (cmake argument -DUSE_QT=5).

You can find my upstream bug report for multiplatform-sonivoxeas at https://github.com/pedrolcl/multiplatform-sonivoxeas/issues/3 but this seems to be a more widespread issue.

A log of my build attempt, including the setup of a clean chroot, is attached.
This task depends upon

Closed by  David Runge (dvzrv)
Friday, 16 June 2023, 08:07 GMT
Reason for closing:  Fixed
Additional comments about closing:  Fixed with drumstick 2.7.2-2
Comment by David Runge (dvzrv) - Thursday, 15 June 2023, 21:21 GMT
I think this is probably related to gcc >= 13 and/or glibc >= 2.37. Will comment on the upstream ticket as well.
Comment by David Runge (dvzrv) - Thursday, 15 June 2023, 21:46 GMT
Hm, looks indeed more like a problem with qt > 6.5. Let's see what upstream can tell us about it.
Comment by David Runge (dvzrv) - Thursday, 15 June 2023, 21:54 GMT Comment by David Runge (dvzrv) - Friday, 16 June 2023, 08:05 GMT
Thanks to @arojas I was able to fix the build using a workaround.
I'll close this and await further fixes from upstream.

Loading...