Dynamic library for openssl-1.0.1c cross-Compilation

Source: Internet
Author: User

# Cross-compiling OpenSSL ------
Modify makefile directly
Add this line:
Cross_compile = arm-unknown-Linux-gnueabi-
Go to the following lines
Cc = cc to CC = $ (cross_compile) GCC
Go to the following lines
AR = ar $ (arflags) r
Ranlib =/usr/bin/ranlib
Change
AR = $ (cross_compile) Ar $ (arflags) r
Ranlib = $ (cross_compile) ranlib
Modify the installation path and locate the following two lines:
Installtop =/usr/local/SSL
Openssldir =/usr/local/SSL
Changed to the actual installation path. Because it is not running on the local machine, you can specify any location
Installtop =/someplace/OpenSSL

Openssldir =/someplace/OpenSSL

The focus is here !!!

The above sections are all changed based on online materials. static libraries can be generated after testing, but the changes to the dynamic libraries generated are different from those mentioned on the Internet. After practice, you need to modify the following parts:

Execute the following script for Initial Configuration:
./Config no-ASM shared -- prefix =/home/rebi/cross_tools/build_openssl-1.0.1c/_ install
Final Conclusion: first execute the above config, then manually modify the generated makefile, and find the location with-M64, delete all (2 in total)
Then modify the generated makefile.
First, add the line:
Cross_compile = arm-unknown-Linux-gnueabi-
Go to the following lines
Cc = cc to CC = $ (cross_compile) GCC
Locate the following rows (--- these two rows should not be changed ---)
AR = ar $ (arflags) r
Ranlib =/usr/bin/ranlib
Change
AR = $ (cross_compile) Ar $ (arflags) r
Ranlib = $ (cross_compile) ranlib

After the above configuration, you can generate both static and dynamic libraries.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.