Compiling OpenSSL on Linux
来源:互联网 发布:网络链路测试工具 编辑:程序博客网 时间:2024/05/16 10:12
OpenSSL is a replacement for SSLeay secure socket layer.
This document reflects my real-world experience in building OpenSSL 0.9.4 (~1.6M) on a Slackware 4.0 Linux 2.2.10 box. A new version appears to come out every two or three months.
Obtaining OpenSSL
OpenSSL Tarball page at http://www.openssl.org/source/ will show you a list of mirror sites you can obtain the latest from. Again, these instructions pertain to just the openssl-0.9.4.tar.gz version.
Untaring
To untar the file, execute tar zxvf openssl-0.9.4.tar.gz. This will produce a subdirectory called openssl-0.9.4 with everything you need inside.
Installation instructions are convienently in a file called INSTALL, this file can be viewed with less INSTALL.
Configuring
Change into the openssl-0.9.4 directory with:
$ cd openssl-0.9.4
Start the configuration process to identify your platform and its capabilities:
$ ./config
To build the software, simply make it:
$ make
...the compile process will take a while to complete...
Test the build to make sure it worked:
$ make test
Now the big step, installing. You'll need to be root in order to do this next phase:
# make install
You'll find your new software is now located in /usr/local/ssl, be sure to check out the bin and include subdirectories. See the INSTALL and README files that explain how you need to specify #include in your source since the include files moved to a subdirectory.
This page last updated
2 Get openssl directory installed and version info
# which openssl
/usr/bin/openssl
# /usr/bin/openssl version
OpenSSL 0.9.4 14 Mar 2012
3 Cross platform compile x86 Android version Openssl on Ubuntu
1>下载NDK Linux版本并解压缩
2> 设置工具链
./android-ndk-r10/build/tools/make-standalone-toolchain.sh--platform=android-19 --install-dir=/tmp/my-android-toolchain --arch=x86
export PATH=/tmp/my-android-toolchain/bin:$PATH
export CC=i686-linux-android-gcc
export CXX=i686-linux-android-g++
3> 切换到openssl根目录,配置
./config
./Configure os/compiler:android-x86
这里是target是x86 Android,所以选了flag android-x86。但是似乎选择任意flag都可以,选择这个flag主要是为了将Makefile中的与当前 host机器相关的编译选项去掉,然后能顺利编译。
4> make
http://mobilepearls.com/labs/native-android-api/ndk/docs/STANDALONE-TOOLCHAIN.html
- Compiling OpenSSL on Linux
- openssl compile on linux
- Compiling OpenSSL with MinGW
- Summary of OPENSSL compiling
- Compiling PHP and Apache 2 from source on Linux OS
- Compiling TBB programs and examples on Linux Ubuntu
- Compiling Erlang on Ubuntu
- Compiling Erlang on Ubuntu
- ccny_vision compiling on ros-fuerte
- Compiling GCC on OS X
- HOWTO: Cross-compiling a 32-bit (i386) Linux kernel on 64-bit Machine (amd64)
- Compiling and installing Hadoop 2.4 on 64-bit Oracle Linux 6
- Linux Kernel Compiling Documents
- Linux kernel compiling problem!
- Cross-Compiling Under Linux
- compiling-linux-kernel-module
- Disable compiling GTK2 for tshark on solaris10
- GCC: Compiling an OpenCL host on Windows
- windows进程间通信
- 游戏后台的快速开发
- jquery插件——仿新浪微博限制输入字数的textarea
- Android开发之wifi
- 八.2 time
- Compiling OpenSSL on Linux
- CSS Hack
- Hiero工具的利用
- Velocity经常要用到的一些方法
- Android adb中命令的运行
- 【C++再学习】【05】有关类的一些知识点整理
- PostgreSQL服务启动时报错:“FATAL: could not create lock file "/tmp/.s.PGSQL.5432.lock": Permission denied”
- C++ 构造函数和析构函数的调用顺序、虚析构函数的作用
- 开发记录