Re: Problem with liborocos-gnulinux.a linking
Peter Soetens <[email protected]> Thu, 16 Jun 2005 13:07:35 +0200
| Newsgroups | gmane.science.robotics.orocos.user |
|---|---|
| Organization | KU Leuven |
| Message-ID | <[email protected]> |
On Thursday 16 June 2005 12:51, Artem Orlov wrote:
> Hello everyone!
>
> I tried the example from orocos-manual.pdf but when linking it
> produced errors which I couldn't fix by myself. In attachment one can
> see example, makefile and compiler output.
This is a wild guess, but isn't the -lorocos-gnulinux and other -l'flags'
supposed to be at the end of the CC command ?
From the gcc man page :
-l library
Search the library named library when linking. (The second
alternative with the library as a separate argument is only for POSIX
compliance and is not recommended.)
It makes a difference where in the command you write this option;
the linker searches and processes libraries and object files in
the order they are specified. Thus, foo.o -lz bar.o searches
library z after file foo.o but before bar.o. If bar.o refers to
functions in z, those functions may not be loaded.
The linker searches a standard list of directories for the library,
which is actually a file named liblibrary.a. The linker then
uses this file as if it had been specified precisely by name.
The directories searched include several standard system
directories plus any that you specify with -L.
Normally the files found this way are library files---archive files
whose members are object files. The linker handles an archive
file by scanning through it for members which define symbols that
have so far been referenced but not defined. But if the file
that is found is an ordinary object file, it is linked in the usual
fashion. The only difference between using an -l option and
specifying a file name is that -l surrounds library with lib and .a
and searches several directories.
Peter
>
> Really I am not keen with OROCOS configuration and make a mistake
> somewhere.
>
> I have all the logs that OROCOS produced while installation and
> compilation steps.
> They are located in http://artemorlov.narod.ru
> Sometimes it is slow. Please be patient.
>
> Thank you.
--
K.U.Leuven, Mechanical Engineering, Robotics Research Group
<http://www.orocos.org> Tel: +32 16 322772