logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Building & Member Downloads View previous topic :: View next topic
Reply to topic   Topic: Cmake Apache compialtion mos_so Error
Author
Anitha



Joined: 25 Sep 2016
Posts: 34
Location: india

PostPosted: Sat 27 Jun '20 22:09    Post subject: Cmake Apache compialtion mos_so Error Reply with quote

Hello Team,

During apache 2.4.43 compilation thru cmake i have got and error in building mod_md.so. As i have commented the following from cmakelist and proceed the compilation . Will it create any problem ?.

Commented : "modules/md/mod_md+i+Apache Managed Domains (Certificates)"

Error:
[ 67%] Linking C shared library mod_md.so
LINK Pass 1: command "C:\PROGRA~2\MICROS~1.0\VC\bin\link.exe /nologo
.
.
ir/manifest.res" failed (exit code 1120) with the following output:
Creating library mod_md.lib and object mod_md.exp
md_curl.c.obj : error LNK2019: unresolved external symbol __imp__curl_global_ini
t referenced in function _md_curl_init
.
.

Thanks,
Anitha.S
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7288
Location: Germany, Next to Hamburg

PostPosted: Tue 30 Jun '20 22:52    Post subject: Reply with quote

Hi Anitha,
do you have the required curl source in the path?
Back to top
Anitha



Joined: 25 Sep 2016
Posts: 34
Location: india

PostPosted: Thu 02 Jul '20 11:19    Post subject: Reply with quote

Hi James,

curl i have already compile using commandline

nmake -f Makefile.vc mode=dll WITH_SSL=dll WITH_ZLIB=static mode=static debug=no machine=x86

And i received the libcurl_imp.lib file that does not resolve the imp errors. As per reference i have included Windows SDK libraries.

#pragma comment(lib, "wldap32.lib")
#pragma comment(lib, "ws2_32.lib")
#pragma comment(lib, "winmm.lib")

Even its not fixed and same issue persist. Even i have set the SDK path in command problem before compile but nothing helps Sad.

Thanks,
Anitha.S
Back to top
tangent
Moderator


Joined: 16 Aug 2020
Posts: 305
Location: UK

PostPosted: Mon 17 Aug '20 18:49    Post subject: Reply with quote

Hi Anitha,

A couple of things to try.

Looking at your 'nmake' command, you've specified two mode options, 'mode=dll' and 'mode=static'.

When I build curl (using CMake to create "NMake Makefiles"), I have to build it twice; once to create the shared library support files (libcurl.dll and libcurl_imp.lib) and once to build the static library (libcurl.lib). If I specify both dynamic and static libraries at the same time, it doesn't seem to create the static library file. Maybe having both options together might mess up the import libary file too.

Also, regarding import library file, make sure you are building a recent release of curl, e.g. 7.71.1
Back to top
Jan-E



Joined: 09 Mar 2012
Posts: 1248
Location: Amsterdam, NL, EU

PostPosted: Wed 19 Aug '20 1:26    Post subject: Reply with quote

As an alternative to building curl yourself, you could also download the compiled version that the PHP-devs use:
https://windows.php.net/downloads/php-sdk/deps/vs16/x86/ (for a VS16 x86 build of Apache).

The sources and sample nmake commands can be found here:
https://github.com/winlibs/cURL

Cmake should be able to find the libcurl.lib and the curl include files. If everything is correct Cmake reports
CURL_FOUND ............... :
and
Curl include directory........... :
Back to top


Reply to topic   Topic: Cmake Apache compialtion mos_so Error View previous topic :: View next topic
Post new topic   Forum Index -> Building & Member Downloads