On 2017-03-16 07:41, Matthias Apitz wrote: > > > Hello, > > I have an older FreeBSD 9.0-CURRENT system which I want to update to > 12-CURRENT: > > # uname -a > FreeBSD vm-9Current 9.0-CURRENT FreeBSD 9.0-CURRENT #2 r220692: Sun Apr 17 03:28:12 CEST 2011 guru_at_tinyCurrent:/usr/obj/usr/src/sys/GENERIC i386 > > To do so without compiling everything from scratch, I transferred > /usr/src (r314251) and /usr/obj to this server, the compilation of > /usr/obj was done on an amd64 server and the same procedure (transfer > of /usr/src and /usr/obj) was also used to update my C720 netbook; the > difference is here that the host which should be update is i386. > > The 'make installkernel' did not work: > > # pwd > /usr/src > # file ../obj/usr/src/sys/GENERIC/kernel > ../obj/usr/src/sys/GENERIC/kernel: ELF 64-bit LSB executable, x86-64, version 1 (FreeBSD), dynamically linked (uses shared libs), not stripped > > # make installkernel > > -------------------------------------------------------------- >>>> Building an up-to-date bmake(1) > -------------------------------------------------------------- > sh /usr/src/tools/install.sh -s -o root -g wheel -m 555 make > /usr/obj/usr/src/make.i386/bmake > -------------------------------------------------------------- >>>> Installing kernel GENERIC > -------------------------------------------------------------- > cd /usr/obj/usr/src/sys/GENERIC; MAKEOBJDIRPREFIX=/usr/obj > MACHINE_ARCH=i386 MACHINE=i386 CPUTYPE= > GROFF_BIN_PATH=/usr/obj/usr/src/tmp/legacy/usr/bin > GROFF_FONT_PATH=/usr/obj/usr/src/tmp/legacy/usr/share/groff_font > GROFF_TMAC_PATH=/usr/obj/usr/src/tmp/legacy/usr/share/tmac CC="cc > -isystem /usr/obj/usr/src/tmp/usr/include -L/usr/obj/usr/src/tmp/usr/lib > -B/usr/obj/usr/src/tmp/usr/lib --sysroot=/usr/obj/usr/src/tmp > -B/usr/obj/usr/src/tmp/usr/bin" CXX="c++ -isystem > /usr/obj/usr/src/tmp/usr/include -L/usr/obj/usr/src/tmp/usr/lib > -B/usr/obj/usr/src/tmp/usr/lib --sysroot=/usr/obj/usr/src/tmp > -B/usr/obj/usr/src/tmp/usr/bin" CPP="cpp -isystem > /usr/obj/usr/src/tmp/usr/include -L/usr/obj/usr/src/tmp/usr/lib > -B/usr/obj/usr/src/tmp/usr/lib --sysroot=/usr/obj/usr/src/tmp > -B/usr/obj/usr/src/tmp/usr/bin" AS="as" AR="ar" LD="ld" LLVM_LINK="" > NM=nm OBJCOPY="objcopy" RANLIB=ranlib STRINGS= SIZE="size" > PATH=/usr/obj/usr/src/tmp/legacy/usr/sbin:/usr/obj/usr/src/tmp/legacy/usr/bin:/usr/obj/usr/src/tmp/legacy/bin:/usr/obj/usr/src/tmp/usr/sbin:/usr/obj/usr/src/tmp/usr/bin:/sbin:/bin:/usr/sbin:/usr/bin > /usr/obj/usr/src/make.i386/bmake KERNEL=kernel install > cc: Exec format error > bmake[1]: "/usr/src/share/mk/bsd.compiler.mk" line 145: Unable to > determine compiler type for CC=cc -isystem > /usr/obj/usr/src/tmp/usr/include -L/usr/obj/usr/src/tmp/usr/lib > -B/usr/obj/usr/src/tmp/usr/lib --sysroot=/usr/obj/usr/src/tmp > -B/usr/obj/usr/src/tmp/usr/bin. Consider setting COMPILER_TYPE. > *** Error code 1 > > > Also the following did not work: > > # make installkernel MACHINE_ARCH=amd64 MACHINE=amd64 > > -------------------------------------------------------------- >>>> Building an up-to-date bmake(1) > -------------------------------------------------------------- > sh /usr/src/tools/install.sh -s -o root -g wheel -m 555 make > /usr/obj/usr/src/make.amd64/bmake > -------------------------------------------------------------- >>>> Installing kernel GENERIC > -------------------------------------------------------------- > cd /usr/obj/usr/src/sys/GENERIC; MAKEOBJDIRPREFIX=/usr/obj > MACHINE_ARCH=amd64 MACHINE=amd64 CPUTYPE= > GROFF_BIN_PATH=/usr/obj/usr/src/tmp/legacy/usr/bin > GROFF_FONT_PATH=/usr/obj/usr/src/tmp/legacy/usr/share/groff_font > GROFF_TMAC_PATH=/usr/obj/usr/src/tmp/legacy/usr/share/tmac CC="cc > -isystem /usr/obj/usr/src/tmp/usr/include -L/usr/obj/usr/src/tmp/usr/lib > -B/usr/obj/usr/src/tmp/usr/lib --sysroot=/usr/obj/usr/src/tmp > -B/usr/obj/usr/src/tmp/usr/bin" CXX="c++ -isystem > /usr/obj/usr/src/tmp/usr/include -L/usr/obj/usr/src/tmp/usr/lib > -B/usr/obj/usr/src/tmp/usr/lib --sysroot=/usr/obj/usr/src/tmp > -B/usr/obj/usr/src/tmp/usr/bin" CPP="cpp -isystem > /usr/obj/usr/src/tmp/usr/include -L/usr/obj/usr/src/tmp/usr/lib > -B/usr/obj/usr/src/tmp/usr/lib --sysroot=/usr/obj/usr/src/tmp > -B/usr/obj/usr/src/tmp/usr/bin" AS="as" AR="ar" LD="ld" LLVM_LINK="" > NM=nm OBJCOPY="objcopy" RANLIB=ranlib STRINGS= SIZE="size" > PATH=/usr/obj/usr/src/tmp/legacy/usr/sbin:/usr/obj/usr/src/tmp/legacy/usr/bin:/usr/obj/usr/src/tmp/legacy/bin:/usr/obj/usr/src/tmp/usr/sbin:/usr/obj/usr/src/tmp/usr/bin:/sbin:/bin:/usr/sbin:/usr/bin > /usr/obj/usr/src/make.i386/bmake KERNEL=kernel install > cc: Exec format error > bmake[1]: "/usr/src/share/mk/bsd.compiler.mk" line 145: Unable to > determine compiler type for CC=cc -isystem > /usr/obj/usr/src/tmp/usr/include -L/usr/obj/usr/src/tmp/usr/lib > -B/usr/obj/usr/src/tmp/usr/lib --sysroot=/usr/obj/usr/src/tmp > -B/usr/obj/usr/src/tmp/usr/bin. Consider setting COMPILER_TYPE. > *** Error code 1 > > > Is there a way to use this /usr/src and pre-compiled /usr/obj on an i386 > host for update? Or do I have to use a complete recompile or even > reinstall, based on a 64-bit memstick system? > > Thanks > > matthias > > The problem is that the build system has built a cross compiler in /usr/obj that it uses to do the building etc, and it is 64bit. Your 32bit OS cannot run it (gives Exec format error). You could try (untested, might eat your lunch, and kick your dog) On the AMD64 host: mkdir /tmp/amd64 make installkernel DESTDIR=/tmp/amd64 Then manually copy that kernel & modules into /boot/kernel on the i386 system, and reboot into it. Then you'll have a 64bit kernel, and your old i386 world. Then you should be able to do the make installkernel / installworld from the /usr/src and /usr/obj you transferred -- Allan Jude
This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:41:10 UTC