Привет всем!
Помогите решить проблему с компиляцией ядра во Фре 4.8...
Машина 2-х процессорный Пень-100, встроенный СКАЗик Adaptec AIC 7870.
Оставил только
machine i386
#cpu I386_CPU
#cpu I486_CPU
cpu I586_CPU
#cpu I686_CPU
ident my
maxusers 256Подставил поддержку многопроцессорности,
# To make an SMP kernel, the next two are needed
options SMP # Symmetric MultiProcessor Kernel
options APIC_IO # Symmetric (APIC) I/Oи вбил файервольные строки
options IPFIREWALL
options IPFIREWALL_VERBOSE
options IPFIREWALL_VERBOSE_LIMIT=10
options IPDIVERTПри компиляции ядра дает ошибку.
Подскажите в чем БЕДА?# make
cc -c -O -pipe -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -fformat-extensions -ansi -nostdinc -I- -I. -I../.. -I/usr/include -I../../contrib/ipfilter -D_KERNEL -include opt_global.h -elf -mpreferred-stack-boundary=2 aic7xxx_reg_print.c
In file included from ../../dev/aic7xxx/aic7xxx_osm.h:44,
from aic7xxx_reg_print.c:9:
../../sys/bus.h:206: syntax error before `iNt'
../../sys/bus.h:207: warning: function declaration isn't a prototype
*** Error code 1Stop in /usr/src/sys/compile/my.
>Привет всем!
>Помогите решить проблему с компиляцией ядра во Фре 4.8...
>Машина 2-х процессорный Пень-100, встроенный СКАЗик Adaptec AIC 7870.
>Оставил только
>machine i386
>#cpu
>I386_CPU
>#cpu
>I486_CPU
>cpu
> I586_CPU
>#cpu
>I686_CPU
>ident my
>
>maxusers 256
>
>Подставил поддержку многопроцессорности,
># To make an SMP kernel, the next two are needed
>options SMP
>
> # Symmetric MultiProcessor Kernel
>
>options APIC_IO
>
> # Symmetric (APIC) I/O
>
>и вбил файервольные строки
>options IPFIREWALL
>options IPFIREWALL_VERBOSE
>options IPFIREWALL_VERBOSE_LIMIT=10
>options IPDIVERT
>
>При компиляции ядра дает ошибку.
>Подскажите в чем БЕДА?
>
># make
>cc -c -O -pipe -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith
>-Winline -Wcast-qual -fformat-extensions -ansi -nostdinc -I- -I. -I../.. -I/usr/include
>-I../../contrib/ipfilter -D_KERNEL -include opt_global.h -elf -mpreferred-stack-boundary=2 aic7xxx_reg_print.c
>In file included from ../../dev/aic7xxx/aic7xxx_osm.h:44,
>
> from aic7xxx_reg_print.c:9:
>../../sys/bus.h:206: syntax error before `iNt'
>../../sys/bus.h:207: warning: function declaration isn't a prototype
>*** Error code 1
>
>Stop in /usr/src/sys/compile/my.man 4 ahc?
сделал такие настройкиmachine i386
cpu I586_CPU
ident my
maxusers 256options NMBCLUSTERS=65536
#makeoptions DEBUG=-g #Build kernel with gdb(1) debug symbols
options MATH_EMULATE #Support for x87 emulation
options INET #InterNETworking
options FFS #Berkeley Fast Filesystem
options FFS_ROOT #FFS usable as root device [keep this!]
options SOFTUPDATES #Enable FFS soft updates support
options UFS_DIRHASH #Improve performance on big directories
options MFS #Memory Filesystem
options MD_ROOT #MD is a potential root device
options PROCFS #Process filesystem
options COMPAT_43 #Compatible with BSD 4.3 [KEEP THIS!]
options SCSI_DELAY=10000 #Delay (in ms) before probing SCSI
options UCONSOLE #Allow users to grab the console
options USERCONFIG #boot -c editor
options VISUAL_USERCONFIG #visual boot -c editor
options KTRACE #ktrace(1) support
options SYSVSHM #SYSV-style shared memory
options SYSVMSG #SYSV-style message queues
options SYSVSEM #SYSV-style semaphores
options P1003_1B #Posix P1003_1B real-time extensions
options _KPOSIX_PRIORITY_SCHEDULING
options ICMP_BANDLIM #Rate limit bad replies
options KBD_INSTALL_CDEV # install a CDEV entry in /dev# To make an SMP kernel, the next two are needed
options SMP # Symmetric MultiProcessor Kernel
options APIC_IO # Symmetric (APIC) I/O
device isa
device eisa
device pci# Floppy drives
device fdc0 at isa? port IO_FD1 irq 6 drq 2
device fd0 at fdc0 drive 0
# ATA and ATAPI devices
device ata0 at isa? port IO_WD1 irq 14
device ata1 at isa? port IO_WD2 irq 15
device ata
device atadisk # ATA disk drives
device atapifd # ATAPI floppy drives
options ATA_STATIC_ID #Static device numbering# SCSI Controllers
device ahc # AHA2940 and onboard AIC7xxx devices
options AHC_ALLOW_MEMIOdevice aic0 at isa?
# SCSI peripherals
device scbus # SCSI bus (required)
device da # Direct Access (disks)
device sa # Sequential Access (tape etc)
device cd # CD
device pass # Passthrough device (direct SCSI access)# atkbdc0 controls both the keyboard and the PS/2 mouse
device atkbdc0 at isa? port IO_KBD
device atkbd0 at atkbdc? irq 1 flags 0x1
device psm0 at atkbdc? irq 12device vga0 at isa?
# splash screen/screen saver
pseudo-device splash# syscons is the default console driver, resembling an SCO console
device sc0 at isa? flags 0x100# Floating point support - do not disable.
device npx0 at nexus? port IO_NPX irq 13# Serial (COM) ports
device sio0 at isa? port IO_COM1 flags 0x10 irq 4
device sio1 at isa? port IO_COM2 irq 3# Parallel port ?????????????????????????
#device ppc0 at isa? irq 7
#device ppbus # Parallel port bus (required)
#device lpt # Printer
#device plip # TCP/IP over parallel
#device ppi # Parallel port interface device
#device vpo # Requires scbus and da
# PCI Ethernet NICs that use the common MII bus controller code.
# NOTE: Be sure to keep the 'device miibus' line in order to use these NICs!
device miibus # MII bus support
device rl # RealTek 8129/8139# Pseudo devices - the number indicates how many units to allocate.
pseudo-device loop # Network loopback
pseudo-device ether # Ethernet support
pseudo-device sl 1 # Kernel SLIP
pseudo-device ppp 1 # Kernel PPP
pseudo-device tun # Packet tunnel.
pseudo-device pty # Pseudo-ttys (telnet etc)
pseudo-device md # Memory "disks"# The `bpf' pseudo-device enables the Berkeley Packet Filter.
# Be aware of the administrative consequences of enabling this!
pseudo-device bpf #Berkeley packet filteroptions IPFIREWALL
options IPFIREWALL_VERBOSE
options IPFIREWALL_VERBOSE_LIMIT=10
options IPDIVERT
Теперь другая ошибка???
cc -elf -shared -nostdlib hack.c -o hack.So
rm -f hack.c
sh ../../conf/newvers.sh MY
cc -c -O -pipe -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -fformat-extensions -ansi -nostdinc -I- -I. -I../.. -I/usr/include -I../../contrib/ipfilter -D_KERNEL -include opt_global.h -elf -mpreferred-stack-boundary=2 vers.c
linking kernel
ffs_vnops.o(.data+0x2c): undefined reference to `ffs_balloc'
*** Error code 1Stop in /usr/src/sys/compile/my.
# make
linking kernel
ffs_vnops.o(.data+0x2c): undefined reference to `ffs_balloc'
*** Error code 1Stop in /usr/src/sys/compile/my.
Где теперь копать?
Или я что-то не правильно сделал?
>сделал такие настройки
>
>machine i386
>cpu I586_CPU
>ident my
>maxusers 256
>
>options NMBCLUSTERS=65536
>
>#makeoptions DEBUG=-g #Build kernel with gdb(1) debug symbols
>
>options MATH_EMULATE #Support for x87 emulation
>options INET #InterNETworking
>options FFS #Berkeley Fast Filesystem
>options FFS_ROOT #FFS usable as root device [keep this!]
>options SOFTUPDATES #Enable FFS soft updates support
>options UFS_DIRHASH #Improve performance on big directories
>options MFS #Memory Filesystem
>options MD_ROOT #MD is a potential root device
>options PROCFS #Process filesystem
>options COMPAT_43 #Compatible with BSD 4.3 [KEEP THIS!]
>options SCSI_DELAY=10000 #Delay (in ms) before probing SCSI
>options UCONSOLE #Allow users to grab the console
>options USERCONFIG #boot -c editor
>options VISUAL_USERCONFIG #visual boot -c editor
>options KTRACE #ktrace(1) support
>options SYSVSHM #SYSV-style shared memory
>options SYSVMSG #SYSV-style message queues
>options SYSVSEM #SYSV-style semaphores
>options P1003_1B #Posix P1003_1B real-time extensions
>options _KPOSIX_PRIORITY_SCHEDULING
>options ICMP_BANDLIM #Rate limit bad replies
>options KBD_INSTALL_CDEV # install a CDEV entry in /dev
>
># To make an SMP kernel, the next two are needed
>options SMP # Symmetric MultiProcessor Kernel
>options APIC_IO # Symmetric (APIC) I/O
>
>
>device isa
>device eisa
>device pci
>
># Floppy drives
>device fdc0 at isa? port IO_FD1 irq 6 drq 2
>device fd0 at fdc0 drive 0
>
>
># ATA and ATAPI devices
>device ata0 at isa? port IO_WD1 irq 14
>device ata1 at isa? port IO_WD2 irq 15
>device ata
>device atadisk # ATA disk drives
>device atapifd # ATAPI floppy drives
>options ATA_STATIC_ID #Static device numbering
>
># SCSI Controllers
>device ahc # AHA2940 and onboard AIC7xxx devices
>options AHC_ALLOW_MEMIO
>
>
>
>device aic0 at isa?
>
># SCSI peripherals
>device scbus # SCSI bus (required)
>device da # Direct Access (disks)
>device sa # Sequential Access (tape etc)
>device cd # CD
>device pass # Passthrough device (direct SCSI access)
>
># atkbdc0 controls both the keyboard and the PS/2 mouse
>device atkbdc0 at isa? port IO_KBD
>device atkbd0 at atkbdc? irq 1 flags 0x1
>device psm0 at atkbdc? irq 12
>
>device vga0 at isa?
>
># splash screen/screen saver
>pseudo-device splash
>
># syscons is the default console driver, resembling an SCO console
>device sc0 at isa? flags 0x100
>
># Floating point support - do not disable.
>device npx0 at nexus? port IO_NPX irq 13
>
># Serial (COM) ports
>device sio0 at isa? port IO_COM1 flags 0x10 irq 4
>device sio1 at isa? port IO_COM2 irq 3
>
># Parallel port ?????????????????????????
>#device ppc0 at isa? irq 7
>#device ppbus # Parallel port bus (required)
>#device lpt # Printer
>#device plip # TCP/IP over parallel
>#device ppi # Parallel port interface device
>#device vpo # Requires scbus and da
>
>
># PCI Ethernet NICs that use the common MII bus controller code.
>
># NOTE: Be sure to keep the 'device miibus' line in order
>to use these NICs!
>device miibus # MII bus support
>device rl # RealTek 8129/8139
>
># Pseudo devices - the number indicates how many units to allocate.
>
>pseudo-device loop # Network loopback
>pseudo-device ether # Ethernet support
>pseudo-device sl 1 # Kernel SLIP
>pseudo-device ppp 1 # Kernel PPP
>pseudo-device tun # Packet tunnel.
>pseudo-device pty # Pseudo-ttys (telnet etc)
>pseudo-device md # Memory "disks"
>
># The `bpf' pseudo-device enables the Berkeley Packet Filter.
># Be aware of the administrative consequences of enabling this!
>pseudo-device bpf #Berkeley packet filter
>
>options IPFIREWALL
>options IPFIREWALL_VERBOSE
>options IPFIREWALL_VERBOSE_LIMIT=10
>options IPDIVERT
>
>
>Теперь другая ошибка???
>
>
>cc -elf -shared -nostdlib hack.c -o hack.So
>rm -f hack.c
>sh ../../conf/newvers.sh MY
>cc -c -O -pipe -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith
>-Winline -Wcast-qual -fformat-extensions -ansi -nostdinc -I- -I. -I../.. -I/usr/include
>-I../../contrib/ipfilter -D_KERNEL -include opt_global.h -elf -mpreferred-stack-boundary=2 vers.c
>linking kernel
>ffs_vnops.o(.data+0x2c): undefined reference to `ffs_balloc'
>*** Error code 1
>
>Stop in /usr/src/sys/compile/my.
># make
>linking kernel
>ffs_vnops.o(.data+0x2c): undefined reference to `ffs_balloc'
>*** Error code 1
>
>Stop in /usr/src/sys/compile/my.
>
>
>Где теперь копать?
>Или я что-то не правильно сделал?не знаю :)
возьми два ядра:
http://alone.dubna.ru:8080/~lavr/ALONE47
http://alone.dubna.ru:8080/~lavr/LAVRSCSIиз ALONE47 выкини лишнее, добавь что нужно, пример для SCSI смотри-бери
из LAVRSCSI# cp ALONE47 /sys/i386/conf/NEWKERNEL
# rm -rf /usr/obj/usr
# cd /usr/src
# make buildkernel KERNCONF=NEWKERNEL
# make installkernel KERNCONF=NEWKERNELчтобы понять ЧТО не так, нужно знать:
- что ты делал до сборки, производил ли cvsup(upgrade)
- на базе чего скомплектовал свое ядро и как собирал ПО ШАГАМ
...