Kea fails to start with log4cplus compiled without implicit initialization
Describe the bug
Log4cplus introduced new build option to disable implicit initialization during startup in 2.0.4 (https://sourceforge.net/p/log4cplus/news/2019/04/v204/):
--disable-implicit-initialization
With this option enabled Kea's binaries won't start:
# ./kea-dhcp4 -c /etc/kea/kea-dhcp4.conf
kea-dhcp4: Fatal error during start up: log4cplus is not initialized and implicit initialization is turned off
Particularly latest log4cplus package in Alpine Linux is compiled with this option. As a result one can't use Kea with Alpine without building it from sources (https://bugs.alpinelinux.org/issues/10480).
To Reproduce
Steps to reproduce the behavior:
- Configure and build log4cplus version 2.0.4 with
--disable-implicit-initialization
option; - Build Kea using that log4cplus library;
- Try to start Kea server
# ./kea-dhcp4 -c /etc/kea/kea-dhcp4.conf
kea-dhcp4: Fatal error during start up: log4cplus is not initialized and implicit initialization is turned off
Expected behavior
# ./kea-dhcp4 -c /etc/kea/kea-dhcp4.conf
INFO [kea-dhcp4.dhcp4/14122] DHCP4_STARTING Kea DHCPv4 server version 1.5.0-git starting
Environment:
- Kea version: 1.5.0;
- OS: Any;
- Log4cplus with --disable-implicit-initialization;
Describe the solution you'd like
Explicitly initialize log4cplus in Kea.