Error ssl_engine_init.c: 546: Error: 'stack' undeclared (first use in this function)

Source: Internet
Author: User
Tags openssl version

Operating System: centos6.4 x86_64

Apache version: httpd-2.2.6

OpenSSL version: openssl-1.0.1e


The following error is reported when compiling Apache with source code:

Authorization: In function 'ssl _ init_ctx_protocol ': ssl_engine_init.c: 390: Warning: Assignment discards qualifiers from pointer target audience: 396: Warning: Assignment discards qualifiers from pointer target audience: in function 'ssl _ init_ctx_verify ': ssl_engine_init.c: 546: Error: 'stack' undeclared (first use in this function) restart: 546: Error: (each undeclared identifier is reported only accept: 546: Error: for each function it appears in .) failed: 546: Error: Expected expression before ') 'failed: In function 'ssl _ init_findcalist': ssl_engine_init.c: 1126: Warning: pointer type mismatch in conditional expressionmake [4]: * [ssl_engine_init.slo] Error 1 make [4]: Leaving directory '/software/httpd-2.2.6/modules/SSL' make [3]: * [Shared-Build-recursive] Error 1 make [3]: Leaving directory '/software/httpd-2.2.6/modules/SSL' make [2]: * [Shared-Build-recursive] Error 1 make [2]: Leaving directory '/software/httpd-2.2.6/modules' make [1]: * [Shared-Build-recursive] Error 1 make [1]: Leaving directory '/software/httpd-2.2.6' Make: *** [All-recursive] Error 1


Cause Analysis: caused by incompatibility between apache2.x and openssl1.0.x

Solution: Install openssl0.9.8e

Installation steps:

# tar zxvf openssl-0.9.8e.tar.gz# cd openssl-0.9.8e# ./config shared zlib# make # make test# make install# mv /usr/bin/openssl /usr/bin/openssl.OFF# mv /usr/include/openssl /usr/include/openssl.OFF# rm -rf /usr/lib/libssl.so# ln -s /usr/local/ssl/bin/openssl /usr/bin/openssl# ln -s /usr/local/ssl/include/openssl /usr/include/openssl# ln -sv /usr/local/ssl/lib/libssl.so.0.9.8  /usr/lib/libssl.so


 

Configure the library file search path

# echo "/usr/local/ssl/lib" >> /etc/ld.so.conf# ldconfig -v


 

Check installation result

# openssl version


OpenSSL 0.9.8e 23 Feb 2007


Installed successfully!


Recompile Apache and add -- enable-SSL -- With-SSL =/usr/local/SSL


Solve the problem.


This article is from the "Bing Lincheng" blog, please be sure to keep this source http://308107405.blog.51cto.com/6396647/1537541

Related Article

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.