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

c疑惑留言

你说是写个动态库不就行了,还说写脚本,脚本跟动态库差别大去了
gcc编译的时候就能生成动态连接库
windows下面没有so的概念,windows叫dll
搜下Linux gcc 动态库
编写好c语言程序,就是file系统调用的几个函数,fopen,fread之类的
gcc编译成so文件,一个命令就搞定,我忘记具体的选项了


相关文档:

PHP调用C编程总结(windows)

一.环境的安装
   
    下载安装包,Google上搜索php+apache+sql的安装包并安装。
二.扩展编程
    针对在PHP环境下掉用C编程(c程序编译的dll),主要有以下两种方式。
   
    1.利用ATL构建DLL组件,然后再PHP里面直接调用,调用方法 ......

c/c++读写文件

#include<stdlib.h>
#include<iostream>
#include<string.h>
using namespace std;
int main(void)
{
FILE *fp, *fp2;
char buf[1024*300];
fp = fopen("in.txt", "rb");
fp2 = fopen("out.txt", "wb+");
fseek(fp, 0, SEEK_END);
int iLen ......

C 字符串函数大全

函数名: stpcpy
功 能: 拷贝一个字符串到另一个
用 法: char *stpcpy(char *destin, char *source);
程序例:
#include <stdio.h>
#include <string.h>
int main(void)
{
   char string[10];
   char *str1 = "abcdefghi";
   stpcpy(string, str1);
 & ......

用php的c扩展编程调用 c程序的动态链接库


一.    首先做一个简单的so文件:
    /**
     * hello.c
     * To compile, use following commands:
     *   gcc -O -c -fPIC -o hello.o hello.c
     *   gcc -shared ......

lua和c的交互


extern "C" {
#include "lua.h"
#include "lualib.h"
#include "lauxlib.h"
}
 
#include <iostream>
#include <string>
using namespace std;
    
int main()
{
    //Lua示例代 ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号