-#define _XOPEN_SOURCE 500
+#include "config.h"
#include <unistd.h>
#include "lock-tracking.h"
#include <ccan/tap/tap.h>
#define free free_noleak
#include <ccan/tdb2/tdb.c>
+#include <ccan/tdb2/open.c>
#include <ccan/tdb2/free.c>
#include <ccan/tdb2/lock.c>
#include <ccan/tdb2/io.c>