From e2a7ad39d077777706512d80f85c9049f3f83a99 Mon Sep 17 00:00:00 2001 From: Ryan Tandy Date: Sat, 4 Jul 2020 00:38:36 +0000 Subject: [PATCH] ITS#9235 Disable slapd-mtread when NO_THREADS --- tests/progs/slapd-mtread.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/tests/progs/slapd-mtread.c b/tests/progs/slapd-mtread.c index 1b99b625c2..adfa552c67 100644 --- a/tests/progs/slapd-mtread.c +++ b/tests/progs/slapd-mtread.c @@ -25,6 +25,9 @@ #include "portable.h" +/* Requires libldap with threads */ +#ifndef NO_THREADS + #include #include "ldap_pvt_thread.h" @@ -705,3 +708,17 @@ retry:; } } } + +#else /* NO_THREADS */ + +#include +#include + +int +main( int argc, char **argv ) +{ + fprintf( stderr, "%s: not available when configured --without-threads\n", argv[0] ); + exit( EXIT_FAILURE ); +} + +#endif /* NO_THREADS */