summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libcrypto/libcrypto/buildfile156
-rw-r--r--libcrypto/manifest2
-rw-r--r--libssl/libssl/buildfile151
-rw-r--r--libssl/manifest2
-rw-r--r--openssl/manifest2
-rw-r--r--openssl/openssl/buildfile118
6 files changed, 205 insertions, 226 deletions
diff --git a/libcrypto/libcrypto/buildfile b/libcrypto/libcrypto/buildfile
index 2c81156..69380a7 100644
--- a/libcrypto/libcrypto/buildfile
+++ b/libcrypto/libcrypto/buildfile
@@ -26,19 +26,12 @@ lib{crypto}: {h }{** -buildinf-body} \
downstream/internal/h{platform}@./downstream/internal/: dist = false
tclass = $c.target.class
+tsys = $c.target.system
i686 = ($c.target.cpu == 'i686')
-linux = ($tclass == 'linux')
-bsd = ($tclass == 'bsd')
windows = ($tclass == 'windows')
-msvc_runtime = ($c.target.system == 'win32-msvc')
-
-gcc = ($c.class == 'gcc')
-msvc = ($c.class == 'msvc')
-mingw = ($c.target.system == 'mingw32')
-
# Build options.
#
# Drop -DOPENSSL_PIC and -D{L|B}_ENDIAN preprocessor options and define
@@ -48,65 +41,68 @@ mingw = ($c.target.system == 'mingw32')
#
c.poptions += -DLIBCRYPTO_BUILD
+# Note that the upstream package uses -pthread compiler/linker option on
+# Linux and FreeBSD. The option is currently unsupported by build2, so we use
+# -D_REENTRANT and -lpthread preprocessor/linker options instead.
+#
+# Also note that on FreeBSD and Mac OS the upstream package also passes
+# -D_REENTRANT.
+#
if! $windows
-{
- # Note that the upstream package uses -pthread compiler/linker option on
- # Linux and FreeBSD. The option is currently unsupported by build2, so we
- # use -D_REENTRANT and -lpthread preprocessor/linker options instead.
- #
- # Also note that on FreeBSD and Mac OS the upstream package also passes
- # -D_REENTRANT.
- #
c.poptions += -D_REENTRANT
+else
+ c.poptions += -DWIN32_LEAN_AND_MEAN -DUNICODE -D_UNICODE
- if $linux
+switch $tclass, $tsys
+{
+ case 'linux'
c.poptions += -DOPENSSL_USE_NODELETE
- if $bsd
+ case 'bsd'
c.poptions += -D_THREAD_SAFE
-}
-else
-{
- c.poptions += -DWIN32_LEAN_AND_MEAN -DUNICODE -D_UNICODE
- # Note that upstream also adds Applink support if compiled with VC. This is
- # something about being able to use the library with application compiled
- # with a different compiler (see ../../upstream/Configurations/10-main.conf
- # for details). We drop this for now as it requires ASM support. In
- # particular, we don't pass -DOPENSSL_USE_APPLINK preprocessor option no
- # compile uplink.c and auto-generated uplink-x86_64.asm.
- #
- if $msvc_runtime
+ case 'windows', 'mingw32'
+ c.poptions += -D_MT
+
+ case 'windows'
+ {
+ # Note that upstream also adds Applink support if compiled with VC. This
+ # is something about being able to use the library with application
+ # compiled with a different compiler (see
+ # ../../upstream/Configurations/10-main.conf for details). We drop this
+ # for now as it requires ASM support. In particular, we don't pass
+ # -DOPENSSL_USE_APPLINK preprocessor option no compile uplink.c and
+ # auto-generated uplink-x86_64.asm.
+ #
c.poptions += -DOPENSSL_SYS_WIN32 -D_CRT_SECURE_NO_DEPRECATE \
-D_WINSOCK_DEPRECATED_NO_WARNINGS
-
- if $msvc
- c.coptions += /Gs0 /GF /Gy
- else
- c.poptions += -D_MT
+ }
}
-if ($i686 && $gcc)
- c.coptions += -fomit-frame-pointer
-
-# Disable compiler warnings.
-#
-if $msvc
+switch $c.class
{
- # Disable warnings that pop up with /W3.
- #
- c.coptions += /wd4090 /wd4129 /wd4164 /wd4244 /wd4267 /wd4311
-}
-elif $gcc
-{
- # Disable warnings that pop up with -Wall -Wextra. Upstream doesn't seem to
- # care about these and it is not easy to disable specific warnings in a way
- # that works across compilers/versions (some -Wno-* options are only
- # recognized in newer versions). There are still some warnings left that
- # appear for certain platforms/compilers. We pass them through but disable
- # treating them as errors.
- #
- c.coptions += -Wno-all -Wno-extra -Wno-error
+ case 'gcc'
+ {
+ if $i686
+ c.coptions += -fomit-frame-pointer
+
+ # Disable warnings that pop up with -Wall -Wextra. Upstream doesn't seem
+ # to care about these and it is not easy to disable specific warnings in a
+ # way that works across compilers/versions (some -Wno-* options are only
+ # recognized in newer versions). There are still some warnings left that
+ # appear for certain platforms/compilers. We pass them through but disable
+ # treating them as errors.
+ #
+ c.coptions += -Wno-all -Wno-extra -Wno-error
+ }
+ case 'msvc'
+ {
+ c.coptions += /Gs0 /GF /Gy
+
+ # Disable warnings that pop up with /W3.
+ #
+ c.coptions += /wd4090 /wd4129 /wd4164 /wd4244 /wd4267 /wd4311
+ }
}
# Define the OPENSSLDIR and ENGINESDIR macros as the upstream package does it
@@ -175,7 +171,9 @@ for f: $c.poptions $c.coptions
cflags += $regex.replace($f, '(\\|")', '\\\1')
h{buildinf-body}: in{buildinf-body}
-h{buildinf-body}: cflags = $regex.merge($cflags, '(.+)', '\n " \1"')
+{
+ cflags = $regex.merge($cflags, '(.+)', '\n " \1"')
+}
# Note that we have to add "-I$src_root" for the headers auto-generating
# machinery to work properly.
@@ -189,41 +187,39 @@ crypto/ec/curve448/ c.poptions =+ "-I$src_base" "-I$src_base/arch_32"
crypto/obj{cversion}: c.poptions =+ "-I$src_root/libcrypto/downstream/internal"
-if! $windows
+switch $tclass, $tsys
{
- if $linux
+ case 'linux'
{
- libs{crypto}: c.loptions += -Wl,-znodelete
- c.libs += -ldl
- }
+ c.loptions += -Wl,-znodelete -Wl,-Bsymbolic \
+ "-Wl,--version-script=$src_base/libcrypto.map"
- if ($linux || $bsd)
+ c.libs += -ldl -lpthread
+ }
+ case 'bsd'
{
- libs{crypto}: c.loptions += -Wl,-Bsymbolic \
- "-Wl,--version-script=$src_base/libcrypto.map"
+ c.loptions += -Wl,-Bsymbolic \
+ "-Wl,--version-script=$src_base/libcrypto.map"
+
c.libs += -lpthread
}
-}
-else
-{
- # Note that for MinGW GCC the upstream package also passes -static-libgcc.
- # We normally don't link GCC run-time statically when packaging other C
- # libraries, so let's not do that here either and see how it goes.
- #
- if $mingw
- libs{crypto}: c.loptions += -Wl,--enable-auto-image-base
-
- c.libs += $regex.apply(ws2_32 gdi32 crypt32, \
- '(.+)', \
- $msvc_runtime ? '\1.lib' : '-l\1')
-
- if $msvc_runtime
+ case 'windows', 'mingw32'
+ {
+ # Note that for MinGW GCC the upstream package also passes -static-libgcc.
+ # We normally don't link GCC run-time statically when packaging other C
+ # libraries, so let's not do that here either and see how it goes.
+ #
+ c.loptions += -Wl,--enable-auto-image-base
+
+ c.libs += -lws2_32 -lgdi32 -lcrypt32
+ }
+ case 'windows'
{
# Suppress the 'object file does not define any public symbols' warning.
#
c.aoptions += /IGNORE:4221
- c.libs += advapi32.lib
+ c.libs += ws2_32.lib gdi32.lib crypt32.lib advapi32.lib
}
}
diff --git a/libcrypto/manifest b/libcrypto/manifest
index 6497942..c33e796 100644
--- a/libcrypto/manifest
+++ b/libcrypto/manifest
@@ -3,7 +3,7 @@ name: libcrypto
# Note: remember to update doc-url below!
#
-version: 1.1.1+6
+version: 1.1.1+7
upstream-version: 1.1.1d
project: openssl
diff --git a/libssl/libssl/buildfile b/libssl/libssl/buildfile
index 2eebf19..6b41c17 100644
--- a/libssl/libssl/buildfile
+++ b/libssl/libssl/buildfile
@@ -7,113 +7,104 @@ import int_libs = libcrypto%lib{crypto}
lib{ssl}: {h c}{**} def{libssl} file{libssl.map} $int_libs
tclass = $c.target.class
-
-i686 = ($c.target.cpu == 'i686')
-
-linux = ($tclass == 'linux')
-bsd = ($tclass == 'bsd')
-windows = ($tclass == 'windows')
-
-msvc_runtime = ($c.target.system == 'win32-msvc')
-
-gcc = ($c.class == 'gcc')
-msvc = ($c.class == 'msvc')
-mingw = ($c.target.system == 'mingw32')
+tsys = $c.target.system
# Build options.
#
# Drop -DOPENSSL_PIC, -D{L|B}_ENDIAN, -DOPENSSLDIR and -DENGINESDIR as they
# are not used in the libssl source code nor in the libcrypto public headers.
#
-if! $windows
-{
- # Note that the upstream package uses -pthread compiler/linker option on
- # Linux and FreeBSD. The option is currently unsupported by build2, so we
- # use -D_REENTRANT and -lpthread preprocessor/linker options instead.
- #
- # Also note that on FreeBSD and Mac OS the upstream package passes
- # -D_REENTRANT.
- #
+# Note that the upstream package uses -pthread compiler/linker option on
+# Linux and FreeBSD. The option is currently unsupported by build2, so we use
+# -D_REENTRANT and -lpthread preprocessor/linker options instead.
+#
+# Also note that on FreeBSD and Mac OS the upstream package also passes
+# -D_REENTRANT.
+#
+if ($tclass != 'windows')
c.poptions += -D_REENTRANT
+else
+ c.poptions += -DWIN32_LEAN_AND_MEAN -DUNICODE -D_UNICODE
- if $linux
+switch $tclass, $tsys
+{
+ case 'linux'
c.poptions += -DOPENSSL_USE_NODELETE
- if $bsd
+ case 'bsd'
c.poptions += -D_THREAD_SAFE
-}
-else
-{
- c.poptions += -DWIN32_LEAN_AND_MEAN -DUNICODE -D_UNICODE
- # Note that upstream also passes -DOPENSSL_USE_APPLINK if compiled with VC.
- # We drop this option (see libcrypto/buildfile) for details.
- #
- if $msvc_runtime
+ case 'windows', 'mingw32'
+ c.poptions += -D_MT
+
+ case 'windows'
+ {
+ # Note that upstream also passes -DOPENSSL_USE_APPLINK if compiled with
+ # VC. We drop this option (see libcrypto/buildfile) for details.
+ #
c.poptions += -DOPENSSL_SYS_WIN32 -D_CRT_SECURE_NO_DEPRECATE \
-D_WINSOCK_DEPRECATED_NO_WARNINGS
-
- if $msvc
- c.coptions += /Gs0 /GF /Gy
- else
- c.poptions += -D_MT
+ }
}
-if ($i686 && $gcc)
- c.coptions += -fomit-frame-pointer
-
-# Disable compiler warnings.
-#
-if $msvc
-{
- # Disable warnings that pop up with /W3.
- #
- c.coptions += /wd4090 /wd4133 /wd4244 /wd4267
-}
-elif $gcc
+switch $c.class
{
- # Disable warnings that pop up with -Wall -Wextra. Upstream doesn't seem to
- # care about these and it is not easy to disable specific warnings in a way
- # that works across compilers/versions (some -Wno-* options are only
- # recognized in newer versions). There are still some warnings left that
- # appear for certain platforms/compilers. We pass them through but disable
- # treating them as errors.
- #
- c.coptions += -Wno-all -Wno-extra -Wno-error
+ case 'gcc'
+ {
+ if ($c.target.cpu == 'i686')
+ c.coptions += -fomit-frame-pointer
+
+ # Disable warnings that pop up with -Wall -Wextra. Upstream doesn't seem
+ # to care about these and it is not easy to disable specific warnings in a
+ # way that works across compilers/versions (some -Wno-* options are only
+ # recognized in newer versions). There are still some warnings left that
+ # appear for certain platforms/compilers. We pass them through but disable
+ # treating them as errors.
+ #
+ c.coptions += -Wno-all -Wno-extra -Wno-error
+ }
+ case 'msvc'
+ {
+ c.coptions += /Gs0 /GF /Gy
+
+ # Disable warnings that pop up with /W3.
+ #
+ c.coptions += /wd4090 /wd4133 /wd4244 /wd4267
+ }
}
c.poptions =+ "-I$src_base"
-if! $windows
+switch $tclass, $tsys
{
- if $linux
+ case 'linux'
{
- libs{ssl}: c.loptions += -Wl,-znodelete
- c.libs += -ldl
- }
+ c.loptions += -Wl,-znodelete -Wl,-Bsymbolic \
+ "-Wl,--version-script=$src_base/libssl.map"
- if ($linux || $bsd)
+ c.libs += -ldl -lpthread
+ }
+ case 'bsd'
{
- libs{ssl}: c.loptions += -Wl,-Bsymbolic \
- "-Wl,--version-script=$src_base/libssl.map"
+ c.loptions += -Wl,-Bsymbolic \
+ "-Wl,--version-script=$src_base/libssl.map"
+
c.libs += -lpthread
}
-}
-else
-{
- # Note that for MinGW GCC the upstream package also passes -static-libgcc.
- # We normally don't link GCC run-time statically when packaging other C
- # libraries, so let's not do it here either and see how it goes.
- #
- if $mingw
- libs{ssl}: c.loptions += -Wl,--enable-auto-image-base
-
- c.libs += $regex.apply(ws2_32 gdi32 crypt32, \
- '(.+)', \
- $msvc_runtime ? '\1.lib' : '-l\1')
-
- if $msvc_runtime
- c.libs += advapi32.lib
+ case 'windows', 'mingw32'
+ {
+ # Note that for MinGW GCC the upstream package also passes -static-libgcc.
+ # We normally don't link GCC run-time statically when packaging other C
+ # libraries, so let's not do that here either and see how it goes.
+ #
+ c.loptions += -Wl,--enable-auto-image-base
+
+ c.libs += -lws2_32 -lgdi32 -lcrypt32
+ }
+ case 'windows'
+ {
+ c.libs += ws2_32.lib gdi32.lib crypt32.lib advapi32.lib
+ }
}
# Export options.
diff --git a/libssl/manifest b/libssl/manifest
index bd804ac..f0463db 100644
--- a/libssl/manifest
+++ b/libssl/manifest
@@ -3,7 +3,7 @@ name: libssl
# Note: remember to update doc-url below!
#
-version: 1.1.1+6
+version: 1.1.1+7
upstream-version: 1.1.1d
project: openssl
diff --git a/openssl/manifest b/openssl/manifest
index 70051e0..2eece7a 100644
--- a/openssl/manifest
+++ b/openssl/manifest
@@ -3,7 +3,7 @@ name: openssl
# Note: remember to update doc-url below!
#
-version: 1.1.1+6
+version: 1.1.1+7
upstream-version: 1.1.1d
priority: security
diff --git a/openssl/openssl/buildfile b/openssl/openssl/buildfile
index 81e1d85..f9e317a 100644
--- a/openssl/openssl/buildfile
+++ b/openssl/openssl/buildfile
@@ -8,91 +8,83 @@ import libs += libcrypto%lib{crypto}
exe{openssl}: {h c}{** -vms_* -apps/win32_init} $libs
tclass = $c.target.class
+tsys = $c.target.system
-i686 = ($c.target.cpu == 'i686')
-
-linux = ($tclass == 'linux')
-bsd = ($tclass == 'bsd')
windows = ($tclass == 'windows')
-msvc_runtime = ($c.target.system == 'win32-msvc')
-
-gcc = ($c.class == 'gcc')
-msvc = ($c.class == 'msvc')
-
exe{openssl}: apps/c{win32_init}: include = $windows
# Build options.
#
+# Note that the upstream package uses -pthread compiler/linker option on
+# Linux and FreeBSD. The option is currently unsupported by build2, so we use
+# -D_REENTRANT and -lpthread preprocessor/linker options instead.
+#
+# Also note that on FreeBSD and Mac OS the upstream package also passes
+# -D_REENTRANT.
+#
if! $windows
-{
- # Note that the upstream package uses -pthread compiler/linker option on
- # Linux and FreeBSD. The option is currently unsupported by build2, so we
- # use -D_REENTRANT and -lpthread preprocessor/linker options instead.
- #
- # Also note that on FreeBSD and Mac OS the upstream package passes
- # -D_REENTRANT.
- #
c.poptions += -D_REENTRANT
-
- if $bsd
- c.poptions += -D_THREAD_SAFE
-}
else
-{
c.poptions += -DWIN32_LEAN_AND_MEAN -DUNICODE -D_UNICODE
- # Note that upstream also passes -DOPENSSL_USE_APPLINK if compiled with VC.
- # We drop this option (see libcrypto/buildfile) for details.
- #
- if $msvc_runtime
- c.poptions += -DOPENSSL_SYS_WIN32 -D_CRT_SECURE_NO_DEPRECATE \
- -D_WINSOCK_DEPRECATED_NO_WARNINGS
+switch $tclass, $tsys
+{
+ case 'bsd'
+ c.poptions += -D_THREAD_SAFE
- if $msvc
- c.coptions += /Gs0 /GF /Gy
- else
+ case 'windows', 'mingw32'
c.poptions += -D_MT
-}
-
-if ($i686 && $gcc)
- c.coptions += -fomit-frame-pointer
-# Disable compiler warnings.
-#
-if $msvc
-{
- # Disable warnings that pop up with /W3.
- #
- c.coptions += /wd4090 /wd4244 /wd4267
+ case 'windows'
+ {
+ # Note that upstream also passes -DOPENSSL_USE_APPLINK if compiled with
+ # VC. We drop this option (see libcrypto/buildfile) for details.
+ #
+ c.poptions += -DOPENSSL_SYS_WIN32 -D_CRT_SECURE_NO_DEPRECATE \
+ -D_WINSOCK_DEPRECATED_NO_WARNINGS
+ }
}
-elif $gcc
+
+switch $c.class
{
- # Disable warnings that pop up with -Wall -Wextra. Upstream doesn't seem to
- # care about these and it is not easy to disable specific warnings in a way
- # that works across compilers/versions (some -Wno-* options are only
- # recognized in newer versions). There are still some warnings left that
- # appear for certain platforms/compilers. We pass them through but disable
- # treating them as errors.
- #
- c.coptions += -Wno-all -Wno-extra -Wno-error
+ case 'gcc'
+ {
+ if ($c.target.cpu == 'i686')
+ c.coptions += -fomit-frame-pointer
+
+ # Disable warnings that pop up with -Wall -Wextra. Upstream doesn't seem
+ # to care about these and it is not easy to disable specific warnings in a
+ # way that works across compilers/versions (some -Wno-* options are only
+ # recognized in newer versions). There are still some warnings left that
+ # appear for certain platforms/compilers. We pass them through but disable
+ # treating them as errors.
+ #
+ c.coptions += -Wno-all -Wno-extra -Wno-error
+ }
+ case 'msvc'
+ {
+ c.coptions += /Gs0 /GF /Gy
+
+ # Disable warnings that pop up with /W3.
+ #
+ c.coptions += /wd4090 /wd4244 /wd4267
+ }
}
c.poptions =+ "-I$src_base"
-if! $windows
+switch $tclass, $tsys
{
- if $linux
- c.libs += -ldl
+ case 'linux'
+ c.libs += -ldl -lpthread
- if ($linux || $bsd)
+ case 'bsd'
c.libs += -lpthread
-}
-else
-{
- c.libs += $regex.apply(ws2_32 gdi32 crypt32, \
- '(.+)', \
- $msvc_runtime ? '\1.lib' : '-l\1')
- if $msvc_runtime
- c.libs += advapi32.lib
+
+ case 'windows', 'mingw32'
+ c.libs += -lws2_32 -lgdi32 -lcrypt32
+
+ case 'windows'
+ c.libs += ws2_32.lib gdi32.lib crypt32.lib advapi32.lib
}