New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
static compilation issue with openssl #6741
Comments
Why, you ask, do I need static compilation? This is for a cross platform desktop app, in anticipation of upcoming windows support. |
for the lazy: this is the Dockerfile:
|
disregard -- I forgot we already figured this out (#6288 (comment)). For some reason this issue persists unless you add the build flags: TLDR: |
Duplicate of #6288 |
A blocker for me right now is the fact that crystal programs that
require "openssl"
do not seem to statically compile on any of the community-managed static compilation docker images. I have set up a repo that reproduces this by running the "./build_static" bash script in the root of the project. Perhaps there are some additional dev packages that need to be included on alpine? Would highly appreciate it if someone weighs in on this. Currently this is pushing me to develop my program in rust instead, since it's openssl library compiles perfectly without any dependencies on linux + osx + windows.repo: https://github.com/sam0x17/crystal_static_compilation
static compilation docker image: https://hub.docker.com/r/durosoft/crystal-alpine/
crystal program:
static compilation result:
update: using this link flag fixes it by forcing libcrypto to be included before libz:
--link-flags "-lcrypto -lz"
The text was updated successfully, but these errors were encountered: