Opened 8 years ago

Closed 8 years ago

#7311 closed defect (fixed)

nmake scripts missing platform dependencies for openssl

Reported by: ultramage Owned by:
Priority: Medium Milestone: Tor: 0.2.4.x-final
Component: Core Tor/Tor Version:
Severity: Keywords: msvc tor-client build
Cc: Actual Points:
Parent ID: #7754 Points:
Reviewer: Sponsor:

Description

All nmake scripts that link to openssl (all of them) are reporting missing platform dependencies. At least for openssl 1.0.1c, the following are also required:

  • crypt32.lib <- openssl's e_capi.c ms crypto functions
  • gdi32.lib <- openssl's readscreen(), seeds RNG with screen bitmap
  • user32.lib <- openssl's isservice() check and showfatal() MessageBox

Maybe openssl added these features since the makefiles were first added?

Child Tickets

Change History (7)

comment:1 Changed 8 years ago by nickm

Keywords: tor-client build added
Milestone: Tor: 0.2.4.x-final

comment:2 Changed 8 years ago by nickm

Parent ID: #7754

comment:3 Changed 8 years ago by ultramage

Slight clarification. This issue occurs when using a static openssl library build. The alternative is to use the shared dll library build, which already has the abovementioned dependencies included. Still, there is no harm including them, since the linker will just skip them when it finds no used references.

Currently the expert bundle is built in an all-static mode, while the browser bundle uses the dll approach. In this case the static version would be the preferred one, since there is no sharing going on anyway, and it's a good idea to avoid introducing the dlls in situations where they might end up in PATH or colliding with another version.

comment:4 Changed 8 years ago by nickm

Status: newneeds_review

This is in the 024_msvc branch, I *think*.

comment:5 Changed 8 years ago by nickm

Resolution: fixed
Status: needs_reviewclosed

Merged a fix for this into master as of b998431a33db2b.

comment:6 Changed 8 years ago by ultramage

Resolution: fixed
Status: closedreopened

I believe this was the one thing that was left out. My fix to satisfy static openssl's dependencies was

- ws2_32.lib advapi32.lib shell32.lib
+ ws2_32.lib advapi32.lib shell32.lib crypt32.lib gdi32.lib user32.lib

(applies to Makefile.nmake in or/ test/ and tools/)

comment:7 Changed 8 years ago by nickm

Resolution: fixed
Status: reopenedclosed

Applied as 2386a98d461bfbd8bbe0f5a17402841599c769e5 ; thanks!

Note: See TracTickets for help on using tickets.