-
Notifications
You must be signed in to change notification settings - Fork 14
Openssl #294
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
base: master
Are you sure you want to change the base?
Openssl #294
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -2,7 +2,7 @@ inherit: [cpackage, make, install, patch] | |
|
|
||
| metaEnvironment: | ||
| PKG_LICENSE: "Apache-2.0" | ||
| PKG_VERSION: "3.3.1" | ||
| PKG_VERSION: "3.5.4" | ||
|
|
||
| depends: | ||
| - libs::zlib-dev | ||
|
|
@@ -14,33 +14,48 @@ depends: | |
| checkoutSCM: | ||
| scm: url | ||
| url: https://www.openssl.org/source/openssl-${PKG_VERSION}.tar.gz | ||
| digestSHA256: 777cd596284c883375a2a7a11bf5d2786fc5413255efab20c50d6ffe6d020b7e | ||
| digestSHA256: 967311f84955316969bdb1d8d4b983718ef42338639c621ec4c34fddef355e99 | ||
| stripComponents: 1 | ||
|
|
||
| checkoutDeterministic: True | ||
| checkoutScript: | | ||
| patchApplySeries $<@openssl/*.patch@> | ||
|
|
||
| Config: | ||
| OPENSSL_ADDITIONAL_OPTIONS: | ||
| help: additional configure options | ||
| OPENSSL_LINK_MODE: | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The idea for such things was to set depends:
- name: libs::openssl
environment:
BASEMENT_LIBS: sharedThis will override the heuristic for Actually, I think our openssl recipe is wrong and should pass |
||
| help: overrides the automatically determined link mode | ||
| type: choice | ||
| choice: | ||
| "-static": | ||
| "shared": | ||
|
|
||
| buildTools: [target-toolchain] | ||
| buildToolsWeak: [perl] | ||
| buildVars: [CC, AR, RANLIB, ARCH, AUTOCONF_HOST] | ||
| buildVars: [CC, AR, RANLIB, ARCH, AUTOCONF_HOST, OPENSSL_ADDITIONAL_OPTIONS, | ||
| OPENSSL_LINK_MODE] | ||
| buildScript: | | ||
| mkdir -p install build | ||
| pushd build | ||
|
|
||
| SHARED_ONLY="false" | ||
| case $(cpackageLibraryType) in | ||
| static) | ||
| SHARED_STATIC=( "-static" "zlib" ) | ||
| ;; | ||
| shared) | ||
| SHARED_STATIC=( "shared" "zlib" ) | ||
| SHARED_ONLY="true" | ||
| ;; | ||
| both) | ||
| SHARED_STATIC=( "shared" "zlib" ) | ||
| ;; | ||
| esac | ||
| if [ ! -z "${OPENSSL_LINK_MODE:-}" ]; then | ||
| SHARED_STATIC=("${OPENSSL_LINK_MODE}" "zlib") | ||
| else | ||
| case $(cpackageLibraryType) in | ||
| static) | ||
| SHARED_STATIC=( "-static" "zlib" ) | ||
| ;; | ||
| shared) | ||
| SHARED_STATIC=( "shared" "zlib" ) | ||
| SHARED_ONLY="true" | ||
| ;; | ||
| both) | ||
| SHARED_STATIC=( "shared" "zlib" ) | ||
| ;; | ||
| esac | ||
| fi | ||
|
|
||
| # refer: https://github.com/openssl/openssl/blob/master/Configurations/10-main.conf | ||
| case "$ARCH" in | ||
|
|
@@ -80,6 +95,7 @@ buildScript: | | |
| --libdir=lib \ | ||
| "${SHARED_STATIC[@]}" \ | ||
| "threads" \ | ||
| ${OPENSSL_ADDITIONAL_OPTIONS:-} \ | ||
| "-I${BOB_DEP_PATHS[libs::zlib-dev]}/usr/include" \ | ||
| "-Wl,-L${BOB_DEP_PATHS[libs::zlib-dev]}/usr/lib" \ | ||
| "-Wl,-rpath-link=${BOB_DEP_PATHS[libs::zlib-dev]}/usr/lib" \ | ||
|
|
@@ -105,10 +121,24 @@ multiPackage: | |
| provideTools: | ||
| openssl: "usr/bin" | ||
|
|
||
| # using openssl plugins within the host-tool requires a shared variant | ||
| pluginable: | ||
| environment: | ||
| OPENSSL_LINK_MODE: "shared" | ||
| packageScript: | | ||
| installPackageTgt "$1/install/" | ||
| provideTools: | ||
| openssl: | ||
| path: "usr/bin" | ||
| libs: [ "usr/lib", "usr/lib/engines" ] | ||
|
|
||
| dev: | ||
| # Static library builds need to explicitly link with libz but the | ||
| # pkgconfig file is not referenced. Fix that up. | ||
| packageScript: | | ||
| if [[ ${OPENSSL_LINK_MODE:-} == *"shared"* ]]; then | ||
| INSTALL_SHARED="true" | ||
| fi | ||
| installPackageDev "$1/install/" | ||
| sed -i -e '/^Libs:.*-lz/{ | ||
| s/-lz// | ||
|
|
@@ -117,5 +147,9 @@ multiPackage: | |
| provideDeps: [ "*-dev" ] | ||
|
|
||
| tgt: | ||
| packageScript: installPackageLib "$1/install/" | ||
| packageScript: | | ||
| if [[ ${OPENSSL_LINK_MODE:-} == *"shared"* ]]; then | ||
| INSTALL_SHARED="true" | ||
| fi | ||
| installPackageLib "$1/install/" | ||
| provideDeps: [ "*-tgt" ] | ||
This file was deleted.
This file was deleted.
This file was deleted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does it make sense to name the algorithms explicitly like buildroot does? This catch-all variable seems a bit coarse grained. Even if not done now, would it be a problem on your side if we go in this direction?