]> git.ipfire.org Git - thirdparty/kea.git/commitdiff
[trac2361] fix issue where the bind10 could not run in source tree
authorJeremy C. Reed <jreed@ISC.org>
Fri, 19 Oct 2012 15:14:44 +0000 (10:14 -0500)
committerJeremy C. Reed <jreed@ISC.org>
Fri, 19 Oct 2012 15:14:44 +0000 (10:14 -0500)
when the installation was not done yet.

I added extra local_plugins path and custom datasrc.spec plugin for that.

configure.ac
src/bin/cfgmgr/Makefile.am
src/bin/cfgmgr/local_plugins/Makefile.am [new file with mode: 0644]
src/bin/cfgmgr/plugins/Makefile.am
src/bin/cfgmgr/plugins/datasrc.spec.pre.in
src/lib/python/bind10_config.py.in
tests/lettuce/configurations/auth/.gitignore [new file with mode: 0644]

index 09de67fd2b05920457d9be3bae78557a4c331729..32f81b320f40ca2012800203f5be1855788f7e6b 100644 (file)
@@ -1112,6 +1112,7 @@ AC_CONFIG_FILES([Makefile
                  src/bin/bindctl/Makefile
                  src/bin/bindctl/tests/Makefile
                  src/bin/cfgmgr/Makefile
+                 src/bin/cfgmgr/local_plugins/Makefile
                  src/bin/cfgmgr/plugins/Makefile
                  src/bin/cfgmgr/plugins/tests/Makefile
                  src/bin/cfgmgr/tests/Makefile
index e9e0ccaf856d9e176f478b8f6aa99e77690f246b..9c73f79ee666943ecefbeca86b62f6f0e2260774 100644 (file)
@@ -1,4 +1,4 @@
-SUBDIRS = . plugins tests
+SUBDIRS = . plugins local_plugins tests
 
 pkglibexecdir = $(libexecdir)/@PACKAGE@
 
diff --git a/src/bin/cfgmgr/local_plugins/Makefile.am b/src/bin/cfgmgr/local_plugins/Makefile.am
new file mode 100644 (file)
index 0000000..63e152d
--- /dev/null
@@ -0,0 +1,10 @@
+# Nothing is installed from this directory.
+# This local_plugins directory is to override plugins when used from running
+# within source tree for testing (instead of installation prefix).
+
+noinst_DATA = datasrc.spec
+
+datasrc.spec: ../plugins/datasrc.spec.pre
+       $(SED) -e "s|@@STATIC_ZONE_FILE@@|$(abs_top_builddir)/src/lib/datasrc/static.zone|;s|@@SQLITE3_DATABASE_FILE@@|$(abs_top_builddir)/local.zone.sqlite3|" ../plugins/datasrc.spec.pre >$@
+
+CLEANFILES = datasrc.spec
index e6ed1275c814f8298fc7c9c0d676307aade9fa52..5967abd4ace5e1e4e7faca9ff167a19b53bf9dd5 100644 (file)
@@ -3,7 +3,7 @@ SUBDIRS = tests
 EXTRA_DIST = README logging.spec tsig_keys.spec
 
 datasrc.spec: datasrc.spec.pre
-       $(SED) -e "s|@@PKGDATADIR@@|$(pkgdatadir)|;s|@@LOCALSTATEDIR@@|$(localstatedir)|" datasrc.spec.pre >$@
+       $(SED) -e "s|@@STATIC_ZONE_FILE@@|$(pkgdatadir)/static.zone|;s|@@SQLITE3_DATABASE_FILE@@|$(localstatedir)/$(PACKAGE)/zone.sqlite3|" datasrc.spec.pre >$@
 
 config_plugindir = @prefix@/share/@PACKAGE@/config_plugins
 config_plugin_DATA = logging.spec tsig_keys.spec datasrc.spec
index f2c6a974a2d52e0241ab9178239bdaf294b1b0af..6d5bd77e7510608c988dd823e91bfe0049f6cbd5 100644 (file)
@@ -12,7 +12,7 @@
                         {
                             "type": "sqlite3",
                             "params": {
-                                "database_file": "@@LOCALSTATEDIR@@/@PACKAGE@/zone.sqlite3"
+                                "database_file": "@@SQLITE3_DATABASE_FILE@@"
                             }
                         }
                     ],
@@ -20,7 +20,7 @@
                         {
                             "type": "static",
                             "cache-enable": false,
-                            "params": "@@PKGDATADIR@@/static.zone"
+                            "params": "@@STATIC_ZONE_FILE@@"
                         }
                     ]
                 },
index b8975cf625bf1b51099991e8d399cb3f286fb2cc..c765fa29a122f61fc27868b51e3104dae9eb513a 100644 (file)
@@ -60,6 +60,8 @@ def reload():
         else:
             DATA_PATH = os.environ["B10_FROM_SOURCE"]
         PLUGIN_PATHS = [os.environ["B10_FROM_SOURCE"] +
+                            '/src/bin/cfgmgr/local_plugins',
+                             os.environ["B10_FROM_SOURCE"] +
                             '/src/bin/cfgmgr/plugins']
         programdirs = ['auth', 'cfgmgr', 'cmdctl', 'ddns', 'dhcp6', 'msgq',
                        'resolver', 'sockcreator', 'stats', 'xfrin', 'xfrout',
diff --git a/tests/lettuce/configurations/auth/.gitignore b/tests/lettuce/configurations/auth/.gitignore
new file mode 100644 (file)
index 0000000..07f1b7d
--- /dev/null
@@ -0,0 +1 @@
+/auth_basic.config