scons - a software construction tool

简介:

Netkiller Developer 手札

November 15, 2008

MrNeo Chan陈景峰

 


中国广东省深圳市宝安区龙华镇
518109
+86 755 29812080
+86 755 29812080

 

 

文档最近一次更新于 Wed Feb 1 08:42:08 UTC 2012

 

版权 © 2008, 2009, 2010, 2011, 2012 Netkiller(Neo Chan). All rights reserved.

版权声明

转载请与作者联系,转载时请务必标明文章原始出处和作者信息及本声明。

文档出处:
http://netkiller.sourceforge.net
http://netkiller.github.com

 

Tue Dec 6 17:22:53 CST 2011

 

2. scons - a software construction tool

http://www.scons.org/

创建一个hello.c测试文件

		
#include<stdio.h>

main()
{
    printf("Hello World!\n");
}
		
		

创建SConstruct文件(相当于Makefile)

$ cat SConstruct
Program('hello.c')
		

开始编译

$ scons
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
gcc -o hello.o -c hello.c
gcc -o hello hello.o
scons: done building targets.
		

编译后产生的文件,尝试运行hello程序

$ ls
hello  hello.c  hello.o  SConstruct

$ ./hello 
Hello World!
		

下面操作想当于 make clean

$ scons -c
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Cleaning targets ...
Removed hello.o
Removed hello
scons: done cleaning targets.

$ ls
hello.c  SConstruct 		
		
目录
相关文章
|
机器人 Python 数据格式
Robot Framework's built-in tool:libdoc
Libdoc是Robot框架的内置工具之一,用于生成HTML和XML格式的测试库和资源文件的关键字文档,使用起来我感觉非常的灵活方便。 General Usage 语法使用 python -m robot.
1326 0
|
Shell Perl 网络安全