#!/bin/sh -e
export CPPFLAGS="-DSQLITE_ENABLE_COLUMN_METADATA=1"
sed 's/ -ltinfo//g' configure > _
mv -f _ configure
chmod +x configure
./configure \
--prefix=/usr \
--enable-threadsafe \
--enable-dynamic-extensions \
--enable-fts5
make -j1
make DESTDIR="$1" install