# Upgrade of emacs and xorgs fails becuase of older installation of perl



## apb15 (Mar 4, 2012)

I recently upgraded to release 9.0. I used portmanager to upgrade most of my ports after fetching the latest ports using portsnap. I could not however upgrade xorg and emacs. So I tried removing these leaf packages and reinstalling them using pkg_add. However I get the following error message:

```
pkg_add: package 'perl5.12.4_3' conflicts with perl-5.10.1_7
Please use -f to force installation or pkg_delete to remove conflicting package.
```

When I ran `pkg_info -rR perl-5.10.1_7` I noticed I have a lot of packages that depend on perl-5.10.1_7.

Is this expected behavior and besides using the -f option is there any other way to fix it?


----------



## wblock@ (Mar 4, 2012)

After upgrading major versions (FreeBSD 8.x -> 9.x), *all* ports must be rebuilt.  Or reinstalled, if you use packages.  Packages will expect your system to have the same packages as the remote machine they were built on.


----------



## apb15 (Mar 4, 2012)

I have used a combination of packages and ports. What is the easiest way for me to upgrade all the packages that depend on perl-5-10 to now use perl-5-12?


----------



## wblock@ (Mar 4, 2012)

Rebuild them all, and since you've upgraded, rebuilding everything is needed anyway.  There's a procedure at the end of the ports-mgmt/portmaster man page for doing that.  Or delete everything and reinstall all the needed packages, but I don't know of a similar documented process for that.


----------

