* Re: [Xenomai] [Xenomai-git] Jan Kiszka : boilerplate: Allow for enabling Xenomai only in shared libs [not found] <E1aXuTj-0000rZ-UQ@sd-51317.xenomai.org> @ 2016-02-22 17:44 ` Gilles Chanteperdrix 2016-02-22 17:56 ` Jan Kiszka 0 siblings, 1 reply; 4+ messages in thread From: Gilles Chanteperdrix @ 2016-02-22 17:44 UTC (permalink / raw) To: xenomai; +Cc: xenomai-git On Mon, Feb 22, 2016 at 06:40:59PM +0100, git repository hosting wrote: > Module: xenomai-jki > Branch: for-forge > Commit: 4601286f7fedb8267ea314584fc68d2b35b818a4 > URL: http://git.xenomai.org/?p=xenomai-jki.git;a=commit;h=4601286f7fedb8267ea314584fc68d2b35b818a4 > > Author: Jan Kiszka <jan.kiszka@siemens.com> > Date: Fri Feb 5 17:33:18 2016 +0100 > > boilerplate: Allow for enabling Xenomai only in shared libs > > Normally, one builds shared libraries with Xenomai awareness by adding > --no-auto-init to xeno-config. This drops bootstrap.o from the linking > steps because - normally - the main application performs the > initialization. > > However, if the main application is Xenomai-free and only dlopen() would > pull in Xenomai services via a shared library, we face two problems: > > - bootstrap.o is not built with position-independence support > > - libboilerplate contains __real_main that expects the main symbol which > cannot be found from a shared library Does not the library find the program symbols if RTLD_GLOBAL is passed to dlopen? -- Gilles. https://click-hack.org ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Xenomai] [Xenomai-git] Jan Kiszka : boilerplate: Allow for enabling Xenomai only in shared libs 2016-02-22 17:44 ` [Xenomai] [Xenomai-git] Jan Kiszka : boilerplate: Allow for enabling Xenomai only in shared libs Gilles Chanteperdrix @ 2016-02-22 17:56 ` Jan Kiszka 0 siblings, 0 replies; 4+ messages in thread From: Jan Kiszka @ 2016-02-22 17:56 UTC (permalink / raw) To: Gilles Chanteperdrix, xenomai [please CC me on replies, I've delivery turned off for all lists] On 2016-02-22 18:44, Gilles Chanteperdrix wrote: > On Mon, Feb 22, 2016 at 06:40:59PM +0100, git repository hosting wrote: >> Module: xenomai-jki >> Branch: for-forge >> Commit: 4601286f7fedb8267ea314584fc68d2b35b818a4 >> URL: http://git.xenomai.org/?p=xenomai-jki.git;a=commit;h=4601286f7fedb8267ea314584fc68d2b35b818a4 >> >> Author: Jan Kiszka <jan.kiszka@siemens.com> >> Date: Fri Feb 5 17:33:18 2016 +0100 >> >> boilerplate: Allow for enabling Xenomai only in shared libs >> >> Normally, one builds shared libraries with Xenomai awareness by adding >> --no-auto-init to xeno-config. This drops bootstrap.o from the linking >> steps because - normally - the main application performs the >> initialization. >> >> However, if the main application is Xenomai-free and only dlopen() would >> pull in Xenomai services via a shared library, we face two problems: >> >> - bootstrap.o is not built with position-independence support >> >> - libboilerplate contains __real_main that expects the main symbol which >> cannot be found from a shared library > > Does not the library find the program symbols if RTLD_GLOBAL is > passed to dlopen? Nope, just retried, didn't help. In fact, RTLD_GLOBAL affects only the opened library's symbols, not the pre-existing ones. I think it is simply not possible with dlopen to refer back to a symbol from the code that loads the library. Jan -- Siemens AG, Corporate Technology, CT RDA ITP SES-DE Corporate Competence Center Embedded Linux ^ permalink raw reply [flat|nested] 4+ messages in thread
[parent not found: <E1aybuF-000446-5i@sd-51317.xenomai.org>]
* Re: [Xenomai] [Xenomai-git] Jan Kiszka : boilerplate: Allow for enabling Xenomai only in shared libs [not found] <E1aybuF-000446-5i@sd-51317.xenomai.org> @ 2016-05-06 9:22 ` Gilles Chanteperdrix 2016-05-09 8:56 ` Jan Kiszka 0 siblings, 1 reply; 4+ messages in thread From: Gilles Chanteperdrix @ 2016-05-06 9:22 UTC (permalink / raw) To: xenomai; +Cc: xenomai-git On Fri, May 06, 2016 at 11:18:43AM +0200, git repository hosting wrote: > diff --git a/lib/boilerplate/init/Makefile.am b/lib/boilerplate/init/Makefile.am > index 7a58f54..8c09e28 100644 > --- a/lib/boilerplate/init/Makefile.am > +++ b/lib/boilerplate/init/Makefile.am > @@ -4,6 +4,7 @@ libbootstrap_a_SOURCES = bootstrap.c > > libbootstrap_a_CPPFLAGS = \ > @XENO_USER_CFLAGS@ \ > + -fPIC \ > -I$(top_srcdir)/include \ > -I$(top_srcdir)/lib This is not how this should be done. -- Gilles. https://click-hack.org ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Xenomai] [Xenomai-git] Jan Kiszka : boilerplate: Allow for enabling Xenomai only in shared libs 2016-05-06 9:22 ` Gilles Chanteperdrix @ 2016-05-09 8:56 ` Jan Kiszka 0 siblings, 0 replies; 4+ messages in thread From: Jan Kiszka @ 2016-05-09 8:56 UTC (permalink / raw) To: Gilles Chanteperdrix, xenomai, Philippe Gerum On 2016-05-06 11:22, Gilles Chanteperdrix wrote: > On Fri, May 06, 2016 at 11:18:43AM +0200, git repository hosting wrote: >> diff --git a/lib/boilerplate/init/Makefile.am b/lib/boilerplate/init/Makefile.am >> index 7a58f54..8c09e28 100644 >> --- a/lib/boilerplate/init/Makefile.am >> +++ b/lib/boilerplate/init/Makefile.am >> @@ -4,6 +4,7 @@ libbootstrap_a_SOURCES = bootstrap.c >> >> libbootstrap_a_CPPFLAGS = \ >> @XENO_USER_CFLAGS@ \ >> + -fPIC \ >> -I$(top_srcdir)/include \ >> -I$(top_srcdir)/lib > > This is not how this should be done. > The patch was just still in my queue when I rebased, as reminder of the unsolved issue. Now I remember that Philippe and I discussed this a while back and he had some ideas. They are probably still on the stack of to-dos. I'll move this to the top and keep it local - as reminder. Jan -- Siemens AG, Corporate Technology, CT RDA ITP SES-DE Corporate Competence Center Embedded Linux ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2016-05-09 8:56 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <E1aXuTj-0000rZ-UQ@sd-51317.xenomai.org>
2016-02-22 17:44 ` [Xenomai] [Xenomai-git] Jan Kiszka : boilerplate: Allow for enabling Xenomai only in shared libs Gilles Chanteperdrix
2016-02-22 17:56 ` Jan Kiszka
[not found] <E1aybuF-000446-5i@sd-51317.xenomai.org>
2016-05-06 9:22 ` Gilles Chanteperdrix
2016-05-09 8:56 ` Jan Kiszka
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.