Re: osmeditor make problem

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: osmeditor make problem

Immanuel Scholz
Hi,

moved to dev


> <rant>
> It's *so* annoying how these errors crop up in some distributions and not
> others. Makes identification of this type of error virtually
> impossible....:-(
> </rant>

Well.. looking at the code, the compiler is fully right:
While compiling osmeditor2.cpp, <cmath> is not included before using it.


That it works for some people, this is because the C++ Standard does not
specify the header dependencies of the standard headers (unlike in C).

So if some implementation of the standard library headers by accident include
cmath in any standard header before (e.g. <vector>), then it works for this
implementation.

But this will not be legal Standard C++ until the missing cmath include is
added.


Ciao, Imi.

By the way: Many coders consider think it is very dirty to use "using"
directives in header files.

_______________________________________________
Openstreetmap-dev mailing list
[hidden email]
http://bat.vr.ucl.ac.uk/cgi-bin/mailman/listinfo/openstreetmap-dev
Reply | Threaded
Open this post in threaded view
|

Re: osmeditor make problem

Immanuel Scholz
Hi,

moved to dev


> /usr/bin/ld: cannot find -lqt
> collect2: ld returned 1 exit status
> make: *** [osmeditor2] Error 1
> rm moc_HTTPHandler.cpp moc_MainWindow2.cpp
...
> > >Hey Nick. I've got the libqt3-mt-dev, libqt4-dev, & libcurl3-dev
> > >libraries from the ubuntu repositories. However, using "make

You have libqt-mt and try to link against libqt.

Either install libqt3-dev (which is not part of ubuntu) or change the Makefile
to use the multi-threaded qt library. To do this, change line 34 to
"QTLIB = -lqt-mt".


Ciao, Imi.

_______________________________________________
Openstreetmap-dev mailing list
[hidden email]
http://bat.vr.ucl.ac.uk/cgi-bin/mailman/listinfo/openstreetmap-dev
Reply | Threaded
Open this post in threaded view
|

Re: Re: osmeditor make problem

Nick Whitelegg
In reply to this post by Immanuel Scholz

> Well.. looking at the code, the compiler is fully right:
> While compiling osmeditor2.cpp, <cmath> is not included before using it.

Yes but what I mean is the error will go undetected unless you test it on
several different distributions......

Nick


_______________________________________________
Openstreetmap-dev mailing list
[hidden email]
http://bat.vr.ucl.ac.uk/cgi-bin/mailman/listinfo/openstreetmap-dev