Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 3 Oct 2014 11:54:36 +0100
From:      TonyMc <afmcc@btinternet.com>
To:        freebsd-questions@freebsd.org
Subject:   Re: pkg upgrade question ....
Message-ID:  <20141003115436.70a5446a@elena.home>
In-Reply-To: <542D601F.1030104@hiwaay.net>
References:  <542D601F.1030104@hiwaay.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 02 Oct 2014 09:24:31 -0500
"William A. Mahaffey III" <wam@hiwaay.net> wrote:

> 
> 
> .... I converted from using linux-f10 to using linux-c6 for linux 
> compatibility earlier this week. There were no linux-c6 pkg's, so I
> used ports to do that install, & I also 'pkg delete'-ed all of
> linux-f10 in the process. I just did a 'pkg upgrade -y' & it deleted
> all of the installed linux-c6 stuff & reinstalled linux-f10 !!!! I
> would like to believe this was pilot error, but that is getting to be
> a bit of a stretch .... I can & will manually clean up the mess, but
> WTF is going on here w/ pkg ? That behavior is 100% counter-intuitive
> to me, bug ?
> 
> 

Dear William,

this was indeed pilot error.  You should get into the habit of
reading /usr/ports/UPDATING.  The relevant entry states (22 Sep.): "The
complete drop-in replacement linux-c6 port infrastructure is in ports
and will shortly replace the current linux-f10- ports as default."
The "will shortly" is key there.  The ports system makes software
available for you to compile and install. You can start using linux-c6
ports before they become the default, but you must understand that that
is your decision, and by doing so you are departing from "the default".
If you then try to "pkg upgrade" pkg will install the most recently
available packages for the ports you have installed.  Since there are
no linux-c6 packages available yet (though presumably it will not be
long), pkg resolved your software dependencies on linux emulation using
linux-f10 packages, which were available.  If you had waited until
linux-c6 became the default, you would have been fine.

I have read a number of your messages over the last few weeks and it
seems to me you still have a problem grasping the relationship between
ports and packages.  (I hope I have not misunderstood you.)  You need
to understand that ports are recipes for configuring, building and
installing software (usually involving compilation, linking and
installation), while packages are recipes for adding
already-configured-and-built software to your system.  The "already"
part of that description means that someone, somewhere has to have done
the configuration, compilation and linking steps.  That takes a finite
time.  When multiplied by the number of available ports (more than
20,000) you can see why the availability of packages lags behind the
availability of the recipes in the ports tree.

I hope that helps.  I suggest you choose between ports and
packages (there are exceptions for some programs, for which you really
need non-default options).  If you prefer to use the newest version as
soon as it becomes available, and you can live with the work of choosing
configuration options, building and installing, you need to use ports.
But if you can wait a few days and accept the default options, pkg
upgrade will make your life a lot easier.

Just as an aside: you seem very keen to use linux emulation on
FreeBSD.  Why is that?  What are you missing that requires the
compatibility layer?

Best,
Tony
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20141003115436.70a5446a>