davy7125 / polyphone

A soundfont editor for quickly designing musical instruments.
https://www.polyphone.io
GNU General Public License v3.0
363 stars 49 forks source link

Compilation failed #75

Closed trebmuh closed 5 years ago

trebmuh commented 5 years ago

Trying to build from 2.1.1 On LibraZiK-2 (Debian Stretch based), it fails with the following:

In file included from editor/envelopeditor.h:30:0,
                 from editor/pagetable.cpp:30:
editor/graphics/graphicsviewenvelop.h:95:20: error: 'QCPAxisTickerFixed' was not declared in this scope
     QSharedPointer<QCPAxisTickerFixed> _fixedTicker;
                    ^~~~~~~~~~~~~~~~~~
editor/graphics/graphicsviewenvelop.h:95:38: error: template argument 1 is invalid
     QSharedPointer<QCPAxisTickerFixed> _fixedTicker;
                                      ^
Makefile:5612: recipe for target 'generated_files/pagetable.o' failed
make[1]: *** [generated_files/pagetable.o] Error 1
make[1]: *** Waiting for unfinished jobs....
In file included from editor/envelopeditor.h:30:0,
                 from editor/envelopeditor.cpp:25:
editor/graphics/graphicsviewenvelop.h:95:20: error: 'QCPAxisTickerFixed' was not declared in this scope
     QSharedPointer<QCPAxisTickerFixed> _fixedTicker;
                    ^~~~~~~~~~~~~~~~~~
editor/graphics/graphicsviewenvelop.h:95:38: error: template argument 1 is invalid
     QSharedPointer<QCPAxisTickerFixed> _fixedTicker;
                                      ^
In file included from editor/graphics/graphiquefourier.cpp:25:0:
editor/graphics/graphiquefourier.h:64:20: error: 'QCPAxisTickerFixed' was not declared in this scope
     QSharedPointer<QCPAxisTickerFixed> _fixedTickerX;
                    ^~~~~~~~~~~~~~~~~~
editor/graphics/graphiquefourier.h:64:38: error: template argument 1 is invalid
     QSharedPointer<QCPAxisTickerFixed> _fixedTickerX;
                                      ^
editor/graphics/graphiquefourier.h:65:20: error: 'QCPAxisTickerFixed' was not declared in this scope
     QSharedPointer<QCPAxisTickerFixed> _fixedTickerY;
                    ^~~~~~~~~~~~~~~~~~
editor/graphics/graphiquefourier.h:65:38: error: template argument 1 is invalid
     QSharedPointer<QCPAxisTickerFixed> _fixedTickerY;
                                      ^
editor/graphics/graphiquefourier.cpp: In constructor 'GraphiqueFourier::GraphiqueFourier(QWidget*)':
editor/graphics/graphiquefourier.cpp:33:23: error: expected type-specifier before 'QCPAxisTickerFixed'
     _fixedTickerX(new QCPAxisTickerFixed()),
                       ^~~~~~~~~~~~~~~~~~
editor/graphics/graphiquefourier.cpp:34:23: error: expected type-specifier before 'QCPAxisTickerFixed'
     _fixedTickerY(new QCPAxisTickerFixed()),
                       ^~~~~~~~~~~~~~~~~~
editor/graphics/graphiquefourier.cpp:62:18: error: base operand of '->' is not a pointer
     _fixedTickerX->setScaleStrategy(QCPAxisTickerFixed::ssNone);
                  ^~
editor/graphics/graphiquefourier.cpp:62:37: error: 'QCPAxisTickerFixed' has not been declared
     _fixedTickerX->setScaleStrategy(QCPAxisTickerFixed::ssNone);
                                     ^~~~~~~~~~~~~~~~~~
editor/graphics/graphiquefourier.cpp:63:18: error: base operand of '->' is not a pointer
     _fixedTickerX->setTickStep(2000);
                  ^~
editor/graphics/graphiquefourier.cpp:64:18: error: 'class QCPAxis' has no member named 'setTicker'; did you mean 'setTicks'?
     this->xAxis->setTicker(_fixedTickerX);
                  ^~~~~~~~~
editor/graphics/graphiquefourier.cpp:76:18: error: base operand of '->' is not a pointer
     _fixedTickerY->setScaleStrategy(QCPAxisTickerFixed::ssNone);
                  ^~
editor/graphics/graphiquefourier.cpp:76:37: error: 'QCPAxisTickerFixed' has not been declared
     _fixedTickerY->setScaleStrategy(QCPAxisTickerFixed::ssNone);
                                     ^~~~~~~~~~~~~~~~~~
editor/graphics/graphiquefourier.cpp:77:18: error: base operand of '->' is not a pointer
     _fixedTickerY->setTickStep(0.2);
                  ^~
editor/graphics/graphiquefourier.cpp:78:18: error: 'class QCPAxis' has no member named 'setTicker'; did you mean 'setTicks'?
     this->yAxis->setTicker(_fixedTickerY);
                  ^~~~~~~~~
editor/graphics/graphiquefourier.cpp: In destructor 'virtual GraphiqueFourier::~GraphiqueFourier()':
editor/graphics/graphiquefourier.cpp:134:19: error: request for member 'clear' in '((GraphiqueFourier*)this)->GraphiqueFourier::_fixedTickerX', which is of non-class type 'int'
     _fixedTickerX.clear();
                   ^~~~~
editor/graphics/graphiquefourier.cpp:135:19: error: request for member 'clear' in '((GraphiqueFourier*)this)->GraphiqueFourier::_fixedTickerY', which is of non-class type 'int'
     _fixedTickerY.clear();
                   ^~~~~
editor/graphics/graphiquefourier.cpp: In member function 'void GraphiqueFourier::dispFourier(QVector<float>, float)':
editor/graphics/graphiquefourier.cpp:391:39: error: no matching function for call to 'QCPGraph::setData(QVector<double>&, QVector<double>&, bool)'
     this->graph(0)->setData(x, y, true);
                                       ^
In file included from editor/graphics/graphiquefourier.h:28:0,
                 from editor/graphics/graphiquefourier.cpp:25:
/usr/include/qcustomplot.h:2543:8: note: candidate: void QCPGraph::setData(QCPDataMap*, bool)
   void setData(QCPDataMap *data, bool copy=false);
        ^~~~~~~
/usr/include/qcustomplot.h:2543:8: note:   candidate expects 2 arguments, 3 provided
/usr/include/qcustomplot.h:2544:8: note: candidate: void QCPGraph::setData(const QVector<double>&, const QVector<double>&)
   void setData(const QVector<double> &key, const QVector<double> &value);
        ^~~~~~~
/usr/include/qcustomplot.h:2544:8: note:   candidate expects 2 arguments, 3 provided
editor/graphics/graphiquefourier.cpp: In member function 'void GraphiqueFourier::exportPng(QString)':
editor/graphics/graphiquefourier.cpp:437:5: error: 'QCPTextElement' was not declared in this scope
     QCPTextElement * title = new QCPTextElement(this, _name);
     ^~~~~~~~~~~~~~
editor/graphics/graphiquefourier.cpp:437:22: error: 'title' was not declared in this scope
     QCPTextElement * title = new QCPTextElement(this, _name);
                      ^~~~~
editor/graphics/graphiquefourier.cpp:437:34: error: expected type-specifier before 'QCPTextElement'
     QCPTextElement * title = new QCPTextElement(this, _name);
                                  ^~~~~~~~~~~~~~
trebmuh commented 5 years ago

Au doigt mouillé, it might be that libqcustomplot-dev is in its 1.3.2 version on Stretch while a newer version would be needed. Please confirmed.

davy7125 commented 5 years ago

In that case you can uncomment "use local qcustomplot" at the beginning of the .pro file. The compilation will then use the embedded library and will not require the right version of qcustomplot to be installed on the OS.

trebmuh commented 5 years ago

All good with that.

Merci @davy7125 !