Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 24 Oct 2013 01:36:25 +1030
From:      Shane Ambler <FreeBSD@ShaneWare.Biz>
To:        freebsd@dreamchaser.org,  FreeBSD Mailing List <freebsd-questions@freebsd.org>
Subject:   Re: headers in /usr/include are 9.1 but /usr/src/sys are 9.0
Message-ID:  <5267E5F1.7030202@ShaneWare.Biz>
In-Reply-To: <52673D72.9080606@dreamchaser.org>
References:  <52673D72.9080606@dreamchaser.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On 23/10/2013 13:37, Gary Aitken wrote:
> Using the generic kernel. Some time ago I upgraded from 9.0 to 9.1
> using freebsd-update.
> 
> originally, under 9.0, I had lsof installed (from ports).
> 
> Some time after all that I tried to reinstall sysutils/lsof and
> couldn't. I wasn't desperate and ignored it...
> 
> Looking into it further, the problem appears to be the result of
> /usr/src/sys/sys/ containing 9.0.0 versions, and /usr/include/sys/
> containing 9.1.0 versions.
> 
> I didn't think I had system source installed, but apparently I did. I
> have vague recollections of telling the upgrade process not to
> upgrade the source because I didn't think I had it installed; but
> maybe it doesn't even ask.  I'm not really familiar with the process
> and it was a while back.
> 
> Anyhow...
> 
> 1. Is /usr/src/sys/sys always present?

No. The system source files are optional.

> 2. Do ports normally use headers from /usr/src/sys/sys instead of 
> /usr/include/sys if /usr/src/sys/sys is present?

As I understand it the ports that would use /usr/src are ones that
compile kernel modules. lsof would be an exception as I believe it
accesses data structures from the running system to collect it's
information, which are defined in the system sources. lsof should be
compiled against the current system and complains when it isn't.

> 3. What's the best way to fix this? freebsd-update fetch?

freebsd-update is configured in /etc/freebsd-update.conf you should find
an entry for Components which should contain src then update.

Another option if you have subversion installed is to checkout the
source tree straight from the svn servers.



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