Skip to contentSkip to conversation

forge/cobalt: Do we need to wrap all POSIX calls for non-POSIX skins?

Xenomai Jan Kiszka 3 participants 6 messages Jan 31, 2014 – Feb 3, 2014

lore
Share & tools
lore

Jan Kiszka

author
#0 lore raw

Hi,

was asked why, e.g., xeno-config --skin=alchemy --ldflags returns -Wl,@/data/xenomai-forge/inst64/lib/cobalt.wrappers. Is there a technical reason? On first glance and after minimal testing, it seems not.

Jan

Signature · 2 lines
Siemens AG, Corporate Technology, CT RTC ITP SES-DE
Corporate Competence Center Embedded Linux
#1 lore raw
Quoted 5 lines · Jan Kiszka

Hi,

was asked why, e.g., xeno-config --skin=alchemy --ldflags returns -Wl,@/data/xenomai-forge/inst64/lib/cobalt.wrappers. Is there a technical reason? On first glance and after minimal testing, it seems not.

Maybe we could drop xeno-config entirely, and move to pkg-config? This forces users which develop for Xenomai to have pkg-config installed, but who does not have it these days?

Signature · 1 line
					    Gilles.
author
#2 lore raw
Quoted 11 lines · Gilles Chanteperdrix
Quoted 6 lines · Jan Kiszka

Hi,

was asked why, e.g., xeno-config --skin=alchemy --ldflags returns -Wl,@/data/xenomai-forge/inst64/lib/cobalt.wrappers. Is there a technical reason? On first glance and after minimal testing, it seems not.

Maybe we could drop xeno-config entirely, and move to pkg-config? This forces users which develop for Xenomai to have pkg-config installed, but who does not have it these days?

Well, the way we transport the information is one thing (xeno-config vs. pkg-config - I'm not against the latter!), but this question is related to the content first of all.

Jan

Signature · 2 lines
Siemens AG, Corporate Technology, CT RTC ITP SES-DE
Corporate Competence Center Embedded Linux
#4 lore raw
In reply to Jan Kiszka
Quoted 6 lines · Jan Kiszka

Hi,

was asked why, e.g., xeno-config --skin=alchemy --ldflags returns -Wl,@/data/xenomai-forge/inst64/lib/cobalt.wrappers. Is there a technical reason? On first glance and after minimal testing, it seems not.

There is no technical reason, since all libs are required to use manual wrapping for these symbols (e.g. __RT()/__STD()) to keep automatic wrapping via the linker optional.

The current assumption is that application code using cobalt-provided routines do want such wrapping to take place automatically, for mixing APIs.

OTOH, we could require such applications to mention --posix explicitly for enabling this feature. It makes sense either way. We need to ponder which one follows the principle of least astonishment.

Signature · 1 line
Philippe.
#3 lore raw
In reply to Gilles Chanteperdrix
Quoted 13 lines · Gilles Chanteperdrix
Quoted 6 lines · Jan Kiszka

Hi,

was asked why, e.g., xeno-config --skin=alchemy --ldflags returns -Wl,@/data/xenomai-forge/inst64/lib/cobalt.wrappers. Is there a technical reason? On first glance and after minimal testing, it seems not.

Maybe we could drop xeno-config entirely, and move to pkg-config? This forces users which develop for Xenomai to have pkg-config installed, but who does not have it these days?

xeno-config is sometimes used on the target as well, for retrieving installation parameters.

Signature · 1 line
Philippe.
author
#5 lore raw
In reply to Philippe Gerum
Quoted 13 lines · Philippe Gerum
Quoted 7 lines · Jan Kiszka

Hi,

was asked why, e.g., xeno-config --skin=alchemy --ldflags returns -Wl,@/data/xenomai-forge/inst64/lib/cobalt.wrappers. Is there a technical reason? On first glance and after minimal testing, it seems not.

There is no technical reason, since all libs are required to use manual wrapping for these symbols (e.g. __RT()/__STD()) to keep automatic wrapping via the linker optional.

Quoted 7 lines

The current assumption is that application code using cobalt-provided routines do want such wrapping to take place automatically, for mixing APIs.

OTOH, we could require such applications to mention --posix explicitly for enabling this feature. It makes sense either way. We need to ponder which one follows the principle of least astonishment.

I would suggest explicit listing of --skin=posix|cobalt, thus this patch:
http://git.xenomai.org/xenomai-jki.git/commit/?h=for-forge&id=eb8a1d4a69836c073461947eaab775b5fc7c01aa.
That is more consistent because there is no way to disable that wrapping (except for fragile filtering on the returned ldflags).

Jan

Signature · 2 lines
Siemens AG, Corporate Technology, CT RTC ITP SES-DE
Corporate Competence Center Embedded Linux