forked from Netgear/wsdd2
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
41 lines (34 loc) · 926 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#
# Makefile for wsdd2 WSD/LLMNR server
#
# Copyright (c) 2016 NETGEAR
# Copyright (c) 2016 Hiro Sugawara
#
include ../common.mak
CFLAGS ?= -Wall -Wextra -g -O0
LDFLAGS ?= -g
OBJFILES = wsdd2.o wsd.o llmnr.o
ifeq ($(RTCONFIG_BCMARM),y)
ifneq ($(HND_ROUTER),y)
OBJFILES += ifaddrs.o
endif
endif
HEADERS = wsdd.h wsd.h
PREFIX ?= /usr
SBINDIR ?= $(PREFIX)/sbin
MANDIR ?= $(PREFIX)/share/man
LIBDIR ?= $(PREFIX)/lib
all: wsdd2
nl_debug: CPPFLAGS+=-DMAIN
nl_debug: nl_debug.c; $(LINK.c) $^ $(LOADLIBES) $(LDLIBS) -o $@
wsdd2: $(OBJFILES)
$(OBJFILES): $(HEADERS) Makefile
install: wsdd2
install -d $(DESTDIR)$(SBINDIR)
install wsdd2 $(DESTDIR)$(SBINDIR)
install -d $(DESTDIR)$(MANDIR)/man8
install -m 0644 wsdd2.8 $(DESTDIR)$(MANDIR)/man8
install -d $(DESTDIR)$(LIBDIR)/systemd/system
install -m 0644 wsdd2.service $(DESTDIR)$(LIBDIR)/systemd/system
clean:
rm -f wsdd2 nl_debug $(OBJFILES)