Skip to content

Commit 091df84

Browse files
committed
wip openssl default
1 parent 50d8062 commit 091df84

File tree

9 files changed

+35
-30
lines changed

9 files changed

+35
-30
lines changed

.github/workflows/android.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
- name: Configure CMake
2424
working-directory: ${{github.workspace}}/build
2525
shell: bash
26-
run: cmake $GITHUB_WORKSPACE -DCMAKE_TOOLCHAIN_FILE=$ANDROID_NDK/build/cmake/android.toolchain.cmake -DANDROID_ABI=arm64-v8a
26+
run: cmake $GITHUB_WORKSPACE -DCRYPTO_LIBRARY=internal -DCMAKE_TOOLCHAIN_FILE=$ANDROID_NDK/build/cmake/android.toolchain.cmake -DANDROID_ABI=arm64-v8a
2727

2828
- name: Build
2929
working-directory: ${{github.workspace}}/build
@@ -36,7 +36,7 @@ jobs:
3636
- name: Configure CMake (Shared Library)
3737
working-directory: ${{github.workspace}}/build_shared
3838
shell: bash
39-
run: cmake $GITHUB_WORKSPACE -DBUILD_SHARED_LIBS=ON -DCMAKE_TOOLCHAIN_FILE=$ANDROID_NDK/build/cmake/android.toolchain.cmake -DANDROID_ABI=arm64-v8a
39+
run: cmake $GITHUB_WORKSPACE -DCRYPTO_LIBRARY=internal -DBUILD_SHARED_LIBS=ON -DCMAKE_TOOLCHAIN_FILE=$ANDROID_NDK/build/cmake/android.toolchain.cmake -DANDROID_ABI=arm64-v8a
4040

4141
- name: Build (Shared Library)
4242
working-directory: ${{github.workspace}}/build_shared

.github/workflows/autotools.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
crypto: [internal, openssl, wolfssl, nss]
1717
include:
1818
- crypto: internal
19-
configure-crypto-enable: ""
19+
configure-crypto-enable: "--with-crypto-library=internal"
2020
- crypto: openssl
2121
configure-crypto-enable: "--with-crypto-library=openssl"
2222
- crypto: wolfssl

.github/workflows/cmake.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
crypto: openssl3
3131
include:
3232
- crypto: internal
33-
cmake-crypto-enable: ""
33+
cmake-crypto-enable: "-DCRYPTO_LIBRARY=internal"
3434
- crypto: openssl
3535
cmake-crypto-enable: "-DCRYPTO_LIBRARY=openssl"
3636
- crypto: openssl3

.github/workflows/meson.yml

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
crypto: openssl3
3131
include:
3232
- crypto: internal
33-
meson-crypto-enable: ""
33+
meson-crypto-enable: "-Dcrypto-library=internal"
3434
- crypto: openssl
3535
meson-crypto-enable: "-Dcrypto-library=openssl"
3636
- crypto: openssl3
@@ -126,12 +126,7 @@ jobs:
126126
- uses: actions/checkout@v2
127127

128128
- name: Create Build Environment
129-
run: meson setup ${{github.workspace}}/build
130-
131-
- name: Configure Meson
132-
working-directory: ${{github.workspace}}/build
133-
shell: bash
134-
run: ${{ env.pkgconfig-crypto-dir }} meson configure ${{ matrix.meson-crypto-enable }}
129+
run: meson setup ${{github.workspace}}/build ${{ matrix.meson-crypto-enable }}
135130

136131
- name: Build
137132
working-directory: ${{github.workspace}}/build

.github/workflows/stream_list.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
- name: Configure CMake
2929
working-directory: ${{github.workspace}}/build
3030
shell: bash
31-
run: cmake $GITHUB_WORKSPACE -DLIBSRTP_TEST_APPS=ON -DCMAKE_C_FLAGS:STRING="-DSRTP_NO_STREAM_LIST -DSRTP_USE_TEST_STREAM_LIST"
31+
run: cmake $GITHUB_WORKSPACE -DCRYPTO_LIBRARY=internal -DLIBSRTP_TEST_APPS=ON -DCMAKE_C_FLAGS:STRING="-DSRTP_NO_STREAM_LIST -DSRTP_USE_TEST_STREAM_LIST"
3232

3333
- name: Build
3434
working-directory: ${{github.workspace}}/build

CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,8 @@ set(ENABLE_DEBUG_LOGGING OFF CACHE BOOL "Enable debug logging in all modules")
8686
set(ERR_REPORTING_STDOUT OFF CACHE BOOL "Enable logging to stdout")
8787
set(ERR_REPORTING_FILE "" CACHE FILEPATH "Use file for logging")
8888

89-
set(CRYPTO_LIBRARY_VALUES "internal;openssl;wolfssl;mbedtls;nss")
90-
set(CRYPTO_LIBRARY "internal" CACHE STRING
89+
set(CRYPTO_LIBRARY_VALUES "openssl;wolfssl;mbedtls;nss;internal")
90+
set(CRYPTO_LIBRARY "openssl" CACHE STRING
9191
"Crypto library used by libSRTP, can be one of: ${CRYPTO_LIBRARY_VALUES}")
9292
set_property(CACHE CRYPTO_LIBRARY PROPERTY STRINGS ${CRYPTO_LIBRARY_VALUES})
9393
if(NOT CRYPTO_LIBRARY IN_LIST CRYPTO_LIBRARY_VALUES)

configure

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1329,8 +1329,8 @@ Optional Packages:
13291329
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
13301330
--without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
13311331
--with-crypto-library=TYPE
1332-
Select crypto library, one of: internal, openssl,
1333-
wolfssl, nss
1332+
Select crypto library, one of: openssl, wolfssl,
1333+
nss, internal
13341334
--with-openssl-dir Location of OpenSSL installation
13351335
--with-wolfssl-dir Location of wolfSSL installation
13361336
--with-nss-dir Location of NSS installation
@@ -5387,18 +5387,23 @@ $as_echo_n "checking for crypto library... " >&6; }
53875387
if test "${with_crypto_library+set}" = set; then :
53885388
withval=$with_crypto_library; case "$with_crypto_library" in
53895389
internal) ;;
5390-
openssl) enable_openssl=yes ;;
5391-
wolfssl) enable_wolfssl=yes ;;
5392-
nss) enable_nss=yes ;;
5393-
*) as_fn_error "Invalid crypto library: $with_crypto_library. Select one of: internal, openssl, wolfssl, nss," "$LINENO" 5 ;;
5390+
openssl) ;;
5391+
wolfssl) ;;
5392+
nss) ;;
5393+
*) as_fn_error "Invalid crypto library: $with_crypto_library. Select one of: openssl, wolfssl, nss, internal" "$LINENO" 5 ;;
53945394
esac
53955395
else
5396-
with_crypto_library=internal
5396+
with_crypto_library=openssl
53975397
fi
53985398

53995399
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_crypto_library" >&5
54005400
$as_echo "$with_crypto_library" >&6; }
5401-
5401+
case "$with_crypto_library" in
5402+
internal) ;;
5403+
openssl) enable_openssl=yes ;;
5404+
wolfssl) enable_wolfssl=yes ;;
5405+
nss) enable_nss=yes ;;
5406+
esac
54025407
if test "$enable_openssl" = "yes"; then
54035408
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for user specified OpenSSL directory" >&5
54045409
$as_echo_n "checking for user specified OpenSSL directory... " >&6; }

configure.ac

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -205,17 +205,22 @@ PKG_PROG_PKG_CONFIG
205205
AS_IF([test "x$PKG_CONFIG" != "x"], [PKG_CONFIG="$PKG_CONFIG --static"])
206206

207207
AC_MSG_CHECKING([for crypto library])
208-
AC_ARG_WITH([crypto-library], AS_HELP_STRING([--with-crypto-library=TYPE], [Select crypto library, one of: internal, openssl, wolfssl, nss]),
208+
AC_ARG_WITH([crypto-library], AS_HELP_STRING([--with-crypto-library=TYPE], [Select crypto library, one of: openssl, wolfssl, nss, internal]),
209209
[case "$with_crypto_library" in
210210
internal) ;;
211-
openssl) enable_openssl=yes ;;
212-
wolfssl) enable_wolfssl=yes ;;
213-
nss) enable_nss=yes ;;
214-
*) AC_MSG_ERROR([Invalid crypto library: $with_crypto_library. Select one of: internal, openssl, wolfssl, nss,]) ;;
211+
openssl) ;;
212+
wolfssl) ;;
213+
nss) ;;
214+
*) AC_MSG_ERROR([Invalid crypto library: $with_crypto_library. Select one of: openssl, wolfssl, nss, internal]) ;;
215215
esac],
216-
[with_crypto_library=internal])
216+
[with_crypto_library=openssl])
217217
AC_MSG_RESULT([$with_crypto_library])
218-
218+
case "$with_crypto_library" in
219+
internal) ;;
220+
openssl) enable_openssl=yes ;;
221+
wolfssl) enable_wolfssl=yes ;;
222+
nss) enable_nss=yes ;;
223+
esac
219224
if test "$enable_openssl" = "yes"; then
220225
AC_MSG_CHECKING([for user specified OpenSSL directory])
221226
AC_ARG_WITH([openssl-dir],

meson_options.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ option('log-stdout', type : 'boolean', value : false,
44
description : 'Redirect logging to stdout')
55
option('log-file', type : 'string', value : '',
66
description : 'Write logging output into this file')
7-
option('crypto-library', type: 'combo', choices : ['none', 'openssl', 'wolfssl', 'nss', 'mbedtls'], value : 'none',
7+
option('crypto-library', type: 'combo', choices : ['openssl', 'wolfssl', 'nss', 'mbedtls', 'internal'], value : 'openssl',
88
description : 'What external crypto library to leverage, if any (OpenSSL, wolfSSL, NSS, or mbedtls)')
99
option('crypto-library-kdf', type : 'feature', value : 'auto',
1010
description : 'Use the external crypto library for Key Derivation Function support')

0 commit comments

Comments
 (0)