apt-get make openvpn

来源:互联网 发布:python vscode 编辑:程序博客网 时间:2024/06/05 04:58

获得指定版本 apt-get install name=version 例如automake=1.8


软件的配置文件全部安装在etc这个文件夹里面,执行程序可能按照在/usr下面, 日志文件又会在/var/log下面,都不一样的!

生成 Makefile 的来龙去脉

首先进入 project 目录,在该目录下运行一系列命令,创建和修改几个文件,就可以生成符合该平台的Makefile文件,操作过程如下:

1) 运行autoscan命令

2) 将configure.scan 文件重命名为configure.in,并修改configure.in文件

3) 在project目录下新建Makefile.am文件,并在core和shell目录下也新建makefile.am文件

4) 在project目录下新建NEWS、 README、 ChangeLog 、AUTHORS文件

5) 将/usr/share/automake-1.X/目录下的depcomp和complie文件拷贝到本目录下

6) 运行aclocal命令

7) 运行autoconf命令

8) 运行automake -a命令

9) 运行./confiugre脚本


在Linux下安装一个应用程序时,一般先运行脚本configure,然后用make来编译源程序,在运行make install,最后运行make clean删除一些临时文件。使用上述三个自动工具,就可以生成configure脚本。运行configure脚本,就可以生成Makefile文件,然后就可以运行make、make install和make clean。clean有时候很用 编译出错的情况下 要用 make test 有时候也用  记得看 install文件 会说怎么用


安装openvpn (转载自http://www.linuxdiyf.com/viewarticle.php?id=107527)


OpenVPN依赖OpenSSL库,用于加密,需要安装。LZO库,数据压缩用,不使用该库也没有关系。

OpenSSL的下载地址:http://www.openssl.org/

LZO的下载地址:http://www.oberhumer.com/opensource/lzo/

OpenVPN的下载地址:http://www.openvpn.net

1、./configure --with-lzo-headers=/usr/local/include --with-lzo-lib=/usr/local/lib --with-ssl-headers=/usr/local/ssl/include/ --with-ssl-lib=/usr/local/ssl/lib/

如果不带--with-ssl-headers的话,就会出现下面的错误

QUOTE:configure: checking for OpenSSL Crypto Library and Header files...
checking openssl/evp.h usability... no
checking openssl/evp.h presence... no
checking for openssl/evp.h... no
configure: error: OpenSSL Crypto headers not found

如果不带 --with-ssl-lib=/usr/local/ssl/lib/,则出现的错误是
QUOTE:configure: checking for OpenSSL Crypto Library and Header files...
checking openssl/evp.h usability... yes
checking openssl/evp.h presence... yes
checking for openssl/evp.h... yes
checking for EVP_CIPHER_CTX_init in -lcrypto... no
configure: error: OpenSSL Crypto library not found.

make ;make install