Commit d7ddee57 authored by Marek Vavruša's avatar Marek Vavruša

build: renamed libkresolve => libkres, kresolved => kresd

also some cleanup and version bump to Q2
parent 16b6dab1
......@@ -40,7 +40,7 @@ tmp*
/ylwrap
/doc/doxyxml
/doc/html
/daemon/kresolved
/daemon/kresd
/tests/test_array
/tests/test_map
/tests/test_module
......
......@@ -35,8 +35,8 @@ See the [Building project][depends] documentation page for more information.
The project builds a resolver library in the `lib` directory, and a daemon in the `daemon` directory.
```
$ ./daemon/kresolved -h
$ ./daemon/kresolved [working_directory]
$ ./daemon/kresd -h
$ ./daemon/kresd [working_directory]
```
See the documentation at [knot-resolver.readthedocs.org][doc].
......
# Project
MAJOR := 15
MINOR := 04
MINOR := 07
PATCH := 0
# Paths
......
......@@ -16,7 +16,7 @@ the `daemon` directory.
.. code-block:: bash
$ ./daemon/kresolved -h
$ ./daemon/kresd -h
Interacting with the daemon
---------------------------
......@@ -26,7 +26,7 @@ You can load modules this way and use their properties to get information about
.. code-block:: bash
$ kresolved /var/run/knot-resolver
$ kresd /var/run/knot-resolver
[system] started in interactive mode, type 'help()'
> cache.count()
53
......@@ -47,7 +47,7 @@ comfortable in the current working directory.
.. code-block:: sh
$ kresolved /var/run/kresolved
$ kresd /var/run/kresd
And you're good to go for most use cases! If you want to use modules or configure daemon behavior, read on.
......
kresolved_EMBED := \
kresd_EMBED := \
contrib/ccan/json/json.c
kresolved_SOURCES := \
$(kresolved_EMBED) \
kresd_SOURCES := \
$(kresd_EMBED) \
daemon/io.c \
daemon/network.c \
daemon/engine.c \
......@@ -16,18 +16,18 @@ daemon/engine.o: daemon/lua/sandbox.inc daemon/lua/config.inc
@$(call quiet,XXD,$<) $< > $@
# Dependencies
kresolved_DEPEND := $(libkresolve)
kresolved_LIBS := $(libkresolve_TARGET) $(libknot_LIBS) $(libuv_LIBS) $(lua_LIBS)
kresd_DEPEND := $(libkres)
kresd_LIBS := $(libkres_TARGET) $(libknot_LIBS) $(libuv_LIBS) $(lua_LIBS)
# Make binary
ifeq ($(HAS_lua)|$(HAS_libuv), yes|yes)
$(eval $(call make_bin,kresolved,daemon))
$(eval $(call make_bin,kresd,daemon))
endif
# Targets
daemon: $(kresolved)
daemon-install: kresolved-install
daemon-clean: kresolved-clean
daemon: $(kresd)
daemon-install: kresd-install
daemon-clean: kresd-clean
@$(RM) daemon/lua/*.inc
.PHONY: daemon daemon-install daemon-clean
......@@ -11,8 +11,8 @@ if os.environ.get('READTHEDOCS', None) == 'True':
extensions = ['sphinx.ext.todo', 'sphinx.ext.viewcode', 'breathe']
# Breathe configuration
breathe_projects = { "libkresolve": "doxyxml" }
breathe_default_project = "libkresolve"
breathe_projects = { "libkres": "doxyxml" }
breathe_default_project = "libkres"
breathe_domain_by_extension = {"h" : "c"}
# The suffix of source filenames.
......@@ -66,7 +66,7 @@ latex_documents = [
# One entry per manual page. List of tuples
# (source start file, name, description, authors, manual section).
man_pages = [
('index', 'libkresolve', u'libkresolve documentation',
('index', 'libkres', u'libkres documentation',
[u'CZ.NIC Labs'], 1)
]
......@@ -15,9 +15,9 @@ Name resolution
---------------
.. doxygenfile:: resolve.h
:project: libkresolve
:project: libkres
.. doxygenfile:: rplan.h
:project: libkresolve
:project: libkres
.. _lib_api_cache:
......@@ -25,7 +25,7 @@ Cache
-----
.. doxygenfile:: cache.h
:project: libkresolve
:project: libkres
.. _lib_api_nameservers:
......@@ -33,9 +33,9 @@ Nameservers
-----------
.. doxygenfile:: nsrep.h
:project: libkresolve
:project: libkres
.. doxygenfile:: zonecut.h
:project: libkresolve
:project: libkres
.. _lib_api_modules:
......@@ -43,15 +43,15 @@ Modules
-------
.. doxygenfile:: module.h
:project: libkresolve
:project: libkres
Utilities
---------
.. doxygenfile:: utils.h
:project: libkresolve
:project: libkres
.. doxygenfile:: defines.h
:project: libkresolve
:project: libkres
.. _lib_generics:
......
......@@ -16,30 +16,30 @@ array
~~~~~
.. doxygenfile:: array.h
:project: libkresolve
:project: libkres
map
~~~
.. doxygenfile:: map.h
:project: libkresolve
:project: libkres
set
~~~
.. doxygenfile:: set.h
:project: libkresolve
:project: libkres
pack
~~~~
.. doxygenfile:: pack.h
:project: libkresolve
:project: libkres
lru
~~~
.. doxygenfile:: lru.h
:project: libkresolve
:project: libkres
.. _`Crit-bit tree`: http://cr.yp.to/critbit.html
......@@ -3,7 +3,7 @@ ccan_EMBED := \
contrib/ccan/isaac/isaac.c \
contrib/murmurhash3/murmurhash3.c
libkresolve_SOURCES := \
libkres_SOURCES := \
$(ccan_EMBED) \
lib/generic/map.c \
lib/layer/iterate.c \
......@@ -17,7 +17,7 @@ libkresolve_SOURCES := \
lib/rplan.c \
lib/cache.c
libkresolve_HEADERS := \
libkres_HEADERS := \
lib/generic/array.h \
lib/generic/map.h \
lib/generic/set.h \
......@@ -31,16 +31,16 @@ libkresolve_HEADERS := \
lib/cache.h
# Dependencies
libkresolve_DEPEND :=
libkresolve_LIBS := $(libknot_LIBS)
libkresolve_TARGET := -Wl,-rpath,lib -Llib -lkresolve
libkres_DEPEND :=
libkres_LIBS := $(libknot_LIBS)
libkres_TARGET := -Wl,-rpath,lib -Llib -lkres
# Make library
$(eval $(call make_static,libkresolve,lib))
$(eval $(call make_static,libkres,lib))
# Targets
lib: $(libkresolve)
lib-install: libkresolve-install
lib-clean: libkresolve-clean
lib: $(libkres)
lib-install: libkres-install
lib-clean: libkres-clean
.PHONY: lib lib-install lib-clean
......@@ -314,7 +314,7 @@ Once you load the module, you can call the module property from the interactive
.. code-block:: bash
$ kresolved
$ kresd
...
[system] started in interactive mode, type 'help()'
> modules.load('cached')
......
cachectl_SOURCES := modules/cachectl/cachectl.c
cachectl_DEPEND := $(libkresolve)
cachectl_LIBS := $(libkresolve_TARGET) $(libkresolve_LIBS)
cachectl_DEPEND := $(libkres)
cachectl_LIBS := $(libkres_TARGET) $(libkres_LIBS)
$(call make_c_module,cachectl)
\ No newline at end of file
gostats_SOURCES := modules/gostats/gostats.go
gostats_DEPEND := $(libkresolve)
gostats_LIBS := $(libkresolve_TARGET) $(libkresolve_LIBS)
gostats_DEPEND := $(libkres)
gostats_LIBS := $(libkres_TARGET) $(libkres_LIBS)
$(call make_go_module,gostats)
\ No newline at end of file
hints_SOURCES := modules/hints/hints.c contrib/ccan/json/json.c
hints_DEPEND := $(libkresolve)
hints_LIBS := $(libkresolve_TARGET) $(libkresolve_LIBS)
hints_DEPEND := $(libkres)
hints_LIBS := $(libkres_TARGET) $(libkres_LIBS)
$(call make_c_module,hints)
\ No newline at end of file
......@@ -4,16 +4,16 @@ Etcd module
-----------
The module connects to Etcd peers and watches for configuration change.
By default, the module looks for the subtree under ``/kresolved`` directory,
By default, the module looks for the subtree under ``/kresd`` directory,
but you can change this `in the configuration <https://github.com/mah0x211/lua-etcd#cli-err--etcdnew-optiontable->`_.
The subtree structure corresponds to the configuration variables in the declarative style.
.. code-block:: bash
$ etcdctl set /kresolved/net/127.0.0.1 53
$ etcdctl set /kresolved/modules/cachectl true
$ etcdctl set /kresolved/cache/size 10000000
$ etcdctl set /kresd/net/127.0.0.1 53
$ etcdctl set /kresd/modules/cachectl true
$ etcdctl set /kresd/cache/size 10000000
Configures all listening nodes to following configuration:
......@@ -30,7 +30,7 @@ Example configuration
modules = {
ketcd = {
prefix = '/kresolved',
prefix = '/kresd',
peer = 'http://127.0.0.1:7001'
}
}
......
......@@ -28,7 +28,7 @@ end
function ketcd.init(module)
ketcd.Etcd = require('etcd.luasocket')
ketcd.defaults = { prefix = '/kresolved' }
ketcd.defaults = { prefix = '/kresd' }
end
function ketcd.deinit(module)
......
kmemcached_SOURCES := modules/kmemcached/kmemcached.c modules/kmemcached/namedb_memcached.c
kmemcached_LIBS := $(libkresolve_TARGET) $(libkresolve_LIBS) $(libmemcached_LIBS)
kmemcached_LIBS := $(libkres_TARGET) $(libkres_LIBS) $(libmemcached_LIBS)
$(call make_c_module,kmemcached)
stats_SOURCES := modules/stats/stats.c contrib/ccan/json/json.c
stats_DEPEND := $(libkresolve)
stats_LIBS := $(libkresolve_TARGET) $(libkresolve_LIBS)
stats_DEPEND := $(libkres)
stats_LIBS := $(libkres_TARGET) $(libkres_LIBS)
$(call make_c_module,stats)
......@@ -14,7 +14,7 @@ EXPOSE 53
# Select entrypoint
WORKDIR /data
CMD ["/usr/local/bin/kresolved"]
CMD ["/usr/local/bin/kresd"]
# Install dependencies and sources
RUN \
......
......@@ -5,7 +5,7 @@
# Mocked calls library
libmock_calls_SOURCES := tests/mock_calls.c
libmock_calls_LIBS := $(tests_LIBS) $(python_LIBS)
libmock_calls_DEPEND := $(libkresolve)
libmock_calls_DEPEND := $(libkres)
$(eval $(call make_lib,libmock_calls,tests))
# Python module for tests
......
......@@ -21,8 +21,8 @@ mock_gomodule_SOURCES := tests/mock_gomodule.c
$(eval $(call make_lib,mock_gomodule,tests))
# Dependencies
tests_DEPEND := $(libkresolve) $(mock_cmodule) $(mock_gomodule)
tests_LIBS := $(libkresolve_TARGET) $(libkresolve_LIBS) $(cmocka_LIBS)
tests_DEPEND := $(libkres) $(mock_cmodule) $(mock_gomodule)
tests_LIBS := $(libkres_TARGET) $(libkres_LIBS) $(cmocka_LIBS)
# Make test binaries
define make_test
......
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