The examples were too numerous to study, so I tried to separate one of them from the project. This was more difficult than I thought. The main trick was creating an environmental variable, QWT_ROOT=/usr/include/qwt-qt4 , to be located in my .profile (or .bashrc). I also had to provide a link to qmake. Using the examples as a, well, as an example, I created two files which contained all the library paths, qwtconfig.pri and myproject.pri.
The sequence at the console is:
- qmake -project , Creates myproject.pro
- Edit myproject.pro and add the lines
- include( myproject.pri )
- include( qwtconfig.pri )
- qmake , Creates Makefile
- make , Creates executable, myproject
- ./myproject , Runs executable
No comments:
Post a Comment