From bc26b4be1de6a0a06af53a242b33708109bb6cfc Mon Sep 17 00:00:00 2001 From: Stephan Bosch Date: Tue, 24 Oct 2023 21:41:04 +0200 Subject: [PATCH] lib-oauth2: test-oauth2-jwt - Allow running test from paths other than current directory --- src/lib-oauth2/Makefile.am | 3 ++- src/lib-oauth2/test-oauth2-jwt.c | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/lib-oauth2/Makefile.am b/src/lib-oauth2/Makefile.am index af5f66916b..7ae5372a54 100644 --- a/src/lib-oauth2/Makefile.am +++ b/src/lib-oauth2/Makefile.am @@ -4,7 +4,8 @@ AM_CPPFLAGS = \ -I$(top_srcdir)/src/lib-http \ -I$(top_srcdir)/src/lib-dcrypt \ -I$(top_srcdir)/src/lib-dict \ - -I$(top_srcdir)/src/lib-settings + -I$(top_srcdir)/src/lib-settings \ + -DTEST_DCRYPT_MODULE_DIR=\""$(abs_top_builddir)/src/lib-dcrypt/.libs"\" noinst_LTLIBRARIES=liboauth2.la diff --git a/src/lib-oauth2/test-oauth2-jwt.c b/src/lib-oauth2/test-oauth2-jwt.c index 41604cbb63..541b49216d 100644 --- a/src/lib-oauth2/test-oauth2-jwt.c +++ b/src/lib-oauth2/test-oauth2-jwt.c @@ -933,7 +933,7 @@ static void test_do_init(void) { const char *error; struct dcrypt_settings dcrypt_set = { - .module_dir = "../lib-dcrypt/.libs", + .module_dir = TEST_DCRYPT_MODULE_DIR, }; struct dict_settings dict_set = { .base_dir = ".", -- 2.47.3