---------------------------------------------------------------------- Download and Build Instructions for Qwt 5.2.2 using Visual Studio 2008 Phil Weinstein, CADSWES, 8-24-2012 ---------------------------------------------------------------------- Including this work, RiverWare has been build with the following versions of Qwt: (1) Qwt 5.0.2, with Qt 4.4 (2) Qwt 5.2.1, with Qt 4.6 (used through RiverWare 6.2) (3) Qwt 5.2.2, with Qt 4.8.2 (for RiverWare 6.3) NOTE-1: Rather than using 'nmake', I'm generating Visual Studio .vcproj files from .pro files, and building the libraries in Visual Studio 2008. NOTE-2: I'm not taking time to actually build the examples. I'm building only the static libraries: C:\Riverware\tools\Qwt-522_Qt-482\lib\qwt.lib C:\Riverware\tools\Qwt-522_Qt-482\lib\qwtd.lib PROCESS: (1) Download 5.2.2 zip file: http://sourceforge.net/projects/qwt/files/qwt/5.2.2/ qwt-5.2.2.zip (2011-08-01; 2.9 MB) (2) Edited qwtconfig.pri (a 'pro' include file) -- significant values: INSTALLBASE = C:/RiverWare/tools/Qwt-522_Qt-482 CONFIG += debug_and_release CONFIG += build_all # CONFIG += QwtDll CONFIG += QwtPlot CONFIG += QwtWidgets # CONFIG += QwtSVGItem # CONFIG += QwtMathML (3) [Refer to INSTALL file instructions, Section (B) Win32/MSVC Qt3/Qt4] ... Not using nmake. Rather, preparing vcproj files to use with Visual Studio 2008 ... (4) Apply SOURCE CODE FIX to qwt_plot_curve.cpp: The original version is copied off to: qwt_plot_curve-ORIG.cpp Method: void QwtPlotCurve::drawLines(QPainter *painter, const QwtScaleMap &xMap, const QwtScaleMap &yMap, int from, int to) const ... around line 740 ================================================================ for (int i = from; i <= to; i++) { // CADSWES FIX -- originally developed with Qwt 5.0.2: // Change [i] to [i - from]. Without this, our solution to // drawing disjoint curves (having internal NaNs) crashes. // //-- WRONG: QwtDoublePoint &p = points[i]; QwtDoublePoint &p = points[i - from]; p.setX( xMap.xTransform(x(i)) ); p.setY( yMap.xTransform(y(i)) ); } ================================================================ (5) Confirm ... which qmake.exe C:\Riverware\tools\Qt-482\bin\qmake.exe (note: 'which' depends on C:\RiverWare\tools\UnxUtils; being on the path). (6) To generate project (vcproj) files: admin\msvc-qmake vc ... among other things, this results in the creation of file: ... src\qwtd.vcproj. Note: the 'd' signifies 'debug' (rather than ... 'release'). But we really don't need a seperate vcproj file for ... 'release'. That can just be toggled within Visual Studio. (7) In Visual Studio 2008, open the project file: C:\Riverware\tools\Qwt-522_Qt-482\src\qwtd.vcproj Build >> Clean Solution Build >> Build Solution ... acknowledge the saving of the file. Change from Release to Debug Build >> Build Solution (8) For the 64-bit build, notice that these two libraries have been built: C:\RiverWare\tools\Qwt-522_Qt-482\src\x64\Release\qwt.lib (2855 KB) C:\RiverWare\tools\Qwt-522_Qt-482\src\x64\Debug\qwtd.lib (7279 KB) copy these to where the 32-bit libraries get built: C:\RiverWare\tools\Qwt-522_Qt-482\lib\qwtd.lib C:\RiverWare\tools\Qwt-522_Qt-482\lib\qwt.lib --- (end) ---