X-Git-Url: https://git.rohieb.name/openwrt.git/blobdiff_plain/56d71638dbf48b8e4885e1e5ed5d0f1859674541..91c9f2c7d5206d28039256d9e5edd221035f8d35:/package/uhttpd/src/Makefile diff --git a/package/uhttpd/src/Makefile b/package/uhttpd/src/Makefile index 06d61bdef..6dcc3555f 100644 --- a/package/uhttpd/src/Makefile +++ b/package/uhttpd/src/Makefile @@ -13,6 +13,12 @@ LIB = -Wl,--export-dynamic -lcrypt -ldl TLSLIB = LUALIB = +HAVE_SHADOW=$(shell echo 'int main(void){ return !getspnam("root"); }' | \ + $(CC) -include shadow.h -xc -o/dev/null - 2>/dev/null && echo yes) + +ifeq ($(HAVE_SHADOW),yes) + CFLAGS += -DHAVE_SHADOW +endif world: compile