# Installation path options. SBINDIR=/sbin MANDIR=/usr/share/man SYSCONTROLSOCKET=/var/run/dinitctl # General build options. # FreeBSD: use clang++ by default, supports sanitizers, requires linking with -lrt # Cannot use LTO with default linker. CXX=clang++ CXXFLAGS=-std=c++11 -Os -Wall -fno-plt -fno-rtti CPPFLAGS= LDFLAGS_BASE=-lrt LDFLAGS=$(LDFLAGS_BASE) TEST_CXXFLAGS=$(CXXFLAGS) -fsanitize=address,undefined TEST_LDFLAGS_BASE=$(LDFLAGS_BASE) TEST_LDFLAGS=$(TEST_LDFLAGS_BASE) BUILD_SHUTDOWN=no # Notes: # -fno-rtti (optional) : Dinit does not require C++ Run-time Type Information # -fno-plt (optional) : Recommended optimisation # -fsanitize=address,undefined : Apply sanitizers (during unit tests) # # Old versions of FreeBSD had issues with -fno-plt/-fno-rtti. # Service defaults. DEFAULT_AUTO_RESTART=true DEFAULT_START_TIMEOUT=60 DEFAULT_STOP_TIMEOUT=10