<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">Index: chap-kernel.xml
===================================================================
RCS file: /cvsroot/htdocs/guide/en/chap-kernel.xml,v
retrieving revision 1.9
diff -b -u -r1.9 chap-kernel.xml
--- chap-kernel.xml	20 May 2004 03:09:14 -0000	1.9
+++ chap-kernel.xml	14 Aug 2004 15:06:46 -0000
@@ -42,131 +42,35 @@
     &lt;title&gt;Installing the kernel sources&lt;/title&gt;
 
     &lt;sidebar&gt;
-      &lt;para&gt;You can get the kernel sources from AnonCVS, see
-        &lt;xref linkend="chap-cvs" /&gt;.&lt;/para&gt;
+      &lt;para&gt;
+	You can get the kernel sources from AnonCVS (see
+        &lt;xref linkend="chap-cvs" /&gt;), or from the 
+	&lt;filename&gt;syssrc.tgz&lt;/filename&gt;
+	tarball that is located in the &lt;filename&gt;source/sets/&lt;/filename&gt; 
+	directory of the release that you are using. If you use the second
+	method, you can extract the tarball as root: 
+      &lt;/para&gt;
     &lt;/sidebar&gt;
 
-    &lt;para&gt;Be patient: this operation lasts many minutes, because the repository
-      contains hundreds of files.
-      The sources live in &lt;filename&gt;/usr/src/sys&lt;/filename&gt;; the
-      symbolic link &lt;filename&gt;sys&lt;/filename&gt; points to this directory.
-      Therefore the following commands have the same effect:&lt;/para&gt;
+    &lt;screen&gt;
+&amp;rprompt; &lt;userinput&gt;cd /&lt;/userinput&gt;
+&amp;rprompt; &lt;userinput&gt;tar zxf /path/to/syssrc.tgz&lt;/userinput&gt;
+    &lt;/screen&gt;
 
-    &lt;screen&gt;&amp;rprompt; &lt;userinput&gt;cd /usr/src/sys&lt;/userinput&gt;
-&amp;rprompt; &lt;userinput&gt;cd /sys&lt;/userinput&gt;&lt;/screen&gt;
+    &lt;para&gt;
+      If you chose to use AnonCVS, be patient, the operation can last
+      many minutes, because the repository contains hundreds of files.
+    &lt;/para&gt;
 
-    &lt;para&gt;Once the sources are checked out, you can create a custom kernel: this
-      is not as difficult as you think.
+    &lt;para&gt;
+      Once you have the sources available, you can create a custom kernel: 
+      this is not as difficult as you might think.
       In fact, a new kernel can be created in a few steps
       which will be described in the following sections.&lt;/para&gt;
   &lt;/sect1&gt;
 
   &lt;!-- ============================================================= --&gt;
 
-  &lt;sect1 id="chap-kernel-italian-keyboard"&gt;
-    &lt;title&gt;Italian keyboard layout&lt;/title&gt;
-
-    &lt;para&gt;Before compiling the kernel, Italian users should consider modifying
-      the predefined layout for the italian keyboard, which is defined in the
-      source file &lt;filename&gt;/sys/dev/pckbc/wskbdmap_mfii.c&lt;/filename&gt;.
-      In the default layout some characters useful for programmers are
-      missing (for example, left and right braces and tilde).
-      This is an alternative layout:&lt;/para&gt;
-
-    &lt;programlisting&gt;static const keysym_t pckbd_keydesc_it[] = {
-...
-KC(8),   KS_7,          KS_slash,       KS_braceleft,
-KC(9),   KS_8,          KS_parenleft,   KS_bracketleft,
-KC(10),  KS_9,          KS_parenright,  KS_bracketright,
-KC(11),  KS_0,          KS_equal,       KS_braceright,
-KC(12),  KS_apostrophe, KS_question,    KS_grave,
-KC(13),  KS_igrave,     KS_asciicircum, KS_asciitilde,
-KC(26),  KS_egrave,     KS_eacute,      KS_bracketleft, KS_braceleft,
-KC(27),  KS_plus,       KS_asterisk,    KS_bracketright,KS_braceright,
-...&lt;/programlisting&gt;
-
-    &lt;para&gt;The previous layout defines the following mappings:&lt;/para&gt;
-
-    &lt;informaltable&gt;
-      &lt;tgroup cols="2"&gt;
-	&lt;colspec align="center" colwidth="1.5in" /&gt;
-	&lt;colspec align="center" colwidth="1.5in" /&gt;
-
-	&lt;thead&gt;
-	  &lt;row&gt;
-	    &lt;entry&gt;Keys&lt;/entry&gt;
-	    &lt;entry&gt;Character&lt;/entry&gt;
-	  &lt;/row&gt;
-	&lt;/thead&gt;
-
-	&lt;tbody&gt;
-	  &lt;row&gt;
-	    &lt;entry&gt;Alt Gr + 7&lt;/entry&gt;
-	    &lt;entry&gt;{&lt;/entry&gt;
-	  &lt;/row&gt;
-
-	  &lt;row&gt;
-	    &lt;entry&gt;Alt Gr + 8&lt;/entry&gt;
-	    &lt;entry&gt;[&lt;/entry&gt;
-	  &lt;/row&gt;
-
-	  &lt;row&gt;
-	    &lt;entry&gt;Alt Gr + 9&lt;/entry&gt;
-	    &lt;entry&gt;]&lt;/entry&gt;
-	  &lt;/row&gt;
-
-	  &lt;row&gt;
-	    &lt;entry&gt;Alt Gr + 0&lt;/entry&gt;
-	    &lt;entry&gt;}&lt;/entry&gt;
-	  &lt;/row&gt;
-
-	  &lt;row&gt;
-	    &lt;entry&gt;Alt Gr + '&lt;/entry&gt;
-	    &lt;entry&gt;`&lt;/entry&gt;
-	  &lt;/row&gt;
-
-	  &lt;row&gt;
-	    &lt;entry&gt;Alt Gr + &amp;igrave;&lt;/entry&gt;
-	    &lt;entry&gt;~&lt;/entry&gt;
-	  &lt;/row&gt;
-
-	  &lt;row&gt;
-	    &lt;entry&gt;Alt Gr + &amp;eacute;&lt;/entry&gt;
-	    &lt;entry&gt;[&lt;/entry&gt;
-	  &lt;/row&gt;
-
-	  &lt;row&gt;
-	    &lt;entry&gt;Alt Gr + +&lt;/entry&gt;
-	    &lt;entry&gt;]&lt;/entry&gt;
-	  &lt;/row&gt;
-
-	  &lt;row&gt;
-	    &lt;entry&gt;Shift + Alt Gr + &amp;egrave;&lt;/entry&gt;
-	    &lt;entry&gt;{&lt;/entry&gt;
-	  &lt;/row&gt;
-
-	  &lt;row&gt;
-	    &lt;entry&gt;Shift + Alt Gr + +&lt;/entry&gt;
-	    &lt;entry&gt;}&lt;/entry&gt;
-	  &lt;/row&gt;
-	&lt;/tbody&gt;
-      &lt;/tgroup&gt;
-    &lt;/informaltable&gt;
-
-    &lt;note&gt;
-      &lt;title&gt;Console driver&lt;/title&gt;
-
-      &lt;para&gt;starting with version 1.4, &amp;os; uses the
-        &lt;application&gt;wscons&lt;/application&gt; multiplatform console driver to
-        handle screen, keyboard and mouse.
-        Previous versions used &lt;application&gt;pccons&lt;/application&gt; or
-        &lt;application&gt;pcvt&lt;/application&gt;.
-        For a detailed description, see &lt;xref linkend="chap-cons" /&gt;.&lt;/para&gt;
-    &lt;/note&gt;
-  &lt;/sect1&gt;
-
-  &lt;!-- ============================================================= --&gt;
-
   &lt;sect1 id="chap-kernel-recompiling-kernel"&gt;
     &lt;title&gt;Recompiling the kernel&lt;/title&gt;
 
@@ -187,10 +91,6 @@
       &lt;title&gt;Basic steps for kernel compilation&lt;/title&gt;
 
       &lt;step&gt;
-        &lt;para&gt;Build the toolchain&lt;/para&gt;
-      &lt;/step&gt;
-
-      &lt;step&gt;
         &lt;para&gt;Create/modify the kernel configuration file&lt;/para&gt;
       &lt;/step&gt;
 
@@ -214,23 +114,6 @@
 
   &lt;!-- ============================================================= --&gt;
 
-  &lt;sect1 id="chap-kernel-build-toolchain"&gt;
-    &lt;title&gt;Build the toolchain&lt;/title&gt;
-
-    &lt;para&gt;The &amp;os; toolchain provides a simple mechanism for compiling
-      the &amp;os; system both natively or when the need arises, cross
-      compiling for other targets. In this example, a native toolchain
-      is built (as &lt;username&gt;root&lt;/username&gt;) by simply typing:&lt;/para&gt;
-
-    &lt;screen&gt;&amp;rprompt; &lt;userinput&gt;cd /usr/src&lt;/userinput&gt;
-&amp;rprompt;  &lt;userinput&gt;./build.sh tools&lt;/userinput&gt;&lt;/screen&gt;
-
-    &lt;para&gt;Once the tools are built, the kernel can be reconfigured
-      and compiled.&lt;/para&gt;
-  &lt;/sect1&gt;
-
-  &lt;!-- ============================================================= --&gt;
-
   &lt;sect1 id="chap-kernel-creating-kernel-configfile"&gt;
     &lt;title&gt;Creating the kernel configuration file&lt;/title&gt;
 
@@ -244,14 +127,14 @@
       characteristics of the devices supported by the kernel as well as
       several kernel configuration options.
       Kernel configuration files are located in the
-      &lt;filename&gt;/sys/arch/i386/conf&lt;/filename&gt; directory.
+      &lt;filename&gt;/usr/sys/arch/i386/conf&lt;/filename&gt; directory.
       The easiest way to create a new file is to copy an existing one
       and modify it: usually the best choice on most platforms is the
       GENERIC configuration.
       In the configuration file there are comments describing the options; a
       more detailed description is found in the &amp;man.options.4; man page.&lt;/para&gt;
 
-    &lt;screen&gt;&amp;rprompt; &lt;userinput&gt;cd /sys/arch/i386/conf/&lt;/userinput&gt;
+    &lt;screen&gt;&amp;rprompt; &lt;userinput&gt;cd /usr/src/sys/arch/i386/conf/&lt;/userinput&gt;
 &amp;rprompt; &lt;userinput&gt;cp GENERIC &lt;replaceable&gt;MYKERNEL&lt;/replaceable&gt;&lt;/userinput&gt;
 &amp;rprompt; &lt;userinput&gt;vi &lt;replaceable&gt;MYKERNEL&lt;/replaceable&gt;&lt;/userinput&gt;&lt;/screen&gt;
 
@@ -313,31 +196,32 @@
 ...
 options PCKBD_LAYOUT="KB_IT"&lt;/programlisting&gt;
 
-    &lt;para&gt;The &lt;filename&gt;adjustkernel&lt;/filename&gt; Perl script, which can be
-      found at &lt;ulink url="http://www.feyrer.de/Misc/adjustkernel"&gt;&lt;/ulink&gt;,
-      analizes the output of &amp;man.dmesg.8; and
+    &lt;para&gt;
+      The &lt;command&gt;adjustkernel&lt;/command&gt; Perl script, which is
+      available through pkgsrc analyzes the output of &amp;man.dmesg.8; and
       automatically generates a minimal configuration file.
-      To run it you need to have Perl installed on your system.
-      The installation of new software is described in detail
-      in the &lt;xref linkend="chap-pack" /&gt;.
-      If you want to install Perl now, download the pre-compiled package
-      &lt;filename&gt;perl-5.00404.tgz&lt;/filename&gt; and write the following command:&lt;/para&gt;
-
-    &lt;screen&gt;&amp;rprompt; &lt;userinput&gt;pkg_add perl-5.00404.tgz&lt;/userinput&gt;&lt;/screen&gt;
+      The installation of packages is described extensively in 
+      in the &lt;xref linkend="chap-pack" /&gt;, but installing
+      &lt;command&gt;adjustkernel&lt;/command&gt; basically boils down to:
+    &lt;/para&gt;
 
-    &lt;para&gt;Now Perl is installed, configured and ready to work: easier than this
-      it's impossible...&lt;/para&gt;
+    &lt;screen&gt;
+&amp;rprompt; &lt;userinput&gt;cd /usr/pkgsrc/sysutils/adjustkernel&lt;/userinput&gt;
+&amp;rprompt; &lt;userinput&gt;make install&lt;/userinput
+    &lt;/screen&gt;
 
     &lt;para&gt;You can now run the script with:&lt;/para&gt;
 
     &lt;screen&gt;&amp;rprompt; &lt;userinput&gt;cd /sys/arch/i386/conf&lt;/userinput&gt;
-&amp;rprompt; &lt;userinput&gt;perl adjustkernel GENERIC &gt; &lt;replaceable&gt;MYKERNEL&lt;/replaceable&gt;&lt;/userinput&gt;&lt;/screen&gt;
+&amp;rprompt; &lt;userinput&gt;adjustkernel GENERIC &gt; &lt;replaceable&gt;MYKERNEL&lt;/replaceable&gt;&lt;/userinput&gt;
+    &lt;/screen&gt;
 
-    &lt;para&gt;I tried this script and it worked very well, saving me a lot of manual
+    &lt;para&gt;
+      This script usually works very well, saving a lot of manual
       editing.
-      Beware that the script only configures the available devices: you
-      must still configure manually the other options (e.g. Linux emulation,
-      ...)&lt;/para&gt;
+      But be aware that the script only configures the available devices: you
+      must still configure the other options manually.
+    &lt;/para&gt;
   &lt;/sect1&gt;
 
   &lt;!-- ============================================================= --&gt;
@@ -376,53 +260,10 @@
       chips): the compilation puts a higher stress on the system than most
       applications do.
       Another typical error is the following: option B, active, requires
-      option A which is not active.&lt;/para&gt;
-
-    &lt;para&gt;A full compilation of the kernel can last from some minutes to several
+      option A which is not active.
+      A full compilation of the kernel can last from some minutes to several
       hours, depending on the hardware.
-      See the following table for some examples:&lt;/para&gt;
-
-    &lt;informaltable&gt;
-      &lt;tgroup cols="3"&gt;
-	&lt;colspec colwidth="1.5in" /&gt;
-	&lt;colspec colwidth="1in" /&gt;
-	&lt;colspec colwidth="1.5in" /&gt;
-
-	&lt;thead&gt;
-	  &lt;row&gt;
-	    &lt;entry&gt;CPU&lt;/entry&gt;
-	    &lt;entry&gt;RAM (MB)&lt;/entry&gt;
-	    &lt;entry&gt;Approx. time&lt;/entry&gt;
-	  &lt;/row&gt;
-	&lt;/thead&gt;
-
-	&lt;tbody&gt;
-	  &lt;row&gt;
-	    &lt;entry&gt;486 DX2 50&lt;/entry&gt;
-	    &lt;entry&gt;20&lt;/entry&gt;
-	    &lt;entry&gt;1 hour&lt;/entry&gt;
-	  &lt;/row&gt;
-
-	  &lt;row&gt;
-	    &lt;entry&gt;P166&lt;/entry&gt;
-	    &lt;entry&gt;96&lt;/entry&gt;
-	    &lt;entry&gt;15 minutes&lt;/entry&gt;
-	  &lt;/row&gt;
-
-	  &lt;row&gt;
-	    &lt;entry&gt;PIII&lt;/entry&gt;
-	    &lt;entry&gt;128&lt;/entry&gt;
-	    &lt;entry&gt;5 minutes&lt;/entry&gt;
-	  &lt;/row&gt;
-
-	  &lt;row&gt;
-	    &lt;entry&gt;68030/25&lt;/entry&gt;
-	    &lt;entry&gt;8&lt;/entry&gt;
-	    &lt;entry&gt;4 hours&lt;/entry&gt;
-	  &lt;/row&gt;
-	&lt;/tbody&gt;
-      &lt;/tgroup&gt;
-    &lt;/informaltable&gt;
+    &lt;/para&gt;
 
     &lt;para&gt;The output of the make command is the &lt;filename&gt;netbsd&lt;/filename&gt; file
       in the compile directory: this file should be copied in the root
</pre></body></html>