diff --git a/src/util/bt.c b/src/util/bt.c index c750080..eacefef 100644 --- a/src/util/bt.c +++ b/src/util/bt.c @@ -28,6 +28,8 @@ #include "bt.h" #include "bool.h" +#if defined(HAS_BACKTRACE) || defined(HAS_LIBUNWIND) || defined(HAS_EXECINFO) + static void bt_add_frame(struct backtrace *bt, const char *fname) { if (bt->frame_count >= BT_MAX_FRAMES) @@ -41,6 +43,8 @@ static void bt_add_frame(struct backtrace *bt, const char *fname) bt->frame_count++; } +#endif + #ifdef HAS_BACKTRACE #include