[Bug 432] New: undefined reference to `ORO_main'

For more information about this bug, visit
A new bug was added:
Summary: undefined reference to `ORO_main'
Product: RTT
Version: rtt-trunk
Platform: All
OS/Version: GNU/Linux
Status: NEW
Severity: normal
Priority: P2
Component: Corba
AssignedTo: orocos-dev [..] ...
ReportedBy: ruben [dot] smits [..] ...

When i try to compile my application against the Corba-enabled version i get
the following linking error:

/home/rsmits/orocos/install-ocl-kdl-exp-corba/lib/liborocos-rtt.so: undefined
reference to `ORO_main'

nm gives me:

nm /home/rsmits/orocos/install-ocl-kdl-exp-corba/lib/liborocos-rtt.so | grep
ORO_main
U ORO_main

make check did not give me any problems. Am i forgetting something?

Ruben

--
(this mail is best viewed with a fixed font)
Configure bugmail: https://www.fmtc.be/orocos-bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
--
Orocos-Dev mailing list
Orocos-Dev [..] ...
http://lists.mech.kuleuven.be/mailman/listinfo/orocos-dev

Disclaimer: http://www.kuleuven.be/cwis/email_disclaimer.htm

Ruben Smits's picture

[Bug 432] undefined reference to `ORO_main'

For more information about this bug, visit

ruben [dot] smits [..] ... changed:

What |Removed |Added
---------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |INVALID

------- Comment #1 from ruben [dot] smits [..] ... 2007-07-24 08:06

I forgot to include

#include

for some strange reason it was no problem when compiling against the
corba-disabled version of orocos-rtt

Ruben

--
(this mail is best viewed with a fixed font)
Configure bugmail: https://www.fmtc.be/orocos-bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
--
Orocos-Dev mailing list
Orocos-Dev [..] ...
http://lists.mech.kuleuven.be/mailman/listinfo/orocos-dev

Disclaimer: http://www.kuleuven.be/cwis/email_disclaimer.htm

[Bug 432] New: undefined reference to `ORO_main'

> When i try to compile my application against the Corba-enabled version i get
> the following linking error:
>
> /home/rsmits/orocos/install-ocl-kdl-exp-corba/lib/liborocos-rtt.so: undefined
> reference to `ORO_main'
>
> nm gives me:
>
> nm /home/rsmits/orocos/install-ocl-kdl-exp-corba/lib/liborocos-rtt.so | grep
> ORO_main
> U ORO_main
>
> make check did not give me any problems. Am i forgetting something?

Probably. You should define ORO_main yourself, it will never be in RTT.
Or maybe you forgot to pass the correct arguments?

ps. @peter There appears to be an answer without a question in the faq.


Q:

The first message I get is 'LXRT NOT INITIALISED IN THIS THREAD
pid=1234, BUT TRIES TO INVOKE LXRT FUNCTION >>rtos_mutex_init<<
ANYWAY'. What did I do wrong ?
A:

You tried to use RTAI's functions while RTAI was not yet initialised.
This happens if you use global objects which contain Mutexes. Examples
are Event and some DataObjects, Buffers and the Logger class. The
solution is not to use global objects, but use global pointers and
create the objects in ORO_main() with new.
A:

You did not put your program in the ORO_main() function. ( see The
Installation Manual and The Orocos OS Manual. )

Klaas
--
Orocos-Dev mailing list
Orocos-Dev [..] ...
http://lists.mech.kuleuven.be/mailman/listinfo/orocos-dev

Disclaimer: http://www.kuleuven.be/cwis/email_disclaimer.htm

[Bug 432] New: undefined reference to `ORO_main'

Quoting Klaas Gadeyne <klaas [dot] gadeyne [..] ...>:
> ps. @peter There appears to be an answer without a question in the faq.
>
>
> Q:
>
> The first message I get is 'LXRT NOT INITIALISED IN THIS THREAD
> pid=1234, BUT TRIES TO INVOKE LXRT FUNCTION >>rtos_mutex_init<<
> ANYWAY'. What did I do wrong ?
> A:
>
> You tried to use RTAI's functions while RTAI was not yet initialised.
> This happens if you use global objects which contain Mutexes. Examples
> are Event and some DataObjects, Buffers and the Logger class. The
> solution is not to use global objects, but use global pointers and
> create the objects in ORO_main() with new.
> A:
>
> You did not put your program in the ORO_main() function. ( see The
> Installation Manual and The Orocos OS Manual. )

Some questions have 2 answers.

Peter
--
Orocos-Dev mailing list
Orocos-Dev [..] ...
http://lists.mech.kuleuven.be/mailman/listinfo/orocos-dev

Disclaimer: http://www.kuleuven.be/cwis/email_disclaimer.htm