Fundamental icon indicating copy to clipboard operation
Fundamental copied to clipboard

2.5.1 build failure on Fedora 39 with gcc 13.2.1

Open ycollet opened this issue 2 years ago • 3 comments

When I tried to build Fundamental on F39 with gcc 13.2.1, I met the following error message:

src/Logic.cpp:137:31: error: reference to ‘LightButton’ is ambiguous
  137 | using VCVBezelLightBigWhite = LightButton<VCVBezelBig, VCVBezelLightBig<WhiteLight>>;
      |                               ^~~~~~~~~~~
In file included from ../include/rack.hpp:36,
                 from src/plugin.hpp:1,
                 from src/Logic.cpp:1:
../include/componentlibrary.hpp:890:8: note: candidates are: ‘template<class TBase, class TLight> struct rack::componentlibrary::LightButton’
  890 | struct LightButton : TBase {
      |        ^~~~~~~~~~~
src/Logic.cpp:121:8: note:                 ‘template<class TBase, class TLight> struct LightButton’
  121 | struct LightButton : TBase {
      |        ^~~~~~~~~~~
src/Logic.cpp: In constructor ‘LogicWidget::LogicWidget(Logic*)’:
src/Logic.cpp:150:51: error: ‘VCVBezelLightBigWhite’ was not declared in this scope; did you mean ‘VCVBezelLightBig’?
  150 |                 addParam(createLightParamCentered<VCVBezelLightBigWhite>(mm2px(Vec(12.7, 26.755)), module, Logic::B_PARAM, Logic::B_BUTTON_LIGHT));
      |                                                   ^~~~~~~~~~~~~~~~~~~~~
      |                                                   VCVBezelLightBig
src/Logic.cpp:150:73: error: no matching function for call to ‘createLightParamCentered<<expression error> >(rack::math::Vec, Logic*&, Logic::ParamId, Logic::LightId)’
  150 |                 addParam(createLightParamCentered<VCVBezelLightBigWhite>(mm2px(Vec(12.7, 26.755)), module, Logic::B_PARAM, Logic::B_BUTTON_LIGHT));
      |                          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from ../include/rack.hpp:35:
../include/helpers.hpp:174:15: note: candidate: ‘template<class TParamWidget> TParamWidget* rack::createLightParamCentered(math::Vec, engine::Module*, int, int)’
  174 | TParamWidget* createLightParamCentered(math::Vec pos, engine::Module* module, int paramId, int firstLightId) {
      |               ^~~~~~~~~~~~~~~~~~~~~~~~
../include/helpers.hpp:174:15: note:   template argument deduction/substitution failed:
src/Logic.cpp:150:73: error: template argument 1 is invalid
  150 |                 addParam(createLightParamCentered<VCVBezelLightBigWhite>(mm2px(Vec(12.7, 26.755)), module, Logic::B_PARAM, Logic::B_BUTTON_LIGHT));
      |                          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
make: *** [../compile.mk:87: build/src/Logic.cpp.o] Error 1
make: *** Waiting for unfinished jobs....

ycollet avatar Oct 02 '23 06:10 ycollet

I fix: Replace:

using VCVBezelLightBigWhite = LightButton<VCVBezelBig, VCVBezelLightBig<WhiteLight>>;

By:

using VCVBezelLightBigWhite = struct rack::componentlibrary:LightButton<VCVBezelBig, VCVBezelLightBig<WhiteLight>>;

ycollet avatar Oct 10 '23 11:10 ycollet

The same problem occured with 2.6.0

ycollet avatar Oct 10 '23 11:10 ycollet

Can't reproduce on Arch Linux with gcc 13.2.1, building Fundamental v2.6.0 against Rack v2.5.1.

cbix avatar Apr 18 '24 22:04 cbix