Skip to content

Commit

Permalink
Use Deimos OpenSSL instead of our own bindings
Browse files Browse the repository at this point in the history
Remove a bit of duplication and allow users depending on this library
to use a more familiar way to configure the version of OpenSSL they
are using.
  • Loading branch information
Geod24 committed Oct 2, 2023
1 parent 8efbcae commit b4cc447
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 829 deletions.
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
[submodule "makd"]
path = submodules/makd
url = https://github.com/sociomantic-tsunami/makd.git
[submodule "openssl"]
path = submodules/openssl
url = https://github.com/D-Programming-Deimos/openssl.git
4 changes: 2 additions & 2 deletions Build.mak
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ TEST_RUNNER_MODULE := ocean.core.UnitTestRunner
export ASSERT_ON_STOMPING_PREVENTION=1

# Common D compiler flags
override DFLAGS += -w -version=GLIBC
override DFLAGS += -I$C/submodules/openssl/source/ -w -version=GLIBC

# Treat deprecations as errors to ensure ocean doesn't use own deprecated
# symbols internally. Disable it on explicit flag to make possible regression
Expand All @@ -18,7 +18,7 @@ endif

# Enables https://github.com/sociomantic-tsunami/ocean/blob/v6.x.x/src/ocean/net/ssl/openssl/OpenSsl.d#L529
ifeq ($(OPENSSL_V3),1)
override DFLAGS += -version=Ocean_OpenSSL3
override DFLAGS += -version=DeimosOpenSSL_3_0
endif

# Remove coverage files
Expand Down
1 change: 1 addition & 0 deletions dub.sdl
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ authors "Sociomantic Labs GmbH and Tango contributors"
homepage "https://github.com/sociomantic-tsunami/ocean"
license "BSD 3-clause or check Ocean license"
copyright "Copyright (c) 2004 dunnhumby Germany GmbH and Tango contributors. All rights reserved."
dependency "openssl" version="~>3.3"
systemDependencies "Depending on the component used you might need one of the following libraries (check the used modules for details): -lglib-2.0 -lpcre -lxml2 -lxslt -lreadline -lhistory -llzo2 -lbz2 -lz -ldl -lgcrypt -lgpg-error -lrt -lebtree (version from https://github.com/sociomantic-tsunami/ebtree)"
importPaths "src"
targetType "sourceLibrary"
Expand Down
4 changes: 3 additions & 1 deletion src/ocean/net/ssl/SslClientConnection.d
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,10 @@

module ocean.net.ssl.SslClientConnection;

import deimos.openssl.err;
import deimos.openssl.ssl;

import ocean.meta.types.Qualifiers;
import ocean.net.ssl.openssl.OpenSsl;
import ocean.text.util.StringC;


Expand Down
Loading

0 comments on commit b4cc447

Please sign in to comment.