Re: [Xenomai-core] Xenomai in Debian
Roland Stigge wrote: > Hi, > > I'm just working on the Xenomai 2.5.1 Debian package and encountered > non-PIC code (evil! ;-) in the shared libraries (skins libraries). > > You can see it with e.g. > > $ readelf -d src/skins/native/.libs/libnative.so.3.0.0 > > The "TEXTREL" tag indicates non-PIC code. > > $ scanelf -qT src/skins/native/.libs/libnative.so.3.0.0 > > Shows the function and code offset of the relocation. > > With > > $ objdump -d src/skins/native/.libs/libnative.so.3.0.0 > > I found the actual location of the relocation. > > I prepared a patch (attached) that fixes it: First, the relocation > itself by letting GCC create the address in PIC style. Second, "extern > inline" looks a bit counterintuitive at first, but according to the GCC > manual, it seems to be what we want (macro behaviour). > > Thanks Jan for reminding me! Glad to hear that debian work on Xenomai has resumed. Merged, thanks. -- Gilles. ___ Xenomai-core mailing list Xenomai-core@gna.org https://mail.gna.org/listinfo/xenomai-core
Re: [Xenomai-core] [PULL REQUEST] analogy: bug fixes + insn_bits
Alexis Berlemont wrote: > The following changes since commit 4a5b93dabf66529e665c8f8422902347d4f6158f: >Jan Kiszka (1): > RTDM: Split up application and driver debugging > > are available in the git repository at: > >git://git.xenomai.org/xenomai-abe.git analogy Merged. -- Gilles. ___ Xenomai-core mailing list Xenomai-core@gna.org https://mail.gna.org/listinfo/xenomai-core
[Xenomai-core] Xenomai in Debian
Hi, I'm just working on the Xenomai 2.5.1 Debian package and encountered non-PIC code (evil! ;-) in the shared libraries (skins libraries). You can see it with e.g. $ readelf -d src/skins/native/.libs/libnative.so.3.0.0 The "TEXTREL" tag indicates non-PIC code. $ scanelf -qT src/skins/native/.libs/libnative.so.3.0.0 Shows the function and code offset of the relocation. With $ objdump -d src/skins/native/.libs/libnative.so.3.0.0 I found the actual location of the relocation. I prepared a patch (attached) that fixes it: First, the relocation itself by letting GCC create the address in PIC style. Second, "extern inline" looks a bit counterintuitive at first, but according to the GCC manual, it seems to be what we want (macro behaviour). Thanks Jan for reminding me! bye, Roland --- xenomai-2.5.1.orig/include/asm-x86/syscall.h +++ xenomai-2.5.1/include/asm-x86/syscall.h @@ -161,9 +161,11 @@ ".endif\n\t" ".endm\n\t"); -static inline void __xn_get_eip(void **dest) +__attribute__((always_inline)) +extern inline void __xn_get_eip(void **dest) { -asm volatile("movl $1f, %0; 1:": "=m"(*dest)); +addr: + *dest = &&addr; } static inline void __xn_get_ebp(void **dest) ___ Xenomai-core mailing list Xenomai-core@gna.org https://mail.gna.org/listinfo/xenomai-core