📄 buildmin-3.html
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"><HTML><HEAD> <META NAME="GENERATOR" CONTENT="SGML-Tools 1.0.9"> <TITLE>How To Build a Minimal Linux System from Source Code: MAKEDEV</TITLE> <LINK HREF="buildMin-4.html" REL=next> <LINK HREF="buildMin-2.html" REL=previous> <LINK HREF="buildMin.html#toc3" REL=contents></HEAD><BODY><A HREF="buildMin-4.html">Next</A><A HREF="buildMin-2.html">Previous</A><A HREF="buildMin.html#toc3">Contents</A><HR><H2><A NAME="s3">3. MAKEDEV</A></H2><P>We will put the source code in the target <CODE>/usr/src</CODE> directory. So for example, if your target file system is mounted on <CODE>/mnt/target</CODE>and your tarballs are in <CODE>/root</CODE>, you would do<P><PRE> cd /mnt/target/usr/src tar -xzvf /root/MAKEDEV-2.5.tar.gz</PRE><P><P>Don't be completely lame and copy the tarball to the place where you are goingto extract it ;-><P><P>Normally when you install software, you are installing it onto the systemthat is running. We don't want to do that though, we want to install itas though <CODE>/mnt/target</CODE> is the root filesystem. Different packageshave different ways of letting you do this. For MAKEDEV you do<P><PRE> ROOT=/mnt/target make install</PRE><P><P>You need to look out for these options in the README and INSTALL filesor by doing a <CODE>./configure --help</CODE>.<P><P>Have a look in MAKEDEV's <CODE>Makefile</CODE> to see what it does with the<CODE>ROOT</CODE> varible that we set in that command. Then have a lookin the man page by doing <CODE>man ./MAKEDEV.man</CODE> to see how it works. You'll find that the way to make our device files is to<CODE>cd /mnt/target/dev</CODE> and do <CODE>./MAKEDEV generic</CODE>.Do an <CODE>ls</CODE> to see all the wonderful device files it has madefor you.<P><HR><A HREF="buildMin-4.html">Next</A><A HREF="buildMin-2.html">Previous</A><A HREF="buildMin.html#toc3">Contents</A></BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -