Age | Commit message (Collapse) | Author | Files | Lines |
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Makes it a bit easier to read.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
The path of the pid file is /run/llmnrd/pid by default but can be
changed via the PIDFILE make variable.
Fixes #18
Signed-off-by: Diego Santa Cruz <Diego.SantaCruz@spinetix.com>
|
|
When llmnrd daemonizes stdout and stderr are redirected to /dev/null
and all logs are lost. This adds a cli option -s / --syslog to send
the logs to syslog instead.
Signed-off-by: Diego Santa Cruz <Diego.SantaCruz@spinetix.com>
|
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
As a side effect of commit 21b5fc75be0a ("Makefile: assign CC
conditionally") which came in via PR #24, the CROSS_COMPILE make
variable is no longer taken into account because CC is always defined by
make itself.
Instead of working around this with dirty hacks, just suggest setting
CC to the corresponding cross-compiler.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Only assign CC if its not yet defined.
The Yocto SDK sets CC as an env variable, including --sysroot and various
other parameters. This change fixes the Makefile for using with Yocto SDK.
|
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Enable -Wextra, sort warning flags in CFLAGS_WARN alphabetically to
avoid adding duplicates.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
gzip and install the manpages for llmnrd and llmnr-query in the
Makefile's 'install' target.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Enable some sensible GCC warnings for default build. The list of flags
was based on the flags from the nftables source.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Instead of spawming a thread for the sole purpose of watching the rtnl
for (presumably) seldom events, just merge the select() for all sockets
together in one single main loop.
This reduces unnecessary complexity and makes llmnrd no longer require
any locking.
It also allows us to handle signals in a thread-safe manner (as there
aren't any ;) and thus the race condition on exit reported in #20
Closes #20
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Distribution build scripts commonly assume the CPPFLAGS, CFLAGS and
LDFLAGS passed via command line or environment to be appended to the
base set of flags defined in the Makefile. Follow this assumption
instead of overriding the already defined values.
Also treat these three variables entriely independently instead of
appending CPPFLAGS to CFLAGS.
Reported-by: @pali
Really-fixes: #17
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Avoid echoing the CC/LD string in verbose mode, just show the plain
commands:
$ make Q=
gcc -W -Wall -DVERSION_STRING=\"v0.2.1\" -DGIT_VERSION=\""(git id v0.2.1-6-gab7cd2fc9043)"\" -O2 -o llmnr.o -c llmnr.c
gcc -W -Wall -DVERSION_STRING=\"v0.2.1\" -DGIT_VERSION=\""(git id v0.2.1-6-gab7cd2fc9043)"\" -O2 -o iface.o -c iface.c
gcc -W -Wall -DVERSION_STRING=\"v0.2.1\" -DGIT_VERSION=\""(git id v0.2.1-6-gab7cd2fc9043)"\" -O2 -o socket.o -c socket.c
gcc -W -Wall -DVERSION_STRING=\"v0.2.1\" -DGIT_VERSION=\""(git id v0.2.1-6-gab7cd2fc9043)"\" -O2 -o util.o -c util.c
gcc -W -Wall -DVERSION_STRING=\"v0.2.1\" -DGIT_VERSION=\""(git id v0.2.1-6-gab7cd2fc9043)"\" -O2 -o llmnrd.o -c llmnrd.c
gcc -o llmnrd llmnr.o iface.o socket.o util.o llmnrd.o -lpthread
gcc -W -Wall -DVERSION_STRING=\"v0.2.1\" -DGIT_VERSION=\""(git id v0.2.1-6-gab7cd2fc9043)"\" -O2 -o llmnr-query.o -c llmnr-query.c
gcc -o llmnr-query util.o llmnr-query.o
Also consider $(Q) for the clean and install targets.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Currently Makefile ignores CPPFLAGS and so any defines passed via
environment/command line ignored. E.g. running
make CPPFLAGS="-D_FORTIFY_SOURCE=2"
does not compile llmnrd with buffer overflow checks.
Fix it by considering CPPFLAGS in the Makefile and appending them to
CFLAGS.
Closes #17
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Bugfix release to create source packages without debian packaging
information.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Add a release target to the Makefile (akin to the one from netsniff-ng)
in order to streamline the release process.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
|
|
|