易截截图软件、单文件、免安装、纯绿色、仅160KB

Linux GCC make文件的写法1

所需文件hello.c, main.c, hello.h, Makefile,在同一个目录下
hello.c:
#include <stdio.h>
void hello(char name[])
{
printf("Hello %s!\n", name);
}

main.c:
#include "stdio.h"
#include "hello.h"
// The second
int main()
{
hello("GCC");
printf("Haha Linux Ubuntu!\n");
return 0;
}

hello.h:
void hello(char name[]);

Makefile(之所以用大写,因为make可以识别Makefile和makefile,用大写可以鲜明一些):
# String declaration
objects = main.o hello.o
# Command
app : $(objects)
cc -o app main.o hello.o
main.o : main.c hello.h
cc -c main.c
hello.o : hello.c stdio.h
cc -c hello.c
# Search paths
vpath %.h /usr/include
# Clean the intermediate files
.PHONY : clean
clean :
rm app $(objects)


相关文档:

linux内核移植s3c2410,移植正式开始1

在前面的准备工作完成之后,先实验一下,谈不上真正的移植 ,因为代码都没有改的。
首先修改顶层的Makefile,修改ARCH,CROSS_COMPLIE变量。
#ARCH        ?= $(SUBARCH)
ARCH        ?= arm
CROSS_COMPILE    ?= arm-linux-
执行make smd ......

Linux驱动的一些基本操作

Linux驱动的一些基本操作

Linux内核中定义了很多宏,对硬件端口和寄存器进行操作,从网上搜集了一些宏定义的信息:
1. __REG简单的说就是获得后面所示物理地址映射后的虚拟地址,例如:
#define GPLR0  __REG(0x40E00000)    /* GPIO Pin-Level Register GPIO<31:0> */
#define GPL ......

虚拟机上SourceInsight访问Linux系统的代码


首先在Linux系统上安装samba
然后启动Windows虚拟机,在资源管理器中将samba的地址(例如//192.168.1.10/share)映射为一个虚拟盘符Z
最后启动SourceInsight,在Z盘上建立工程,并导入文件。
注意:以后每次使用SourceInsight之前先要连接samba服务器,比如说打开盘符Z。 ......

J2EE项目迁移(window >linux)

1. download & setup jdk
2. download eclipse and test a simple example of java
3. setup mysql use yum(or download & setup by hand)
 yum install mysql
 problem1:linux mysql configuration & use
  solution1:
   mysql -uroot -p
   passw ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号