From owner-freebsd-questions@FreeBSD.ORG Sun Aug 19 23:42:51 2012 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 05810106564A for ; Sun, 19 Aug 2012 23:42:51 +0000 (UTC) (envelope-from freebsd-questions@m.gmane.org) Received: from plane.gmane.org (plane.gmane.org [80.91.229.3]) by mx1.freebsd.org (Postfix) with ESMTP id B3C328FC18 for ; Sun, 19 Aug 2012 23:42:50 +0000 (UTC) Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1T3F8q-0007BF-18 for freebsd-questions@freebsd.org; Mon, 20 Aug 2012 01:42:48 +0200 Received: from pool-173-79-96-198.washdc.fios.verizon.net ([173.79.96.198]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 20 Aug 2012 01:42:48 +0200 Received: from nightrecon by pool-173-79-96-198.washdc.fios.verizon.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 20 Aug 2012 01:42:48 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-questions@freebsd.org From: Michael Powell Date: Sun, 19 Aug 2012 19:43:14 -0400 Lines: 60 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7Bit X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: pool-173-79-96-198.washdc.fios.verizon.net Subject: Re: Issue with kernel building X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: nightrecon@hotmail.com List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 19 Aug 2012 23:42:51 -0000 antonin tessier wrote: > > Hi, > > I have a problem when I try to build my own kernel. I had never got such a > one; here is my kernel configuration file and the building errors that it > makes. > [snip] > > "# make kernel KERNCONF=GOLLUM > > MAKE=make sh /usr/src/sys/conf/newvers.sh GOLLUM > > Stop in /usr/obj/usr/src/sys/GOLLUM. " I have snipped out content for brevity; rather let's focus on evidence of incorrect procedure on your part. While there still exists 2 ways of accomplishing this, the so-called "new" method is standard. An example of how to do this can be found contained within a commented out section in the beginning of /usr/src/Makefile. While this information is on how to completely rebuild/update the entire system from source, the commands to build and install a new kernel are present. Please note the following: make buildkernel KERNCONF=somekernelfilename make installkernel KERNCONF=somekernelfilename You are on almost the right track but you are referencing above incorrect paths to this kernel config process. For an i386 box/install your kernel config file would be located in /usr/src/sys/i386/conf and for a 64-bit amd64 install this location is /usr/src/sys/amd64/conf. The best way to begin with customising a kernel is to simply copy the GENERIC config you will find in the conf directory mentioned (whichever is your box - i386 or amd64) to something like, for example, GOLLUM. Then cd to /usr/src and perform the above described commands. Hints: Prior to attempting to rebuild again cd to /usr/obj and delete anything under /usr/obj. There will exist here content left over from the previous failed attempt. Keep in mind whenever you install a new kernel your present kernel (and its matching modules) get moved to kernel.old. What this means is that the GENERIC you have with a base install will be moved to kernel.old and can be used in the event the new kernel won't boot. Realize this: after the next rebuild process this kernel.old will be replaced _again_. In which case you might now have 2 broken kernels with not an easy way to recover. This is just some generic stuff to try and get you back on track. I would recommend an extended reading of the Handbook, as all of these instructions are present there. Hope this halps. :-) -Mike