mirror of
https://git.notmuchmail.org/git/notmuch
synced 2024-11-25 04:18:08 +01:00
configure: check directly for xapian compaction API
This is consistent with the check for FieldProcessor, and probably a bit more robust.
This commit is contained in:
parent
792bea5aff
commit
1aa6f90a10
1 changed files with 13 additions and 10 deletions
21
configure
vendored
21
configure
vendored
|
@ -361,17 +361,20 @@ fi
|
||||||
have_xapian_compact=0
|
have_xapian_compact=0
|
||||||
have_xapian_field_processor=0
|
have_xapian_field_processor=0
|
||||||
if [ ${have_xapian} = "1" ]; then
|
if [ ${have_xapian} = "1" ]; then
|
||||||
# Compaction is only supported on Xapian > 1.2.6
|
|
||||||
printf "Checking for Xapian compaction support... "
|
printf "Checking for Xapian compaction support... "
|
||||||
case "${xapian_version}" in
|
cat>_compact.cc<<EOF
|
||||||
0.*|1.[01].*|1.2.[0-5])
|
#include <xapian.h>
|
||||||
printf "No (only available with Xapian > 1.2.6).\n" ;;
|
class TestCompactor : public Xapian::Compactor { };
|
||||||
[1-9]*.[0-9]*.[0-9]*)
|
EOF
|
||||||
|
if ${CXX} ${CXXFLAGS_for_sh} ${xapian_cxxflags} -c _compact.cc -o _compact.o > /dev/null 2>&1
|
||||||
|
then
|
||||||
have_xapian_compact=1
|
have_xapian_compact=1
|
||||||
printf "Yes.\n" ;;
|
printf "Yes.\n"
|
||||||
*)
|
else
|
||||||
printf "Unknown version.\n" ;;
|
printf "No.\n"
|
||||||
esac
|
fi
|
||||||
|
|
||||||
|
rm -f _compact.o _compact.cc
|
||||||
|
|
||||||
printf "Checking for Xapian FieldProcessor API... "
|
printf "Checking for Xapian FieldProcessor API... "
|
||||||
cat>_field_processor.cc<<EOF
|
cat>_field_processor.cc<<EOF
|
||||||
|
|
Loading…
Reference in a new issue