LINUX RTAI中.runinfo文件详解(英文)
Description of the "runinfo" format
-----------------------------------
Purpose of the "runinfo" files
------------------------------
"runinfo" files found in the source tree allow the "rtai-load" script
(see rtai-core/scripts/rtai-load) to retrieve the information it needs
to execute a RTAI application in an automated manner. This file
basically describes the module dependencies (i.e from standard RTAI
system modules) and the load/startup actions (i.e. insmoding module(s)
and/or launching executable(s)) that need to be taken to start a given
application.
This mecanism replaces the various hand-crafted "run" shell scripts
that existed up to RTAI's 24.1.12 (stromboli) version.
Format of a runinfo file
------------------------
All examples and tests contain/should contain an ASCII file called
runinfo that provides the needed information for having the
corresponding RTAI applications run through the "rtai-load"
script. This file is actually a template read by Autoconf's
"configure" script, where installation-dependent information is
automatically patched in, to produce the corresponding ".runinfo"
file. The "rtai-load" script will exclusively use .runinfo files to
find out the actions needed to bootstrap an application.
runinfo should list all possible execution targets for the given
example/test directory.
Each execution target appears on a single text line, contains four
specification fields separated by double-colons, and is parsed as:
target_name:module_dependencies:run_actions:init_comment
Therefore, having multiple targets in a single file is possible, like
this:
target_name1:module_dependencies_1:run_actions_1:init_comment_1
target_name2:module_dependencies_2:run_actions_2:init_comment_2
...
and so on.
o target_name is a symbolic name. The first line seen in a given file
stands for the default target.
o module_dependencies is a list defining the standard RTAI modules the
test/example depends on, and which must be loaded bef
相关文档:
1. Linux 脚本编写基础
1.1 语法基本介绍
1.1.1 开头
程序必须以下面的行开始(必须方在文件的第一行):
#!/bin/sh
符号#!用来告诉系统它后面的参数是用来执行该文件的程序。在这个例子中我们使用/bin/sh来执行程序。
当编辑好脚本时,如果要执行该脚本,还必须使其可执行。
要使脚本可执行:
编译 chmod +x ......
#include <unistd.h>
int daemon(int nochdir,int noclose)
在创建精灵进程的时候,往往需要将精灵进程的工作目录修改为"/"根目录
并且将标准输入,输出和错误输出重定向到/dev/null
daemon的作用就是当参数nochdir为0时,将根目录修改为工作目录
noclose为0时,做输入,输出以及错误输出重定向到/dev/null
执 ......
Linux 安装中文包
首先,安装中文包:
#yum groupinstall chinese-support
其次,修改一下字符编码的配置。
# vi /etc/sysconfig/i18n
修改后内容如下:
LANG="zh_CN.GB18030"
SUPPORTED="zh_CN.UTF-8:zh_CN:zh:en_US.UTF-8:en_US:en:zh_CN.GB18030"
SYSFONT="latarcyrheb-sun16"
最后重启服 ......
本文网址:http://bbs.bitscn.com/72875 复制
1. Linux 脚本编写基础
1.1 语法基本介绍
1.1.1 开头
程序必须以下面的行开始(必须放在文件的第一行):
#!/bin/sh
符号#!用来告诉系统它后面的参数是用来执行 ......