LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 832|回复: 8

ln -s $LFS/stage1 /

[复制链接]
发表于 2003-7-7 13:52:54 | 显示全部楼层 |阅读模式
Linux From Scratch: 版本 20030603   章 5. 准备 LFS 系统

下面这个命令是什么意思,是把$LFS/stage1看做是根目录吗?
ln -s $LFS/stage1 /

那么后面的这个命令我不知该如何解释了,
../binutils-2.13.2/configure \
    --prefix=/stage1 --disable-nls
是这样理解的吗?实际安装在$LFS/stage1/stage1           可这样理解肯定是错的
那位来指点一下我啊!
 楼主| 发表于 2003-7-7 14:11:38 | 显示全部楼层

help me

各位在线的给点帮助吧
发表于 2003-7-7 16:06:15 | 显示全部楼层
ln -s $LFS/stage1 /
表示创建符号链接,/stage1->/mnt/lfs/stage1
真正的目录是/mnt/lfs/stage1,而/stage1只是一个链接。创建这个链接是为了让你在主系统里和chroot环境中看到的都是/stage1。
 楼主| 发表于 2003-7-7 18:57:19 | 显示全部楼层

谢了,我试试看
 楼主| 发表于 2003-7-7 23:21:44 | 显示全部楼层
可以写成
ln -s $LFS/stage1 /stage1
 楼主| 发表于 2003-7-7 23:22:32 | 显示全部楼层
吗?
发表于 2003-7-8 00:00:03 | 显示全部楼层
说实话,还真没注意到,原来这两个有一点点区别的。
   `ln' makes links between files.  By default, it makes hard links;
with the `-s' option, it makes symbolic (or "soft") links.  Synopses:
                                                                                                      
     ln [OPTION]... TARGET [LINKNAME]
     ln [OPTION]... TARGET... DIRECTORY
                                                                                                      
   * If the last argument names an existing directory, `ln' creates a
     link to each TARGET file in that directory, using the TARGETs'
     names.  (But see the description of the `--no-dereference' option
     below.)
                                                                                                      
   * If two filenames are given, `ln' creates a link from the second to
     the first.
你用ls -l /
看一下这两个的区别,最后面多一个“/”
 楼主| 发表于 2003-7-9 14:37:05 | 显示全部楼层

chinese

先谢了,可以给个中文的吗?
 楼主| 发表于 2003-7-9 14:38:04 | 显示全部楼层
我决定开始装lfs了因为觉得好无聊
您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表