Hitchhiker's Guide to Openbsd
partition the source tree is on will often give significantly better performance
Download 1.27 Mb. Pdf ko'rish
|
obsd-faq49
partition the source tree is on will often give significantly better performance. 5.3.4 - Building the kernel We will assume you wish to build a standard (GENERIC or GENERIC.MP) kernel here. Normally, this is what you want to do. Do not consider building a custom kernel if you have not mastered the standard building process. Obviously, the kernel is a VERY hardware dependent portion of the system. The source for the kernel is in the /usr/src/sys directory. Some parts of the OpenBSD kernel code are used on all platforms, others are very specific to one processor or one architecture. If you look in the /usr/src/sys/ arch/ directory, you may see some things that look a little confusing -- for example, there are mac68k , m68k and mvme68k directories. In this case, the mvme68k and mac68k systems both use the same processor, but the machines they are based on are very different, and thus require a very different kernel (there is much more to a computer's design than its processor!). However, parts of the kernel are common, those parts are kept in the m68k directory. If you are simply building a kernel, the base architecture directories like m68k are not anything for you to worry about, you will be working exclusively with the "compound architecture" directories, such as mvme68k . Kernels are built based on kernel configuration files , which are located in the /usr/src/sys/arch/ <your platform>/conf directory. Building the kernel consists of using the config(8) program to create and populate a kernel compile directory, which will end up in /usr/src/sys/arch/<your platform>/compile/<KernelName> . For this example, we will assume you are using the i386 platform: # cd /usr/src/sys/arch/i386/conf # config GENERIC # cd ../compile/GENERIC # make clean && make depend && make [...lots of output...] # make install Replace " i386 " in the first line with your platform name. The machine(1) command can tell you what your platform name is, so an obvious generalization would be to use the command " cd /usr/src/ sys/arch/`machine`/conf " instead on the first line. At this point, reboot your machine to activate this new kernel. Note that the new kernel should be running before the next step, though if you have followed the above advice about upgrading to the most recent available snapshot, it may not matter as much. Sometimes, however, APIs change, and the old http://www.openbsd.org/faq/faq5.html (10 of 26)9/4/2011 10:02:02 AM 5 - Building the System from Source kernel will be unable to run new applications, but the new kernel will generally support the old ones. Note that you can build a kernel without root access, but you must have root to install the kernel. Download 1.27 Mb. Do'stlaringiz bilan baham: |
Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2025
ma'muriyatiga murojaat qiling
ma'muriyatiga murojaat qiling