You are here

Can't build 0.7.9 on Ubuntu 16.04 64-bit

Hello, I haven't had any success building qtractor. When trying to build for either Qt4 or Qt5 I get the following errors:

In file included from qtractorAudioEngine.cpp:35:0:
qtractorMidiManager.h:298:11: error: field ‘progs’ has incomplete type ‘qtractorMidiManager::Progs {aka QMap}’
   Progs   progs;
           ^
In file included from /usr/include/qt4/QtCore/qpair.h:45:0,
                 from /usr/include/qt4/QtCore/qhash.h:49,
                 from /usr/include/qt4/QtCore/QHash:1,
                 from qtractorMidiControl.h:29,
                 from qtractorTrack.h:27,
                 from qtractorEngine.h:25,
                 from qtractorAudioEngine.h:26,
                 from qtractorAudioEngine.cpp:23:
/usr/include/qt4/QtCore/qdatastream.h:67:37: note: declaration of ‘qtractorMidiManager::Progs {aka class QMap}’
 template  class QMap;
                                     ^
In file included from qtractorAudioEngine.cpp:35:0:
qtractorMidiManager.h:396:14: error: field ‘m_instruments’ has incomplete type ‘qtractorMidiManager::Instruments {aka QMap >}’
  Instruments m_instruments;
              ^
In file included from /usr/include/qt4/QtCore/qpair.h:45:0,
                 from /usr/include/qt4/QtCore/qhash.h:49,
                 from /usr/include/qt4/QtCore/QHash:1,
                 from qtractorMidiControl.h:29,
                 from qtractorTrack.h:27,
                 from qtractorEngine.h:25,
                 from qtractorAudioEngine.h:26,
                 from qtractorAudioEngine.cpp:23:
/usr/include/qt4/QtCore/qdatastream.h:67:37: note: declaration of ‘qtractorMidiManager::Instruments {aka class QMap >}’
 template  class QMap;
                                     ^

In an attempt to get things to just compile I use the following:

./configure --enable-vst=no --enable-libsamplerate=no --enable-librubberband=no --enable-libvorbis=no --enable-libmad=no --enable-liblo=no --enable-dssi=no --enable-lv2=no --enable-lilv=no --enable-nsm=no

I used sudo apt-get build-dep qtractor to make sure I have the dependencies.

Does this look familiar or obvious to anyone?

Thanks for your wisdom.

Forums: 
rncbc's picture

i suspect you're still trying to build on an system which fails or is incomplete on dependencies on either Qt4 or/and Qt5 build dependencies.

i have no big field experience on ubuntu, but you can try following the following basic (theoretical) steps :

  1. install all the necessary build dependencies (mandatory are in bold):
    sudo apt-get update
    sudo apt-get install qtbase5-dev qtbase5-dev-tools qttools5-dev-tools qtchooser
    sudo apt-get install libx11-dev x11proto-core-dev, libqt5x11extras5-dev
    sudo apt-get install libjack-dev libasound2-dev libsndfile-dev ladspa-sdk libvorbis-dev libsamplerate-dev
    sudo apt-get install libmad0-dev librubberband-dev dssi-dev liblo0-dev zlib1g-dev
    sudo apt-get install lv2-dev liblilv-dev libsuil-dev
  2. on the source tree, start on a clean slate:
    ./autogen.sh clean
    ./autogen.sh
  3. main build, from source:
    export QT_SELECT=5
    ./configure
    make
  4. finally, if so desired, install from source:
    sudo make install

hth.
cheers

Excellent, thank you very much. The trick seemed to be removing "--enable-vst=no" from my configure line. I didn't actually install anything just now because everything was already there except the Qt5 packages, and I already had the full Qt5 tools installed and didn't want to have two variants of Qt5 stuff.

I stumbled a bit getting configure to work and crossed a point where that switch was now not helping me. Here are the "tweaks" that I think were necessary for me:

  1. I installed the full Qt5 package from their web site, and after much head scratching to get qmake detected by ./configure I ended up doing
        ln -s /<my-qt5-install-dir>/5.7/gcc_64/bin/qmake /usr/bin/qmake-qt5

    I feel like there is a more proper way to do this, but none of the info I found, particularly about qtchooser, seemed to solve locating my Qt5 binaries.

  2. Specify
        CXXFLAGS='-std=c++11'

    in the ./configure options.

  3. DO NOT specify
        --enable-vst=no

    in the ./configure options.

It's building and running now.

Thanks again!

Add new comment