Send kea-dev mailing list submissions to
[email protected]
To subscribe or unsubscribe via the World Wide Web, visit
https://lists.isc.org/mailman/listinfo/kea-dev
or, via email, send a message with subject or body 'help' to
[email protected]
You can reach the person managing the list at
[email protected]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of kea-dev digest..."
Today's Topics:
1. OpenBSD: Kea 1.2.0 (Patrik Lundin)
----------------------------------------------------------------------
Message: 1
Date: Mon, 3 Jul 2017 21:05:22 +0200
From: Patrik Lundin <[email protected]>
To: [email protected]
Subject: [kea-dev] OpenBSD: Kea 1.2.0
Message-ID: <[email protected]>
Content-Type: text/plain; charset=us-ascii
Hello,
As mentioned in
https://lists.isc.org/pipermail/kea-users/2017-July/001050.html I am
currently updating the Kea port in OpenBSD to 1.2.0.
First of all I notice that while the majority of the shared libraries
have an explicit version configured using the "-version-info" flag in
the Makefiles, there are a few that do not:
===
kea-asiodns (src/lib/asiodns/Makefile.am)
kea-exceptions (src/lib/exceptions/Makefile.am)
kea-util-io (src/lib/util/io/Makefile.am)
===
Is there a reason for this or is it just an oversight? In general it
seems the other ones have settings along these lines:
===
libkea_cfgclient_la_LDFLAGS = -no-undefined -version-info 3:0:0
===
The reason I ask about this is that port Makefiles in OpenBSD keep track
of SHARED_LIBS version numbers. It helps me out a lot when there is clear
indication that a library version needs to be bumped because of changes by
upstream.
I also noticed one of the version numbers went backwards in 1.2.0 in
comparision to 1.1.0. kea-dns++ went from 2.0 to 1.1. It can be seen in
src/lib/dns/Makefile.am, git commit 88d32454640a1f5f80fc4cd75339647be0210426.
Was this a mistake or am I missing something?
As Mike noted in the above mentioned thread Kea 1.2.0 requires a more
modern compiler and because of that I am using clang. The build fails in
the following way without patches:
===
c++ --std=c++11 -DHAVE_CONFIG_H -I. -I../../.. -I../../../src/lib
-I../../../src/lib -I/usr/local/include -DOS_BSD -DBOOST_DISABLE_THREADS=1
-I../../../ext/coroutine -DBOOST_ASIO_HEADER_ONLY
-DBOOST_ASIO_DISABLE_THREADS=1 -Qunused-arguments -Wall -Wextra
-Wnon-virtual-dtor -Wwrite-strings -Woverloaded-virtual -Wno-sign-compare
-pthread -Wno-missing-field-initializers -Wno-unused-variable
-Wno-unused-parameter -fPIC -O2 -pipe -MT watch_socket.lo -MD -MP -MF
.deps/watch_socket.Tpo -c watch_socket.cc -fPIC -DPIC -o .libs/watch_socket.o
watch_socket.cc:29:9: error: use of undeclared identifier 'pipe'
if (pipe(fds)) {
^
watch_socket.cc:72:22: error: use of undeclared identifier 'write'
int nbytes = write (source_, &MARKER, sizeof(MARKER));
^
watch_socket.cc:111:22: error: use of undeclared identifier 'read'
int nbytes = read (sink_, &buf, sizeof(buf));
^
watch_socket.cc:133:13: error: use of undeclared identifier 'close'
if (close(source_)) {
^
watch_socket.cc:142:13: error: use of undeclared identifier 'close'
if (close(sink_)) {
^
5 errors generated.
Error while executing c++ --std=c++11 -DHAVE_CONFIG_H -I. -I../../..
-I../../../src/lib -I../../../src/lib -I/usr/local/include -DOS_BSD
-DBOOST_DISABLE_THREADS=1 -I../../../ext/coroutine -DBOOST_ASIO_HEADER_ONLY
-DBOOST_ASIO_DISABLE_THREADS=1 -Qunused-arguments -Wall -Wextra
-Wnon-virtual-dtor -Wwrite-strings -Woverloaded-virtual -Wno-sign-compare
-pthread -Wno-missing-field-initializers -Wno-unused-variable
-Wno-unused-parameter -fPIC -O2 -pipe -MT watch_socket.lo -MD -MP -MF
.deps/watch_socket.Tpo -c watch_socket.cc -fPIC -DPIC -o .libs/watch_socket.o
*** Error 1 in src/lib/util (Makefile:617 'watch_socket.lo')
*** Error 1 in src/lib/util (Makefile:683 'all-recursive')
*** Error 1 in src/lib (Makefile:431 'all-recursive')
*** Error 1 in src (Makefile:432 'all-recursive')
*** Error 1 in . (Makefile:600 'all-recursive')
*** Error 1 in /home/ports/pobj/kea-1.2.0/kea-1.2.0 (Makefile:441 'all')
*** Error 1 in . (/usr/ports/infrastructure/mk/bsd.port.mk:2695
'/usr/ports/pobj/kea-1.2.0/.build_done')
*** Error 1 in /usr/ports/net/kea
(/usr/ports/infrastructure/mk/bsd.port.mk:2398 'build')
===
This was fixed by Marc Espie (espie@) prior to me starting to look at
1.2.0 here:
http://cvsweb.openbsd.org/cgi-bin/cvsweb/ports/net/kea/patches/patch-src_lib_util_watch_socket_cc
I'm thinking it is a good candidate for being merged upstream.
I also noticed that while a ticket i previously filed
(https://kea.isc.org/ticket/5072) has been solved, and the lfc-interval
has been added to a bunch of places in the repo, it has not been added
to the src/bin/keactrl/kea.conf.pre file which ends up as the default
kea.conf. Is this intentional? I also notice "persist" is not configured
by default, even if this seems to be strongly encouraged in the
documentation.
Finally, here are the warnings thrown by the build. I'm guessing none of
them are critical, so I am mostly mentioning them here for completeness
(I have done this before as well):
===
.libs/libkea-asiolink.so.2.0: warning: warning: strcat() is almost always
misused, please use strlcat()
.libs/libkea-asiolink.so.2.0: warning: warning: sprintf() is often misused,
please use snprintf()
.libs/libkea-dhcp++.so.2.0: warning: warning: random() may return deterministic
values, is that what you want?
.libs/libkea-asiolink.so.2.0: warning: warning: strcat() is almost always
misused, please use strlcat()
.libs/libkea-asiolink.so.2.0: warning: warning: sprintf() is often misused,
please use snprintf()
.libs/libkea-dhcp++.so.2.0: warning: warning: random() may return deterministic
values, is that what you want?
.libs/libkea-asiolink.so.2.0: warning: warning: strcat() is almost always
misused, please use strlcat()
.libs/libkea-asiolink.so.2.0: warning: warning: sprintf() is often misused,
please use snprintf()
.libs/libkea-dhcp++.so.2.0: warning: warning: random() may return deterministic
values, is that what you want?
.libs/libkea-asiolink.so.2.0: warning: warning: strcat() is almost always
misused, please use strlcat()
.libs/libkea-asiolink.so.2.0: warning: warning: sprintf() is often misused,
please use snprintf()
.libs/libkea-dhcp++.so.2.0: warning: warning: random() may return deterministic
values, is that what you want?
test_control.cc:(.text._ZN3isc8perfdhcp13PacketStorageINS_4dhcp4Pkt4EE9getRandomEv[_ZN3isc8perfdhcp13PacketStorageINS_4dhcp4Pkt4EE9getRandomEv]+0x45):
warning: warning: rand() may return deterministic values, is that what you
want?
.libs/libkea-asiolink.so.2.0: warning: warning: strcat() is almost always
misused, please use strlcat()
.libs/libkea-asiolink.so.2.0: warning: warning: sprintf() is often misused,
please use snprintf()
.libs/libkea-dhcp++.so.2.0: warning: warning: random() may return deterministic
values, is that what you want?
.libs/libkea-asiolink.so.2.0: warning: warning: strcat() is almost always
misused, please use strlcat()
.libs/libkea-asiolink.so.2.0: warning: warning: sprintf() is often misused,
please use snprintf()
.libs/libkea-dhcp++.so.2.0: warning: warning: random() may return deterministic
values, is that what you want?
===
--
Patrik Lundin
------------------------------
Subject: Digest Footer
_______________________________________________
kea-dev mailing list
[email protected]
https://lists.isc.org/mailman/listinfo/kea-dev
------------------------------
End of kea-dev Digest, Vol 40, Issue 1
**************************************