Hi, I would to like to use the rtai kernel patches on Debian Wheezy (Debian-Package rtai-source) on the i386 architecture, which are currently only available for various releases of Linux 2.6. As the most recent kernel patch included in rtai-source was hal-linux-126.96.36.199-x86-2.6-03.patch.gz, I first tried to compile the vanilla kernel 188.8.131.52 with gcc-4.7 from Wheezy and using make-kpkg (with .config copied from linux-image-2.6.32-5-686). It failed compiling ptrace.c (the problem has already been described in https://lkml.org/lkml/2012/8/9/281). Using the patch from the linux-kernel-mailinglist from above the compile process got further, but it fails at gcc -nostdlib -o arch/x86/vdso/vdso32-int80.so.dbg -fPIC -shared -Wl,--hash-style=sysv -m elf_i386 -Wl,-soname=linux-gate.so.1 -Wl,-T,arch/x86/vdso/vdso32/vdso32.lds arch/x86/vdso/vdso32/note.o arch/x86/vdso/vdso32/int80.o gcc: error: unrecognized command line option '-m' gcc: error: elf_i386: No such file or directory As I am using an i386 system anyway, I simply patched -m elf_i386 away (which probably the Makefile when crosscompiling from amd64 to i386, see attached patch for details). I assume -march=i386 would be a proper replacement, but I am not sure about that. Next problem occured at compiling an Intel network driver: gcc -Wp,-MD,drivers/net/igbvf/.ethtool.o.d -nostdinc -isystem /usr/lib/gcc/i486-linux-gnu/4.7/include -nostdinc -isystem /usr/lib/gcc/i486-linux-gnu/4.7/include -Iinclude -I/home/ceet/benedikt/vanilla-linux/linux-184.108.40.206/arch/x86/include -include include/linux/autoconf.h -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -fno-delete-null-pointer-checks -Os -m32 -msoft-float -mregparm=3 -freg-struct-return -mpreferred-stack-boundary=2 -march=i686 -mtune=generic -Wa,-mtune=generic32 -ffreestanding -fstack-protector -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -Wframe-larger-than=1024 -fomit-frame-pointer -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fno-dwarf2-cfi-asm -fconserve-stack -DMODULE -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(ethtool)" -D"KBUILD_MODNAME=KBUILD_STR(igbvf)" -c -o drivers/net/igbvf/.tmp_ethtool.o drivers/net/igbvf/ethtool.c In file included from include/linux/irq.h:29:0, from /home/ceet/benedikt/vanilla-linux/linux-220.127.116.11/arch/x86/include/asm/hardirq.h:5, from include/linux/hardirq.h:10, from include/linux/interrupt.h:12, from include/linux/netdevice.h:1070, from drivers/net/igbvf/ethtool.c:30: /home/ceet/benedikt/vanilla-linux/linux-18.104.22.168/arch/x86/include/asm/irq_regs.h: In function 'set_irq_regs': /home/ceet/benedikt/vanilla-linux/linux-22.214.171.124/arch/x86/include/asm/irq_regs.h:26:2: warning: variable 'tmp__' set but not used [-Wunused-but-set-variable] In file included from /home/ceet/benedikt/vanilla-linux/linux-126.96.36.199/arch/x86/include/asm/hardirq.h:5:0, from include/linux/hardirq.h:10, from include/linux/interrupt.h:12, from include/linux/netdevice.h:1070, from drivers/net/igbvf/ethtool.c:30: include/linux/irq.h: In function 'alloc_desc_masks': include/linux/irq.h:441:8: warning: variable 'gfp' set but not used [-Wunused-but-set-variable] In file included from drivers/net/igbvf/ethtool.c:36:0: drivers/net/igbvf/igbvf.h: At top level: drivers/net/igbvf/igbvf.h:128:15: error: duplicate member 'page' make: *** [drivers/net/igbvf/ethtool.o] Error 1 make: *** [drivers/net/igbvf] Error 2 make: *** [drivers/net] Error 2 make: *** [drivers] Error 2 make: *** [deb-pkg] Error 2 make: *** [deb-pkg] Error 2 Of course I could find some way to go around this error, but I assume I either did something fundamentally wrong or I'll have to file a bug against some package (gcc?). Does anybody have an idea? Regards, Benedikt Wildenhain P.S.: Compiling this kernel using gcc-4.4 from oldstable works, I am currently trying to compile it together with the rtai-patches, but that doesn't feel like the way rtai-source is meant to be used. -- Benedikt Wildenhain, M.Sc., Wiss. Mitarbeiter - Hardwarenahe IT-Systeme Hochschule Bochum - Bochum University of Applied Sciences Campus Velbert/Heiligenhaus - http://www.hs-bochum.de/cvh/ Höseler Platz 2, Heiligenhaus, Raum 2.28, Tel +49 (0)2056 158744
--- a/arch/x86/vdso/Makefile 2013-10-22 14:14:38.000000000 +0200 +++ b/arch/x86/vdso/Makefile 2013-10-22 14:14:09.000000000 +0200 @@ -69,7 +69,7 @@ vdso32-images = $(vdso32.so-y:%=vdso32-%.so) CPPFLAGS_vdso32.lds = $(CPPFLAGS_vdso.lds) -VDSO_LDFLAGS_vdso32.lds = -m elf_i386 -Wl,-soname=linux-gate.so.1 +VDSO_LDFLAGS_vdso32.lds = -Wl,-soname=linux-gate.so.1 # This makes sure the $(obj) subdirectory exists even though vdso32/ # is not a kbuild sub-make subdirectory.
Description: Digital signature