diff options
-rwxr-xr-x | bootstrap | 2 | ||||
-rw-r--r-- | configure.ac | 11 | ||||
-rw-r--r-- | src/plugins/Makefile.am | 2 | ||||
-rw-r--r-- | src/plugins/html_extractor.c | 7 |
4 files changed, 18 insertions, 4 deletions
@@ -27,7 +27,7 @@ else | |||
27 | fi | 27 | fi |
28 | 28 | ||
29 | if existence libtool || existence libtoolize || existence glibtoolize || existence slibtool; then | 29 | if existence libtool || existence libtoolize || existence glibtoolize || existence slibtool; then |
30 | autoreconf -I m4 -i ${1+"$@"} | 30 | autoreconf -f -I m4 -i ${1+"$@"} |
31 | else | 31 | else |
32 | echo "*** No libtoolize (libtool) or libtool found, please install it ***" >&2; | 32 | echo "*** No libtoolize (libtool) or libtool found, please install it ***" >&2; |
33 | exit 1 | 33 | exit 1 |
diff --git a/configure.ac b/configure.ac index e89d70c..703c4a6 100644 --- a/configure.ac +++ b/configure.ac | |||
@@ -426,14 +426,20 @@ AC_CHECK_LIB(magic, magic_open, | |||
426 | AM_CONDITIONAL(HAVE_MAGIC, false))], | 426 | AM_CONDITIONAL(HAVE_MAGIC, false))], |
427 | AM_CONDITIONAL(HAVE_MAGIC, false)) | 427 | AM_CONDITIONAL(HAVE_MAGIC, false)) |
428 | 428 | ||
429 | dnl tidyNodeGetValue was already available in 5.0.0, released in 2015. | 429 | # tidyNodeGetValue was already available in 5.0.0, released in 2015. |
430 | maybe_tidy=1 | ||
430 | PKG_CHECK_MODULES([TIDY], [tidy >= 5.0.0], | 431 | PKG_CHECK_MODULES([TIDY], [tidy >= 5.0.0], |
431 | [AC_DEFINE(HAVE_TIDY, 1, [Have tidy]) | 432 | [AC_DEFINE(HAVE_TIDY, 1, [Have tidy]) |
432 | AM_CONDITIONAL(HAVE_TIDY, true)], | 433 | AM_CONDITIONAL(HAVE_TIDY, true)], |
433 | [AM_CONDITIONAL(HAVE_TIDY, false)]) | 434 | [maybe_tidy=0]) |
434 | CFLAGS="$CFLAGS $TIDY_CFLAGS" | 435 | CFLAGS="$CFLAGS $TIDY_CFLAGS" |
435 | LIBS="$LIBS $TIDY_LIBS" | 436 | LIBS="$LIBS $TIDY_LIBS" |
436 | 437 | ||
438 | AC_CHECK_HEADERS([tidy.h],, | ||
439 | AC_CHECK_HEADERS([tidy/tidy.h],,[maybe_tidy=0])) | ||
440 | |||
441 | AM_CONDITIONAL(HAVE_TIDY, test "x$maybe_tidy" = "x1") | ||
442 | |||
437 | # should 'make check' run tests? | 443 | # should 'make check' run tests? |
438 | AC_MSG_CHECKING(whether to run tests) | 444 | AC_MSG_CHECKING(whether to run tests) |
439 | AC_ARG_ENABLE([testruns], | 445 | AC_ARG_ENABLE([testruns], |
@@ -443,7 +449,6 @@ AC_ARG_ENABLE([testruns], | |||
443 | AC_MSG_RESULT($enable_test_run) | 449 | AC_MSG_RESULT($enable_test_run) |
444 | AM_CONDITIONAL([ENABLE_TEST_RUN], [test "x$enable_tests_run" = "xyes"]) | 450 | AM_CONDITIONAL([ENABLE_TEST_RUN], [test "x$enable_tests_run" = "xyes"]) |
445 | 451 | ||
446 | |||
447 | AC_HEADER_DIRENT | 452 | AC_HEADER_DIRENT |
448 | AC_HEADER_STDBOOL | 453 | AC_HEADER_STDBOOL |
449 | AC_CHECK_HEADERS([iconv.h fcntl.h netinet/in.h stdlib.h string.h unistd.h libintl.h limits.h stddef.h zlib.h]) | 454 | AC_CHECK_HEADERS([iconv.h fcntl.h netinet/in.h stdlib.h string.h unistd.h libintl.h limits.h stddef.h zlib.h]) |
diff --git a/src/plugins/Makefile.am b/src/plugins/Makefile.am index 69cb1f7..f32114a 100644 --- a/src/plugins/Makefile.am +++ b/src/plugins/Makefile.am | |||
@@ -363,6 +363,8 @@ test_gstreamer_CFLAGS = \ | |||
363 | 363 | ||
364 | libextractor_html_la_SOURCES = \ | 364 | libextractor_html_la_SOURCES = \ |
365 | html_extractor.c | 365 | html_extractor.c |
366 | libextractor_html_la_CFLAGS = \ | ||
367 | $(TIDY_CFLAGS) | ||
366 | libextractor_html_la_LDFLAGS = \ | 368 | libextractor_html_la_LDFLAGS = \ |
367 | $(PLUGINFLAGS) | 369 | $(PLUGINFLAGS) |
368 | libextractor_html_la_LIBADD = \ | 370 | libextractor_html_la_LIBADD = \ |
diff --git a/src/plugins/html_extractor.c b/src/plugins/html_extractor.c index 88100d3..0a9a89b 100644 --- a/src/plugins/html_extractor.c +++ b/src/plugins/html_extractor.c | |||
@@ -26,8 +26,15 @@ | |||
26 | #include "platform.h" | 26 | #include "platform.h" |
27 | #include "extractor.h" | 27 | #include "extractor.h" |
28 | #include <magic.h> | 28 | #include <magic.h> |
29 | #if HAVE_TIDY_H | ||
29 | #include <tidy.h> | 30 | #include <tidy.h> |
30 | #include <tidybuffio.h> | 31 | #include <tidybuffio.h> |
32 | #elif HAVE_TIDY_TIDY_H | ||
33 | #include <tidy/tidy.h> | ||
34 | #include <tidy/tidybuffio.h> | ||
35 | #else | ||
36 | Broken build, fix tidy detection. | ||
37 | #endif | ||
31 | 38 | ||
32 | /** | 39 | /** |
33 | * Mapping of HTML META names to LE types. | 40 | * Mapping of HTML META names to LE types. |