On Fri, Aug 26, 2016 at 3:11 PM, Oliver Kurz
On Friday 26 August 2016 18:50:57 Tom Kacvinsky wrote:
On Aug 26, 2016, at 14:42:00, Tom Kacvinsky
wrote: […] src/frameworks/UBGeometryUtils.cpp: In static member function 'static QPolygonF UBGeometryUtils::arcToPolygon(const QLineF&, qreal, qreal)': [ 179s] src/frameworks/UBGeometryUtils.cpp:191:42: error: call of overloaded 'abs(qreal&)' is ambiguous [ 179s] bool overlap = abs(spanAngleInDegrees) > 360 - angle; [ 179s] ^ [ 179s] In file included from /usr/include/c++/6/cstdlib:75:0, […] A c++ programmer can probably fix (patch) that up pretty quickly, but it would be better to report it to upstream and get them to do a real fix that will be part of the next release. They could probably provide you the needed patch as well will little problem.
Yes, should be reported upstream, but I just checked the Qt docs and qreal is typedfed to double. abs(), according to
http://www.cplusplus.com/reference/cmath/abs/
comes in three flavors. So I don't see why abs(double) is not chosen as the prototype for abs(qreal). But, looking at the error message, it is taking the "usual" C prototype for abs (which is abs(int)). A fix for this until you hear from the upstream maintainers is to use std::abs() instead of abs(). Another option is to include cmath:
#include <cmath>
to get the C++ prototypes
Do you know how I would apply that as a patch as part of the packaging process in the proper way?
Does this help:
https://en.opensuse.org/openSUSE:Build_Service_Tutorial#A_start_to_end_examp...
Note the example of modifying sleuthkit:
===
cd ~/obs
umask 0022
osc branch security sleuthkit
osc co home: