Broken ports while updating 7.4 -> 8.0 -> 8.4

I'm trying to update my old system: 7.4-RELEASE-p5 -> 8.4-RELEASE-p36
After running # cd /usr/src and # make buildworld:
Code:
===> lib/libmagic (obj,build-tools)
/var/tmp//cc46YY2J.o(.text+0xdfb): In function `load_1':
: undefined reference to `getline'
*** Error code 1
1 error
*** Error code 2
1 error
*** Error code 2
1 error
*** Error code 2
1 error
Can't find workaroud or solution....
 
Both versions have been End-of-Life for quite some time. All I can suggest is to just backup the data and install a fresh copy with a recent version. You could try the source update straight to 9.3 but it's not a recommended step to take.
 
Did you clean out your old source files? If not remove, /usr/obj and try again. It's possible you may be trying to jump ahead too many versions. You may want to go with 7.4 -> 8.0 -> 8.4 -> 9.x (definitely try to get up to 9x) Each major version upgrade, you'll probably want to recompile ports (if you manually compile).
 
you'll probably want to recompile ports (if you manually compile).
Yeah, that's going to be the next issue. Sometimes it's simpler just to make a note of all the installed ports/packages, remove them all, then update the OS to the version you want. Once it's up and running correctly you can use the list you made earlier to install all the ports/packages again.

None of the ports/packages you have installed should be the reason why you can't properly buildworld though. Unless you've set an alternative C compiler in /etc/make.conf. So make sure that's not causing issues.
 
I once did an upgrade from 7.4 directly to 9.1-RC3 by building the sources on a faster machine and nc-ing a tar image of /usr/src and /usr/obj to the target machine, and then doing the installs there. It worked OK. You should be able to do something similar if you have another machine to build on, but it might be easier in the long run just to back it all up, do a fresh install, and restore your data & applications.
 
Did you clean out your old source files? If not remove, /usr/obj and try again. It's possible you may be trying to jump ahead too many versions. You may want to go with 7.4 -> 8.0 -> 8.4 -> 9.x (definitely try to get up to 9x) Each major version upgrade, you'll probably want to recompile ports (if you manually compile).
Thanks, I've updated to 8.0. But now when I trying to make any port, I've got a lots of errors like:
Code:
Unknown modifier 't'
Then I've installed bmake:
Code:
pkg_add bmake.tbz
mv /usr/bin/make /usr/bin/make.old
ln /usr/local/bin/bmake /usr/bin/make
And now I get this:
Code:
make: no system rules (sys.mk).
How to revive/update ports?
/usr/ports was missed so I've get a fresh copy:
Code:
portsnap fetch && portsnap extract
svn checkout https://svn0.eu.FreeBSD.org/ports/head /usr/ports

P.S.
sys.mk is present: /usr/share/mk/sys.mk /usr/src/share/mk/sys.mk
 
I once did an upgrade from 7.4 directly to 9.1-RC3 by building the sources on a faster machine and nc-ing a tar image of /usr/src and /usr/obj to the target machine, and then doing the installs there. It worked OK. You should be able to do something similar if you have another machine to build on, but it might be easier in the long run just to back it all up, do a fresh install, and restore your data & applications.
That's interesting and brave move, but I'm not sure I can do the same.... (And you didn't describe the entire process.)
 
That's interesting and brave move, but I'm not sure I can do the same.... (And you didn't describe the entire process.)

It's very simple. I had a fast machine already running the version I wanted to upgrade to, so I built a kernel configuration file for the target machine on the build system, SVN'ed a clean source tree, and did the make buildworld and make buildkernel KERNCONF=xxxx steps on the build system. Then I copied the entire /usr/src and /usr/obj file trees to the target system (I used tar and nc, but it doesn't really matter how you do it; SirDice recommends just NFS mounting them if possible). I then performed the make installkernel KERNCONF=xxxx and make installworld steps on the target machine, and rebooted into the new version.
 
Ha-ha. I've updated 8.0 -> 8.4, installed pkg and run pkg2ng:
Code:
15:59 [temp] pkg ~> pkg2ng
/libexec/ld-elf.so.1: /usr/local/lib/liblzma.so.5: version XZ_5.0 required by /usr/lib/libarchive.so.5 not defined
Analysing shared libraries, this will take a while...
/libexec/ld-elf.so.1: /usr/local/lib/liblzma.so.5: version XZ_5.0 required by /usr/lib/libarchive.so.5 not defined
DING! [temp] pkg ~>
16:00 [temp] pkg ~> portupgrade xz-5.0.3
/libexec/ld-elf.so.1: Shared object "libcrypt.so.4" not found, required by "ruby18"
And now there is no xz in ports at all....

Is there a way to fix this or should I move to 9.3 and then update ports?
 
8.4 is not supported anymore so it's only expected that there might be unresolvable problems using ports and pkg(8) on it. Upgrade to 9.3 first.
 
Hmm.. I've deleted /lib/libcrypt.so.4 (with yes | make delete-old-libs), I've moved it back and the second problem is gone. But the first one still exists and I don't understand why.
Code:
/libexec/ld-elf.so.1: /usr/local/lib/liblzma.so.5: version XZ_5.0 required by /usr/lib/libarchive.so.5 not define
 
Back
Top