mtrojnar / osslsigncode

OpenSSL based Authenticode signing for PE/MSI/Java CAB files
Other
801 stars 131 forks source link

cannot find the libcurl with the latest build #179

Closed chenrui333 closed 1 year ago

chenrui333 commented 2 years ago

Another issue that I found with the latest release build is osslsigncode cannot find libcurl installation, which requires some linker patch.

The error log is as below

/opt/homebrew/Library/Homebrew/shims/mac/super/clang -O3 -DNDEBUG -arch arm64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX12.sdk -Wl,-search_paths_first -Wl,-headerpad_max_install_names -fstack-protector-all -fstack-check CMakeFiles/osslsigncode.dir/osslsigncode.c.o CMakeFiles/osslsigncode.dir/msi.c.o -o osslsigncode  /opt/homebrew/opt/openssl@3/lib/libssl.dylib /opt/homebrew/opt/openssl@3/lib/libcrypto.dylib 
Undefined symbols for architecture arm64:
  "_curl_easy_cleanup", referenced from:
      _add_timestamp in osslsigncode.c.o
  "_curl_easy_getinfo", referenced from:
      _add_timestamp in osslsigncode.c.o
  "_curl_easy_init", referenced from:
      _add_timestamp in osslsigncode.c.o
  "_curl_easy_perform", referenced from:
      _add_timestamp in osslsigncode.c.o
  "_curl_easy_setopt", referenced from:
      _add_timestamp in osslsigncode.c.o
  "_curl_easy_strerror", referenced from:
      _add_timestamp in osslsigncode.c.o
  "_curl_slist_append", referenced from:
      _add_timestamp in osslsigncode.c.o
  "_curl_slist_free_all", referenced from:
      _add_timestamp in osslsigncode.c.o
  "_curl_version", referenced from:
      _main in osslsigncode.c.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
mtrojnar commented 2 years ago

My guess: https://github.com/jeroen/curl/issues/71#issuecomment-235971309 It does compile cleanly on our CI: https://github.com/mtrojnar/osslsigncode/runs/7812972051?check_suite_focus=true

chenrui333 commented 2 years ago

My guess: jeroen/curl#71 (comment)

that indeed looks like a similar issue.

It does compile cleanly on our CI: https://github.com/mtrojnar/osslsigncode/runs/7812972051?check_suite_focus=true

yeah, I was aware of that.

mtrojnar commented 1 year ago

I don't think there is anything I can do here to fix your build environment.