curl 7.61.1 vs2017 dynamic library build(MD/MDd) ( with DLL OpenSSL )

in #curl6 years ago (edited)

:: 이 내용은 아래의 구성의 빌드에만 유효하다.

  1. DLL Debug - DLL OpenSSL
  2. DLL Release - DLL OpenSSL

  1. folder 구조

  2. 3rdparty 라이브러리 셋팅
    2-1. openssl (https://www.npcglib.org/~stathis/blog/precompiled-openssl/)

    • openssl-1.1.0f는 아직 curl 빌드에 연동되어 있지 않기 때문에 기존 1.0.2l 버전을 사용한다.
      : 참고 : 1.1.0f로 바뀌면서 기존 libeay32 => libcrypto, ssleay32 =>libssl로 명칭이 변경되었다.
    • openssl-1.0.2l-vs2017.7z 다운로드 후 압축 해제
    • bin 폴더에 precompiled 된 바이너리 존재 확인 ( libeay32MD.dll, libeay32MDd.dll, ssleay32MD.dll, ssleay32MDd.dll )
    • lib 폴더에 precompiled 된 바이너리들 확인 (libeay32MDd.lib, ssleay32MDd.lib, libeay32MD.lib, ssleay32MD.lib)
    • 아래 내용 수행
      root/openssl/build/win32/vc15/LIB Debug 에 libeay32MDd.lib, ssleay32MDd.lib를 복사해서 넣는다.
      root/openssl/build/win32/vc15/LIB Release 에 libeay32MD.lib, ssleay32MD.lib를 복사해서 넣는다.
    • include/openssl폴더 통체로 root/inc32/openssl에 붙여 넣기 한다.
  3. curl 셋팅
    3-1. download (https://curl.haxx.se/download.html)

    • 'Windows 32bit 7.61.1 binary the curl project' download
    • root/curl-7.61.1 에 압축 풀어준다.
    • root/curl-7.61.1/projects/Windows/VC15/curl-all.sln 로 솔루션을 연다.

    3-2. libcurl 빌드만 성공하고 curl 빌드가 필요 없다면 아래 구성 내용 수정 할 필요가 없다.

    • curl 프로젝트 => 속성
      DLL Debug - DLL OpenSSL 구성 선택 => 링커 => 입력 에 libeay32.lib 를 libeay32MDd.lib, ssleay32.lib를 ssleay32MDd.lib 로 각각 수정한다.
      DLL Release - DLL OpenSSL 구성 선택 => 링커 => 입력 에 libeay32.lib 를 libeay32MD.lib, ssleay32.lib를 ssleay32MD.lib 로 각각 수정한다.
  4. build

    • 각 구성 별로 아래와 같이 파일이 출력된다.
    • DLL Debug - DLL OpenSSL : root/curl-7.61.1/build/Win32/VC15/DLL Debug - DLL OpenSSL/libcurld.lib, libcurld.dll, curl.exe
      : curl.exe를 실행하라면 같은 폴더에 다음 파일이 필요 ( llibeay32MDd.dll, ssleay32MTd.dll )
    • DLL Release - DLL OpenSSL : root/curl-7.61.1/build/Win32/VC15/DLL Release - DLL OpenSSL/libcurl.lib, libcurl.dll curl.exe
      : curl.exe를 실행하라면 같은 폴더에 다음 파일이 필요 ( llibeay32MD.dll, ssleay32MT.dll )
  5. 프로젝트에 적용 (참고 curl_test_dynamic 프로젝트)

    • include : root/curl-7.61.1/include/curl 폴더 사용
    • lib
      • debug : libcurld.lib, libcurld.dll, llibeay32MDd.dll, ssleay32MTd.dll 사용
      • release : libcurl.lib, libcurl.dll, libeay32MD.dll, ssleay32MD.dll 사용
Sort:  

Congratulations @thickeyes! You received a personal award!

Happy Birthday! - You are on the Steem blockchain for 1 year!

You can view your badges on your Steem Board and compare to others on the Steem Ranking

Vote for @Steemitboard as a witness to get one more award and increased upvotes!

Coin Marketplace

STEEM 0.18
TRX 0.14
JST 0.030
BTC 58668.45
ETH 3162.85
USDT 1.00
SBD 2.44