On Mon, 2007-05-28 at 14:57 +0200, Perrine Martignoni wrote:
> Sorry for the details.
> I work on an ARM and I use the cross compiler ELDK version 4.1
> (build : 2007-01-22-uclibc).
>  
> When I compile sources of xenomai, I have this error message : 
>  
> -Wl,shm_unlink -Wl,--wrap -Wl,mmap -Wl,--wrap -Wl,munmap
> cyclictest-cyclictest.o  ../../skins/posix/.libs/libpthread_rt.a
> -lpthread -lrt
> 
> ../../skins/posix/.libs/libpthread_rt.a(libpthread_rt_la-shm.o): In
> function `__wrap_shm_open':
> 
> shm.c:(.text+0x74): undefined reference to `shm_open'
> 
> ../../skins/posix/.libs/libpthread_rt.a(libpthread_rt_la-shm.o): In
> function `__wrap_shm_unlink':
> 
> shm.c:(.text+0xdc): undefined reference to `shm_unlink'
> 
> collect2: ld returned 1 exit status
> 

Try adding this patch on top of the stock Xenomai release you are using:

--- include/asm-arm/syscall.h   (revision 2472)
+++ include/asm-arm/syscall.h   (working copy)
@@ -167,6 +167,22 @@
 
 #undef CONFIG_XENO_HW_DIRECT_TSC
 
+#include <errno.h>
+
+inline __attribute__((weak)) int shm_open(const char *name,
+                                         int oflag,
+                                         mode_t mode)
+{
+       errno = ENOSYS;
+       return -1;
+}
+
+inline __attribute__((weak)) int shm_unlink(const char *name)
+{
+       errno = ENOSYS;
+       return -1;
+}
+
 #endif /* __KERNEL__ */
 
 #define XENOMAI_SYSARCH_ATOMIC_ADD_RETURN      0

-- 
Philippe.



_______________________________________________
Xenomai-help mailing list
[email protected]
https://mail.gna.org/listinfo/xenomai-help

Reply via email to