Skip to content
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

Download OpenSSL from Conan #5

Open
annulen opened this issue Sep 16, 2020 · 2 comments
Open

Download OpenSSL from Conan #5

annulen opened this issue Sep 16, 2020 · 2 comments
Assignees

Comments

@annulen
Copy link
Member

annulen commented Sep 16, 2020

Right now we download OpenSSL with qt-downloader, and it turned out to have 2 major issues:

  • MSVC binaries are built with VS2010 (!) and require its runtime which is not preinstalled on Win10
  • MinGW is shipped with OpenSSL 1.0.2 which is incompatible with Qt
    Also, qt.io doesn't update OpenSSL often (though our use case is not security-sensitive)

Alternative is to use Conan package. For example, to download OpenSSL built with VS2019 x86_64 following command can be used:

conan install 'openssl/[>=1.1.1g <3.0]@' -g deploy -o openssl:shared=True -s compiler="Visual Studio" -s os=Windows -s arch=x86_64 -s compiler.version=16

It creates openssl directory which contains necessary dlls in bin. Same can be used for x86. MinGW won't work out of the box so let's start from MSVC x86 and x86_64.

@annulen
Copy link
Member Author

annulen commented Sep 16, 2020

Now we have mingw too. Run

conan remote add qtproject https://api.bintray.com/conan/qtproject/conan --insert --force

and then one of the following commands:

# VS2019 x86
conan install 'openssl/[>=1.1.1g <3.0]@qtproject/stable' -g deploy -o openssl:shared=True -s compiler="Visual Studio" -s os=Windows -s arch=x86 -s compiler.version=16
# VS2019 x86_64
conan install 'openssl/[>=1.1.1g <3.0]@qtproject/stable' -g deploy -o openssl:shared=True -s compiler="Visual Studio" -s os=Windows -s arch=x86_64 -s compiler.version=16
# MinGW x86
conan install 'openssl/[>=1.1.1g <3.0]@qtproject/stable' -g deploy -o openssl:shared=True -s compiler=gcc -s os=Windows -s arch=x86 -s compiler.version=8 -s compiler.libcxx=libstdc++ -s compiler.exception=dwarf2 -s compiler.threads=posix
# MinGW x86_64
conan install 'openssl/[>=1.1.1g <3.0]@qtproject/stable' -g deploy -o openssl:shared=True -s compiler=gcc -s os=Windows -s arch=x86_64 -s compiler.version=8 -s compiler.libcxx=libstdc++ -s compiler.exception=seh -s compiler.threads=posix

to download one of packages.

@annulen
Copy link
Member Author

annulen commented Sep 16, 2020

I think we need a script "download-openssl" which gets following arguments: compiler (mingw/msvc), version (16 or 8 in this case), arch, output dir (goes to --install-folder of conan)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants