Modify

Opened 8 years ago

Closed 8 years ago

Last modified 5 years ago

#88 closed task (fixed)

BNC for Raspberry Pi

Reported by: wiese Owned by: wiese
Priority: normal Component: BNC
Version: Keywords: raspi
Cc: wiese

Description

BNC compilation crashes on Rasperry Pi. (Model B Rev. 2)

qwt_polar_curve.cpp: In member function ‘void 
QwtPolarCurve::drawLines(QPainter*, const QwtScaleMap&, const 
QwtScaleMap&, const QPointF&, int, int) const’:
qwt_polar_curve.cpp:436:64: error: no matching function for call to 
‘qMax(double, qreal)’
qwt_polar_curve.cpp:436:64: note: candidate is:
/usr/include/qt4/QtCore/qglobal.h:1198:34: note: template<class T> const 
T& qMax(const T&, const T&)
Makefile:326: recipe for target '.obj/qwt_polar_curve.o' failed
make[1]: *** [.obj/qwt_polar_curve.o] Error 1
make[1]: Leaving directory '/home/wiese/BNC_2.12.2/qwtpolar'
Makefile:114: recipe for target 'sub-qwtpolar-make_default-ordered' failed
make: *** [sub-qwtpolar-make_default-ordered] Error 2

There are 2 errors more like that. Errors are all within QwtPolar.

Attachments (0)

Change History (2)

comment:1 by wiese, 8 years ago

The errors related to expected QReal variables where the compiler only finds doubles. Need to make the following changes (Thanks to Eric Younkin from NOAA!):

In BNC_2.12.2/qwtpolar/qwt_polar_curve.cpp, Line 436 Change

double off = qCeil( qMax(1.0, painter->pen().widthF() ) );
To
double off = qCeil( qMax(qreal(1.0), painter->pen().widthF() ) );

In BNC_2.12.2/qwtpolar/qwt_polar_layout.cpp, Line 281 Change

dim = qMin( hint.width(), rect.width() * d_data->legendRatio );
To
dim = qMin( hint.width(), qreal(rect.width() * d_data->legendRatio) );

In BNC_2.12.2/qwtpolar/qwt_polar_layout.cpp, Line 296 Change

dim = qMin( hint.width(), rect.width() * d_data->legendRatio );
To
dim = qMin( hint.width(), qreal(rect.width() * d_data->legendRatio) );

Thex next problem was that there wasn't enough memory for comiling. Installing zram (see raspberry-pi-performance-tuning and increasing swap from 100 to 500MB helped to successfully compile BNC. It takes about 2 hours on my raspi B Rev. 2.0.

Libs that I installed with apt-get: build-essential, libssl-dev, qt4-qmake, xterm

Executables are available at https://igs.bkg.bund.de/ntrip/download.

Last edited 8 years ago by wiese (previous) (diff)

comment:2 by stuerze, 8 years ago

Resolution: fixed
Status: newclosed

The mentioned changes are now part of BNC's SVNs and will be part of each future BNC version.

Modify Ticket

Change Properties
Action
as closed The owner will remain wiese.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.