Chinaunix首页 | 论坛 | 博客
  • 博客访问: 108878
  • 博文数量: 35
  • 博客积分: 0
  • 博客等级: 民兵
  • 技术积分: 287
  • 用 户 组: 普通用户
  • 注册时间: 2015-08-01 19:56
文章分类
文章存档

2017年(6)

2016年(21)

2015年(8)

我的朋友

分类: LINUX

2015-12-20 17:39:11

ubuntu中man的手册安装。用下面几条命令就行了:

  sudo apt-get install manpages 
  sudo apt-get install manpages-de 
  sudo apt-get install manpages-de-dev 
  sudo apt-get install manpages-dev
manpages 包含 GNU/Linux 的基本操作
manpages-dev 包含 GNU/Linux 的基本操作API
manpages-posix 包含 POSIX 所定义公用程序的方法
manpages-posix-dev 包含 POSIX 的 header files 和 library calls 的用法

Linux man中的man就是manual的缩写,用来查看系统中自带的各种参考手册,但是手册页分为好几个部分,如下所示:(注:手册页,很重要的,一般我们也都没有用上,不过有时候,你就会发现你用上了)

1   Executable programs or shell commands

2   System calls (functions provided by the kernel)

3   Library calls (functions within program libraries)

4   Special files (usually found in /dev)

5   File formats and conventions eg /etc/passwd

6   Games

7   Miscellaneous (including macro packages and conventions), e.g. man(7), groff(7)

8   System administration commands (usually only for root)

9   Kernel routines [Non standard]

----------------------

解释一下,

1是普通的命令

2是系统调用,如open,write之类的(通过这个,至少可以很方便的查到调用这个函数,需要加什么头文件)

3是库函数,如printf,fread

4是特殊文件,也就是/dev下的各种设备文件

5是指文件的格式,比如passwd, 就会说明这个文件中各个字段的含义

6是给游戏留的,由各个游戏自己定义

7是附件还有一些变量,比如向environ这种全局变量在这里就有说明

8是系统管理用的命令,这些命令只能由root使用,如ifconfig

所以想查系统命令一般是man 1。系统调用man 2,c标准函数man 3。。。等等


阅读(3419) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~