# portupgrade fails with makefile fatal error



## mikie46 (Jan 30, 2013)

FreeBSD la1008.myhostlogin.com 6.2-RELEASE-p6 FreeBSD 6.2-RELEASE-p6 #2:

I upgraded from ports then tried to upgrade perl.

When *I* ran the following *I* received a make file error. Been searching for hours but nothing has fixed it. Problem is, the upgrade to perl 5.10 was successful but trying to reinstall everything that depends on perl kicks the following error:

`portupgrade -fr perl`


```
# > portupgrade -fr perl
** Makefile possibly broken: archivers/p5-Archive-Tar:
        "Makefile", line 29: Malformed conditional (${PORT_OPTIONS:MTEXTDIFF})
        "Makefile", line 31: if-less endif
        make: fatal errors encountered -- cannot continue
/usr/local/sbin/portupgrade:1473:in `get_pkgname': Makefile broken (MakefileBrokenError)
        from /usr/local/sbin/portupgrade:617:in `main'
        from /usr/local/sbin/portupgrade:608:in `each'
        from /usr/local/sbin/portupgrade:608:in `main'
        from /usr/local/sbin/portupgrade:582:in `catch'
        from /usr/local/sbin/portupgrade:582:in `main'
        from /usr/local/lib/ruby/1.8/optparse.rb:1310:in `call'
        from /usr/local/lib/ruby/1.8/optparse.rb:1310:in `parse_in_order'
        from /usr/local/lib/ruby/1.8/optparse.rb:1306:in `catch'
        from /usr/local/lib/ruby/1.8/optparse.rb:1306:in `parse_in_order'
        from /usr/local/lib/ruby/1.8/optparse.rb:1254:in `catch'
        from /usr/local/lib/ruby/1.8/optparse.rb:1254:in `parse_in_order'
        from /usr/local/lib/ruby/1.8/optparse.rb:1248:in `order!'
        from /usr/local/lib/ruby/1.8/optparse.rb:1241:in `order'
        from /usr/local/sbin/portupgrade:559:in `main'
        from /usr/local/lib/ruby/1.8/optparse.rb:791:in `initialize'
        from /usr/local/sbin/portupgrade:231:in `new'
        from /usr/local/sbin/portupgrade:231:in `main'
        from /usr/local/sbin/portupgrade:2219
```

The Makefile looks like this

```
# --< optimizations :: BEGIN >-------------------------------------------------
CPUTYPE=opteron

# added by use.perl 2013-01-30 11:51:17
PERL_VERSION=5.10.1
```
Can*'*t upgrade portupgrade or any other package.

How can *I* fix the Makefile? Any ideas would be great.

Help!


----------



## mikie46 (Jan 31, 2013)

Does anyone know? Im getting desperate here.


----------



## wblock@ (Jan 31, 2013)

I think the ports system has had changes that are not backwards compatible with very old and no-longer-supported FreeBSD revisions.


----------



## cpm@ (Jan 31, 2013)

You should upgrade to a supported release, FreeBSD 6.2 was dropped since May 31, 2008 (EoL). Read about FreeBSD Security Information.


----------



## mikie46 (Jan 31, 2013)

Thats correct but sorry i dont have time right this minute to upgrade. I would however like to know how to get make working again.


----------



## wblock@ (Jan 31, 2013)

make(1) is working, it is the ports tree that has changed.  I don't know if there is a way to make it work on 6.2, but you could ask on the freebsd-ports mailing list, or on IRC: #bsdports on EFnet.


----------



## mikie46 (Jan 31, 2013)

Buy the port tree for 6.2 is still out there. As of recently everything was still working just fine.


----------



## cpm@ (Jan 31, 2013)

mikie46 said:
			
		

> FreeBSD la1008.myhostlogin.com 6.2-RELEASE-p6 FreeBSD 6.2-RELEASE-p6 #2:
> 
> I upgraded from ports then tried to upgrade perl.
> 
> ...



Try to update archivers/p5-Archive-Tar manually:

`# cd /usr/ports/archivers/p5-Archive-Tar && make deinstall clean && make install clean`

To upgrade Perl using portupgrade(1), do as following:

```
# pkgdb -Ff
# portupgrade -o lang/perl5.12 -f perl-5.10\*
# portupgrade -fr perl
```

Update all Perl related stuff:

`# portupgrade -f p5*`

Finally, run perl-after-upgrade -f to tell the system about the new version and update all packages necessary. See perl-after-upgrade(1) for full details.


----------



## wblock@ (Jan 31, 2013)

mikie46 said:
			
		

> Buy the port tree for 6.2 is still out there. As of recently everything was still working just fine.



There is only one ports tree.  It is the same for all versions of FreeBSD.  At some point, old versions of the operating system miss enough features to not be able to use it any more.  There may be a temporary fix for the problem, but the permanent fix is to upgrade to a supported version of FreeBSD.


----------

