Newsgroup: it.comp.os.linux.iniziare
Titolo: Kernel 2.6.3 e user-mode-linux

Ciao a tutti,
sto provando a compilare il kernel 2.6.3 per usare uml su una mdk 9.2, ma
mi da strani errori di compilazione.
Quello che faccio è:
make mrproper ARCH=um --> tutto OK
make defconfig ARCH=um --> tutto OK
make linux ARCH=um --> da ciò che segue
make[1]: `arch/um/sys-i386/util/mk_sc' is up to date.
  CC      arch/um/util/mk_task_kern.o
In file included from include/asm/system-generic.h:4,
                 from include/asm/system.h:4,
                 from include/linux/list.h:8,
                 from include/linux/signal.h:4,
                 from include/asm/processor-generic.h:14,
                 from include/asm/processor.h:22,
                 from include/asm/thread_info.h:11,
                 from include/linux/thread_info.h:21,
                 from include/linux/spinlock.h:12,
                 from include/linux/capability.h:45,
                 from include/linux/sched.h:7,
                 from arch/um/util/mk_task_kern.c:1:
include/asm/arch/system.h:7:28: asm/cpufeature.h: No such file or directory
In file included from include/linux/time.h:28,
                 from include/asm/arch/signal.h:6,
                 from include/asm/signal.h:12,
                 from include/linux/signal.h:6,
                 from include/asm/processor-generic.h:14,
                 from include/asm/processor.h:22,
                 from include/asm/thread_info.h:11,
                 from include/linux/thread_info.h:21,
                 from include/linux/spinlock.h:12,
                 from include/linux/capability.h:45,
                 from include/linux/sched.h:7,
                 from arch/um/util/mk_task_kern.c:1:
include/linux/seqlock.h:35: error: syntax error before "spinlock_t"
include/linux/seqlock.h:35: warning: no semicolon at end of struct or union
include/linux/seqlock.h:36: warning: type defaults to `int' in declaration of `seqlock_t'
include/linux/seqlock.h:36: warning: data definition has no type or storage class
include/linux/seqlock.h:50: error: syntax error before '*' token
include/linux/seqlock.h:51: warning: function declaration isn't a prototype
include/linux/seqlock.h: In function `write_seqlock':
include/linux/seqlock.h:52: warning: implicit declaration of function `spin_lock'
include/linux/seqlock.h:52: error: `sl' undeclared (first use in this function)
include/linux/seqlock.h:52: error: (Each undeclared identifier is reported only once
include/linux/seqlock.h:52: error: for each function it appears in.)
include/linux/seqlock.h: At top level:
include/linux/seqlock.h:57: error: syntax error before '*' token
include/linux/seqlock.h:58: warning: function declaration isn't a prototype
include/linux/seqlock.h: In function `write_sequnlock':
include/linux/seqlock.h:60: error: `sl' undeclared (first use in this function)
include/linux/seqlock.h:61: warning: implicit declaration of function `spin_unlock'
include/linux/seqlock.h: At top level:
include/linux/seqlock.h:64: error: syntax error before '*' token
include/linux/seqlock.h:65: warning: function declaration isn't a prototype
include/linux/seqlock.h: In function `write_tryseqlock':
include/linux/seqlock.h:66: warning: implicit declaration of function `spin_trylock'
include/linux/seqlock.h:66: error: `sl' undeclared (first use in this function)
include/linux/seqlock.h: At top level:
include/linux/seqlock.h:76: warning: type defaults to `int' in declaration of `seqlock_t'
include/linux/seqlock.h:76: error: syntax error before '*' token
include/linux/seqlock.h:77: warning: function declaration isn't a prototype
include/linux/seqlock.h: In function `read_seqbegin':
include/linux/seqlock.h:78: error: `sl' undeclared (first use in this function)
include/linux/seqlock.h: At top level:
include/linux/seqlock.h:91: warning: type defaults to `int' in declaration of `seqlock_t'
include/linux/seqlock.h:91: error: syntax error before '*' token
include/linux/seqlock.h:92: warning: function declaration isn't a prototype
include/linux/seqlock.h: In function `read_seqretry':
include/linux/seqlock.h:94: error: `iv' undeclared (first use in this function)
include/linux/seqlock.h:94: error: `sl' undeclared (first use in this function)
In file included from include/asm/arch/signal.h:6,
                 from include/asm/signal.h:12,
                 from include/linux/signal.h:6,
                 from include/asm/processor-generic.h:14,
                 from include/asm/processor.h:22,
                 from include/asm/thread_info.h:11,
                 from include/linux/thread_info.h:21,
                 from include/linux/spinlock.h:12,
                 from include/linux/capability.h:45,
                 from include/linux/sched.h:7,
                 from arch/um/util/mk_task_kern.c:1:
include/linux/time.h: At top level:
include/linux/time.h:297: error: syntax error before "xtime_lock"
include/linux/time.h:297: warning: type defaults to `int' in declaration of `xtime_lock'
include/linux/time.h:297: warning: data definition has no type or storage class
In file included from include/asm/processor-generic.h:14,
                 from include/asm/processor.h:22,
                 from include/asm/thread_info.h:11,
                 from include/linux/thread_info.h:21,
                 from include/linux/spinlock.h:12,
                 from include/linux/capability.h:45,
                 from include/linux/sched.h:7,
                 from arch/um/util/mk_task_kern.c:1:
include/linux/signal.h:16: error: syntax error before "spinlock_t"
include/linux/signal.h:16: warning: no semicolon at end of struct or union
include/linux/signal.h:19: error: syntax error before '}' token
make[1]: *** [arch/um/util/mk_task_kern.o] Error 1
make: *** [arch/um/util] Error 2
Quale può essere il problema? Dove sbaglio?
Ho già compilato il 2.4.24 senza problemi, ma vorrei riuscire anche con
il 2.6.
Grazie per l'aiuto,
Davide

 Quale può essere il problema? Dove sbaglio?
Il problema è che le patch per UML non entrano nei kernel di Linus.
Prova con le patch di Andrew Morton (le patch 2.6.3-mm* da
applicare a un normale 2.6.3).
-- 
Lorenzo

 applicare a un normale 2.6.3).
Ho provato ma l'errore è uguale.
Quello che mi chiedo è se qualcuno riesce a compilare uml con i kernel
2.6. Ho provato anche su una slack 9.1 ma non si compila neanche lì dando
lo stesso errore.
Non potrebbe essere un problema di librerie?
Ciao,
Davide

 Non potrebbe essere un problema di librerie?
Non credo, se non ricordo male UML č una normale applicazione che usa
solo glibc.
-- 
Lorenzo

 
http://prdownloads.sourceforge.net/user-mode-linux/uml-patch-2.6.3-rc2-1.bz2
Funziona perfettamente e si applica in modo pulito anche sul 2.6.3 finale.
Grazie per l'aiuto.
Ciao,
Davide