On 02/05/2015 04:29 PM, Huy Cong Vu wrote: > > > ----- Mail original ----- >> De: "Philippe Gerum" <[email protected]> >> À: "Huy Cong Vu" <[email protected]> >> Cc: [email protected] >> Envoyé: Jeudi 5 Février 2015 15:42:15 >> Objet: Re: [Xenomai] Xenomai 3 - no skin detected in program > >> On 02/05/2015 03:05 PM, Huy Cong Vu wrote: >>> >>> >>> ----- Mail original ----- >>>> De: "Philippe Gerum" <[email protected]> >>>> À: "Huy Cong Vu" <[email protected]> >>>> Cc: [email protected] >>>> Envoyé: Mercredi 4 Février 2015 14:21:18 >>>> Objet: Re: [Xenomai] Xenomai 3 - no skin detected in program >>> >>>> On 02/04/2015 12:40 PM, Huy Cong Vu wrote: >>>>> >>>>> >>>>> ----- Mail original ----- >>>>>> De: "Huy Cong Vu" <[email protected]> >>>>>> À: "Philippe Gerum" <[email protected]> >>>>>> Cc: [email protected] >>>>>> Envoyé: Mercredi 4 Février 2015 12:07:54 >>>>>> Objet: Re: [Xenomai] Xenomai 3 - no skin detected in program >>>>> >>>>>> ----- Mail original ----- >>>>>>> De: "Philippe Gerum" <[email protected]> >>>>>>> À: "Huy Cong Vu" <[email protected]>, [email protected] >>>>>>> Envoyé: Mercredi 4 Février 2015 10:13:14 >>>>>>> Objet: Re: [Xenomai] Xenomai 3 - no skin detected in program >>>>>> >>>>>>> On 02/04/2015 09:55 AM, Huy Cong Vu wrote: >>>>>>>> Hello everyone, >>>>>>>> I recently try to run an application compiled in native skin of >>>>>>>> Xenomai 3. When >>>>>>>> trying to run the binary, these line appeared: >>>>>>>> WARNING: [main] no skin detected in program >>>>>>>> BUG: [main] initialization failed, EINVAL >>>>>>>> I know that this is a cooperplate_init() warning when trying to >>>>>>>> initialize >>>>>>>> native skin, but I don't understand the reason why: >>>>>>>> if (pvlist_empty(&skins)){ >>>>>>>> warning("no skin detected in program"); >>>>>>>> ret = -EINVAL; >>>>>>>> goto fail; >>>>>>>> } >>>>>>> >>>>>>> It seems that your application was not linked against libalchemy.so. >>>>>>> When API libraries are properly linked in, internal constructor routines >>>>>>> populate this list. POSIX support is built-in within the Cobalt >>>>>>> interface, so it won't appear here though. >>>>>>> >>>>> I change the order of the linker flags, now my app is linked against >>>>> libalchemy.so, but this message shown up: >>>>> symbol lookup error: /usr/xenomai/lib/libcopperplate.so.0: undefined >>>>> symbol: >>>>> main >>>>> >>>>> I guess that it stills a problem due to the linker flag, am I right? >>>>> >>>> >>>> Yes. You seem to be using a set of flags with fine-grained tuning, some >>>> of which might have an adverse effect on your linking stage. You should >>>> start with the set output by xeno-config --ldflags --alchemy which are >>>> known to work, then tune gradually as appropriate. >>>> >>> >>> Hi Philippe, >>> >>> I'm getting close to it, but it still left some undefined reference for rtdm >>> functions. >>> >> >> rtdm_socket() is a kernel-space API for inter-driver calls, socket() is >> what you need for creating a RTDM socket endpoint in your application. >> The Cobalt implementation will be used provided the linker is passed the >> proper flags (which you Makefile does). > > So that means I will always end up in calling socket() for all skins (alchemy > or cobalt) and let the linker flags differs it in kernel space?
The API layers for x3 are described here: http://xenomai.org/start-here/#How_does_Xenomai_deliver_real-time alchemy is one of the non-POSIX APIs. -- Philippe. _______________________________________________ Xenomai mailing list [email protected] http://www.xenomai.org/mailman/listinfo/xenomai
