Remaining problem is that not all *.syms linker scripts are generated
so the LD command needs to look in a single place. Out of tree
builds now work but report write access to the source tree in order
to create the $(srcdir)/expotrs/libtdb.sysms file.
LIBTDB_SHARED_TARGET=@LIBTDB_SHARED_TARGET@
LIBTDB_STATIC_TARGET=@LIBTDB_STATIC_TARGET@
LIBTDB=$(LIBTDB_STATIC_TARGET) @LIBTDB_SHARED@
-LIBTDB_SYMS=exports/libtdb.syms
+LIBTDB_SYMS=$(srcdir)/exports/libtdb.syms
LIBTDB_HEADERS=@tdbdir@/include/tdb.h
LIBSMBCLIENT=bin/libsmbclient.a @LIBSMBCLIENT_SHARED@
# TODO: These should come from m4_include(lib/tdb/libtdb.m4)
# but currently this fails: things have to get merged from s4.
-tdbdir="lib/tdb"
+tdbdir="${srcdir-.}/lib/tdb"
AC_SUBST(tdbdir)
TDB_CFLAGS="-I$tdbdir/include"
AC_SUBST(TDB_CFLAGS)
mkdir -p `dirname $symsfile`
-${awk} -f script/mksyms.awk $proto_src > $symsfile_tmp
+${awk} -f `dirname $0`/mksyms.awk $proto_src > $symsfile_tmp
if cmp -s $symsfile $symsfile_tmp 2>/dev/null
then