summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/conf_macros.m47
-rw-r--r--src/tests/common.c8
2 files changed, 6 insertions, 9 deletions
diff --git a/src/conf_macros.m4 b/src/conf_macros.m4
index 4ea4e936..26eb4acc 100644
--- a/src/conf_macros.m4
+++ b/src/conf_macros.m4
@@ -329,11 +329,12 @@ AC_DEFUN([WITH_TEST_DIR],
[AC_HELP_STRING([--with-test-dir=PATH],
[Directory used for make check temporary files [$builddir]]
)
- ]
+ ],
+ [TEST_DIR=$withval],
+ [TEST_DIR="."]
)
- TEST_DIR=$with_test_dir
AC_SUBST(TEST_DIR)
- AC_DEFINE_UNQUOTED(TEST_DIR, "$with_test_dir", [Directory used for 'make check' temporary files])
+ AC_DEFINE_UNQUOTED(TEST_DIR, "$TEST_DIR", [Directory used for 'make check' temporary files])
])
AC_DEFUN([WITH_NSCD],
diff --git a/src/tests/common.c b/src/tests/common.c
index 54c93e28..16c05165 100644
--- a/src/tests/common.c
+++ b/src/tests/common.c
@@ -33,12 +33,8 @@ tests_set_cwd(void)
ret = chdir(TEST_DIR);
if (ret == -1) {
- if (strlen(TEST_DIR)) {
- fprintf(stderr,
- "Could not chdir to [%s].\n"
- "Attempting to continue with current dir\n",
- TEST_DIR);
- }
+ fprintf(stderr, "Could not chdir to [%s].\n"
+ "Attempting to continue with current dir\n", TEST_DIR);
}
}