From 935478c3fe03346f6d6323f00424df07b2f04c70 Mon Sep 17 00:00:00 2001 From: Explorer09 Date: Sat, 26 Nov 2016 17:21:25 +0800 Subject: [PATCH] build: allow building libfl even with --disable-libfl. For various reasons, we may wish to build libfl explicitly even when configure has been run with the --disable-libfl option. This is possible, now, via 'make -C src libfl.la'. --- configure.ac | 4 ++-- src/Makefile.am | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/configure.ac b/configure.ac index 5a29b79..7d742c5 100644 --- a/configure.ac +++ b/configure.ac @@ -64,7 +64,7 @@ AC_ARG_ENABLE([libfl], [AS_HELP_STRING([--disable-libfl], [do not build -lfl runtime support library])], [], [enable_libfl=yes]) -AM_CONDITIONAL([ENABLE_LIBFL], [test "$enable_libfl" = yes]) +AM_CONDITIONAL([ENABLE_LIBFL], [test "x$enable_libfl" = xyes]) AC_PATH_PROG([BISON], bison, no) AS_IF([test "$BISON" != no],[], @@ -122,7 +122,7 @@ AC_DEFINE([HAVE_LIBPTHREAD], 1, [pthread library] ), AC_DEFINE([HAVE_LIBPTHREAD], 0, [pthread library] ) ) AC_CHECK_HEADERS([pthread.h]) -AM_CONDITIONAL([want_pthread], [test x$ac_cv_lib_pthread_pthread_mutex_lock = xyes]) +AM_CONDITIONAL([want_pthread], [test "x$ac_cv_lib_pthread_pthread_mutex_lock" = xyes]) AC_CHECK_LIB(m, log10) diff --git a/src/Makefile.am b/src/Makefile.am index fdd3c92..0d267db 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -10,11 +10,11 @@ noinst_PROGRAMS = stage1flex if ENABLE_LIBFL lib_LTLIBRARIES = libfl.la +endif libfl_la_SOURCES = \ libmain.c \ libyywrap.c libfl_la_LDFLAGS = -version-info @SHARED_VERSION_INFO@ -endif stage1flex_SOURCES = \ scan.l \ -- 2.40.0