Commit 4f0e3014 authored by Evan Hunt's avatar Evan Hunt
Browse files

Restructured src/lib/auth:

 - test-related files are now in "tests"
 - concrete data sources are now named "sqlite3_ds.h" and "static_ds.h",
   so we don't have so many files all starting with "data_source".


git-svn-id: svn://bind10.isc.org/svn/bind10/trunk@1260 e5f2f494-b856-4b98-b285-d166d9295462
parent ceb44cf5
SUBDIRS = . tests
AM_CPPFLAGS = -I$(top_builddir)/src/lib -I$(top_srcdir)/ext $(SQLITE_CFLAGS)
CLEANFILES = *.gcno *.gcda
lib_LTLIBRARIES = libauth.la
libauth_la_SOURCES = data_source.h data_source.cc
libauth_la_SOURCES += data_source_static.h data_source_static.cc
libauth_la_SOURCES += data_source_sqlite3.h data_source_sqlite3.cc
libauth_la_SOURCES += static_ds.h static_ds.cc
libauth_la_SOURCES += sqlite3_ds.h sqlite3_ds.cc
libauth_la_SOURCES += query.h query.cc
TESTS =
if HAVE_GTEST
TESTS += run_unittests
run_unittests_SOURCES = run_unittests.cc
run_unittests_SOURCES += unittest_util.h unittest_util.cc
run_unittests_SOURCES += unittest_ds.h unittest_ds.cc
run_unittests_SOURCES += datasrc_unittest.cc
run_unittests_SOURCES += data_source_sqlite3_unittest.cc
run_unittests_SOURCES += data_source_static_unittest.cc
run_unittests_CPPFLAGS = $(AM_CPPFLAGS) $(GTEST_INCLUDES)
run_unittests_LDFLAGS = $(AM_LDFLAGS) $(GTEST_LDFLAGS)
run_unittests_LDADD = $(GTEST_LDADD)
run_unittests_LDADD += $(SQLITE_LIBS)
run_unittests_LDADD += .libs/libauth.a
run_unittests_LDADD += $(top_builddir)/src/lib/dns/.libs/libdns.a
run_unittests_LDADD += $(top_builddir)/src/lib/cc/libcc.a
run_unittests_LDADD += $(top_builddir)/src/lib/exceptions/.libs/libexceptions.a
endif
noinst_PROGRAMS = $(TESTS)
......@@ -17,7 +17,7 @@
#include <string>
#include <sstream>
#include "data_source_sqlite3.h"
#include "sqlite3_ds.h"
#include <dns/rrttl.h>
#include <dns/rdata.h>
......@@ -420,7 +420,7 @@ Sqlite3DataSrc::checkAndSetupSchema(void) {
try {
loadVersion();
setupPreparedStatements();
cout << "Loaded existing schema" << endl;
// cout << "Loaded existing schema" << endl;
} catch(...) {
execSetupQuery("CREATE TABLE schema_version ("
"version INTEGER NOT NULL)");
......@@ -453,7 +453,7 @@ Sqlite3DataSrc::checkAndSetupSchema(void) {
execSetupQuery("CREATE INDEX nsec3_byhash ON nsec3 (hash)");
setupPreparedStatements();
cout << "Created new file and schema" << endl;
// cout << "Created new file and schema" << endl;
}
}
......
......@@ -23,7 +23,7 @@
#include <dns/rrttl.h>
#include "data_source.h"
#include "data_source_static.h"
#include "static_ds.h"
using namespace std;
using namespace isc::dns;
......
......@@ -31,9 +31,9 @@
#include <dns/rrttl.h>
#include <dns/rrtype.h>
#include "query.h"
#include <auth/query.h>
#include "unittest_util.h"
#include "unittest_ds.h"
#include "test_ds.h"
using isc::UnitTestUtil;
using namespace std;
......
......@@ -31,9 +31,9 @@
#include <dns/rrsetlist.h>
#include <cc/data.h>
#include "query.h"
#include "data_source.h"
#include "data_source_sqlite3.h"
#include <auth/query.h>
#include <auth/data_source.h>
#include <auth/sqlite3_ds.h>
using namespace std;
using namespace isc::dns;
......
......@@ -29,9 +29,9 @@
#include <dns/rrsetlist.h>
#include <cc/data.h>
#include "query.h"
#include "data_source.h"
#include "data_source_static.h"
#include <auth/query.h>
#include <auth/data_source.h>
#include <auth/static_ds.h>
using namespace std;
using namespace isc::dns;
......
......@@ -17,8 +17,9 @@
#include <cassert>
#include "unittest_util.h"
#include "unittest_ds.h"
#include "data_source.h"
#include "test_ds.h"
#include <auth/data_source.h>
#include <dns/buffer.h>
#include <dns/messagerenderer.h>
......
......@@ -19,7 +19,7 @@
#include <gtest/gtest.h>
#include "data_source.h"
#include <auth/data_source.h>
namespace isc {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment