improve lua depedency detection

When make info is executed, the lua package is not searched for no.

$ make info
fatal: Not a git repository (or any of the parent directories): .git
Target:     Knot DNS Resolver 1.99.1-alpha-POSIX
Compiler:   cc  -std=c99 -D_GNU_SOURCE -Wno-unused -Wtype-limits -Wformat -Wformat-security -Wall -I/usr/local/src/knot-resolver-1.99.1-alpha -I/usr/local/src/knot-resolver-1.99.1-alpha/lib/generic -I/usr/local/src/knot-resolver-1.99.1-alpha/contrib -I/usr/local/src/knot-resolver-1.99.1-alpha/contrib/lmdb -DPACKAGE_VERSION="\"1.99.1-alpha\"" -DPREFIX="\"/usr/local\"" -DMODULEDIR="\"/usr/local/lib/kdns_modules\"" -O2 -D_FORTIFY_SOURCE=2 -I/usr/include/p11-kit-1    -I/usr/include/luajit-2.1 -I/usr/include/p11-kit-1  -Icontrib/ccan/compiler -Icontrib/ccan/ilog -Icontrib/ccan/isaac -Icontrib/ccan/json -Icontrib/ccan/asprintf -Icontrib/murmurhash3 -DENABLE_COOKIES

Variables
---------
HARDENING:  yes
BUILDMODE:  dynamic
PREFIX:     /usr/local
PREFIX:     /usr/local
DESTDIR:    
BINDIR:     /usr/local/bin
SBINDIR:    /usr/local/sbin
LIBDIR:     /usr/local/lib
ETCDIR:     /usr/local/etc/kresd
INCLUDEDIR: /usr/local/include
MODULEDIR:  /usr/local/lib/kdns_modules

Core Dependencies
------------
[yes] libknot (lib)
[yes] embedded lmdb (lib)
[yes] luajit (daemon)
[yes] libuv (daemon)
[yes] libgnutls (daemon)

Optional
--------
[no] doxygen (doc)
[no] sphinx-build (doc)
[no] python-breathe (doc)
[yes] go (modules/go, Go buildmode=c-shared support)
[no] libmemcached (modules/memcached)
[no] hiredis (modules/redis)
[yes] cmocka (tests/unit)
[yes] systemd (daemon)
[yes] nettle (modules/cookies)
[no] Lua socket ltn12 (trust anchor bootstrapping)
[no] Lua ssl.https (trust anchor bootstrapping)
[yes] libedit (client)
[no] libfstrm (modules/dnstap)
[no] libprotobuf-c (modules/dnstap)
[no] proto-c (modules/dnstap)

make: Nothing to be done for 'info'.

However, as you can see, the corresponding package has been introduced.

  • At least the command that can be executed in Shell should be lua.
$ dpkg -l | grep lua-s
ii  lua-sec:arm64                            0.5.1-1                                    arm64        SSL socket library for the Lua language
ii  lua-sec-dev:arm64                        0.5.1-1                                    arm64        SSL socket library library devel files for the Lua language
ii  lua-socket:arm64                         3.0~rc1+git+321c0c9-1                      arm64        TCP/UDP socket library for the Lua language
ii  lua-socket-dev:arm64                     3.0~rc1+git+321c0c9-1                      arm64        TCP/UDP socket library for the Lua language

When checking the file, is luajit on the corresponding line of platform.mk not lua?
https://gitlab.labs.nic.cz/knot/knot-resolver/blob/master/platform.mk#L186

It seems that it correctly reads as follows when corrected.

Optional
--------
[no] doxygen (doc)
[no] sphinx-build (doc)
[no] python-breathe (doc)
[yes] go (modules/go, Go buildmode=c-shared support)
[no] libmemcached (modules/memcached)
[no] hiredis (modules/redis)
[yes] cmocka (tests/unit)
[yes] systemd (daemon)
[yes] nettle (modules/cookies)
[yes] Lua socket ltn12 (trust anchor bootstrapping)
[yes] Lua ssl.https (trust anchor bootstrapping)
[yes] libedit (client)
[no] libfstrm (modules/dnstap)
[no] libprotobuf-c (modules/dnstap)
[no] proto-c (modules/dnstap)

Env:

  • knot-resolver-1.99.1-alpha
  • aarch64
  • Ubuntu-16.04.3

platform.mk.diff

Edited by Petr Špaček
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information