From 3bc78855390d1fde57615572a7ca05c7dcb5e226 Mon Sep 17 00:00:00 2001 From: Harald Welte Date: Wed, 24 Aug 2011 08:32:38 +0200 Subject: re-introduce optional build of DAHDI input plugin We should only build it when the dahdi/user.h file is actually present. --- src/e1_input.c | 3 +++ src/input/dahdi.c | 6 ++++++ 2 files changed, 9 insertions(+) (limited to 'src') diff --git a/src/e1_input.c b/src/e1_input.c index f9d3477..a549ba4 100644 --- a/src/e1_input.c +++ b/src/e1_input.c @@ -20,6 +20,7 @@ */ #include "internal.h" +#include "../config.h" #include #include @@ -722,7 +723,9 @@ void e1inp_init(void) osmo_signal_register_handler(SS_L_GLOBAL, e1i_sig_cb, NULL); e1inp_misdn_init(); +#ifdef HAVE_DAHDI_USER_H e1inp_dahdi_init(); +#endif e1inp_ipaccess_init(); e1inp_hsl_init(); e1inp_rs232_init(); diff --git a/src/input/dahdi.c b/src/input/dahdi.c index 4fd4e61..a4dbd03 100644 --- a/src/input/dahdi.c +++ b/src/input/dahdi.c @@ -22,6 +22,10 @@ * */ +#include "../../config.h" + +#ifdef HAVE_DAHDI_USER_H + #include #include #include @@ -461,3 +465,5 @@ int e1inp_dahdi_init(void) /* register the driver with the core */ return e1inp_driver_register(&dahdi_driver); } + +#endif /* HAVE_DAHDI_USER_H */ -- cgit v1.2.3-55-g7522