free-audio / clap-host

Reference Host
MIT License
49 stars 14 forks source link

Build fails on Fedora 36 #17

Open ghost opened 2 years ago

ghost commented 2 years ago

Bash log:

$ cmake --build --preset ninja-system
[1/3] Building CXX object host/CMakeFi...t.dir/Debug/audio-settings-widget.cc.o
FAILED: host/CMakeFiles/clap-host.dir/Debug/audio-settings-widget.cc.o 
/usr/lib64/ccache/c++ -DQT_CORE_LIB -DQT_GUI_LIB -DQT_WIDGETS_LIB -DCMAKE_INTDIR=\"Debug\" -I/home/<redacted>/Desktop/clap-host/builds/ninja-system/host -I/home/<redacted>/Desktop/clap-host/host -I/home/<redacted>/Desktop/clap-host/builds/ninja-system/host/clap-host_autogen/include_Debug -I/home/<redacted>/Desktop/clap-host/clap-helpers/include -I/home/<redacted>/Desktop/clap-host/clap/include -isystem /usr/include/qt6/QtWidgets -isystem /usr/include/qt6 -isystem /usr/include/qt6/QtCore -isystem /usr/lib64/qt6/mkspecs/linux-g++ -isystem /usr/include/qt6/QtGui -isystem /usr/include/rtmidi -isystem /usr/include/rtaudio -g -fvisibility=hidden -fvisibility-inlines-hidden -Werror=return-type -Werror=unused-result -Wno-unused-parameter -Wuninitialized -Wvla -Wmultichar -Werror=non-virtual-dtor -Woverloaded-virtual -pthread -D__UNIX_JACK__ -D__LINUX_ALSA__ -D_REENTRANT -D__LINUX_PULSE__ -Winvalid-pch -include /home/<redacted>/Desktop/clap-host/builds/ninja-system/host/CMakeFiles/clap-host.dir/Debug/cmake_pch.hxx -MD -MT host/CMakeFiles/clap-host.dir/Debug/audio-settings-widget.cc.o -MF host/CMakeFiles/clap-host.dir/Debug/audio-settings-widget.cc.o.d -o host/CMakeFiles/clap-host.dir/Debug/audio-settings-widget.cc.o -c /home/<redacted>/Desktop/clap-host/host/audio-settings-widget.cc
/home/<redacted>/Desktop/clap-host/host/audio-settings-widget.cc: In member function ‘void AudioSettingsWidget::initApiList()’:
/home/<redacted>/Desktop/clap-host/host/audio-settings-widget.cc:73:60: error: ‘getApiDisplayName’ is not a member of ‘RtAudio’
   73 |       _apiChooser->addItem(QString::fromStdString(RtAudio::getApiDisplayName(api)));
      |                                                            ^~~~~~~~~~~~~~~~~
/home/<redacted>/Desktop/clap-host/host/audio-settings-widget.cc:74:35: error: ‘getApiName’ is not a member of ‘RtAudio’
   74 |       if (selectedApi == RtAudio::getApiName(api))
      |                                   ^~~~~~~~~~
/home/<redacted>/Desktop/clap-host/host/audio-settings-widget.cc: In member function ‘void AudioSettingsWidget::saveSettings()’:
/home/<redacted>/Desktop/clap-host/host/audio-settings-widget.cc:204:28: error: ‘getApiName’ is not a member of ‘RtAudio’
  204 |    auto apiName = RtAudio::getApiName(getSelectedAudioApi());
      |                            ^~~~~~~~~~
[2/3] Building CXX object host/CMakeFiles/clap-host.dir/Debug/engine.cc.o
FAILED: host/CMakeFiles/clap-host.dir/Debug/engine.cc.o 
/usr/lib64/ccache/c++ -DQT_CORE_LIB -DQT_GUI_LIB -DQT_WIDGETS_LIB -DCMAKE_INTDIR=\"Debug\" -I/home/<redacted>/Desktop/clap-host/builds/ninja-system/host -I/home/<redacted>/Desktop/clap-host/host -I/home/<redacted>/Desktop/clap-host/builds/ninja-system/host/clap-host_autogen/include_Debug -I/home/<redacted>/Desktop/clap-host/clap-helpers/include -I/home/<redacted>/Desktop/clap-host/clap/include -isystem /usr/include/qt6/QtWidgets -isystem /usr/include/qt6 -isystem /usr/include/qt6/QtCore -isystem /usr/lib64/qt6/mkspecs/linux-g++ -isystem /usr/include/qt6/QtGui -isystem /usr/include/rtmidi -isystem /usr/include/rtaudio -g -fvisibility=hidden -fvisibility-inlines-hidden -Werror=return-type -Werror=unused-result -Wno-unused-parameter -Wuninitialized -Wvla -Wmultichar -Werror=non-virtual-dtor -Woverloaded-virtual -pthread -D__UNIX_JACK__ -D__LINUX_ALSA__ -D_REENTRANT -D__LINUX_PULSE__ -Winvalid-pch -include /home/<redacted>/Desktop/clap-host/builds/ninja-system/host/CMakeFiles/clap-host.dir/Debug/cmake_pch.hxx -MD -MT host/CMakeFiles/clap-host.dir/Debug/engine.cc.o -MF host/CMakeFiles/clap-host.dir/Debug/engine.cc.o.d -o host/CMakeFiles/clap-host.dir/Debug/engine.cc.o -c /home/<redacted>/Desktop/clap-host/host/engine.cc
/home/<redacted>/Desktop/clap-host/host/engine.cc: In member function ‘void Engine::start()’:
/home/<redacted>/Desktop/clap-host/host/engine.cc:95:45: error: ‘getCompiledApiByName’ is not a member of ‘RtAudio’
   95 |          std::make_unique<RtAudio>(RtAudio::getCompiledApiByName(deviceRef._api.toStdString()));
      |                                             ^~~~~~~~~~~~~~~~~~~~
ninja: build stopped: subcommand failed.
ghost commented 2 years ago

It is probably failing because of the rtaudio version for Arch/MinGW at 5.2.0 vs the one currently in Fedora 36 at 5.0.0. Unable to build it usingvcpkgtoo.

abique commented 2 years ago

What's the error with vcpkg?

abique commented 2 years ago

Could fedora upgrate rtaudio and rtmidi?

ghost commented 2 years ago

Could fedora upgrate rtaudio and rtmidi?

Unfortunately, it seems to be a no. It'll require someone to contact the maintainer and they're inactive, it seems. I'll try asking folks from Fedora's Discord Server

I could do with building rtaudio from scratch, but I am not good with cmake flags. I've tried using $LD_LIBRARY_PATH, and that doesn't seem to be doing anything, because it specifically requires rtaudio from the /usr/lib/ directory, again, where I don't want to place the newly built files manually, as it might probably create a mess.

Edit: Someone put a request for 5.2.0 here.

abique commented 1 year ago

Sorry to come back after so long. Did you try to build it using scripts/build.sh?