* the contents of INCLUDES and DEFINES should now be placed into CPPFLAGS
[olsrd.git] / make / Makefile.fbsd
1 #
2 # FREEBSD SPECIFIC CONFIGURATION
3 #
4
5 DESTDIR ?= /usr/local
6 SBINDIR = $(DESTDIR)/sbin
7 ETCDIR = $(DESTDIR)/etc
8 LIBDIR = $(DESTDIR)/lib
9 DOCDIR = $(DESTDIR)/share/doc
10 MANDIR = $(DESTDIR)/man
11
12 SRCS +=         $(wildcard src/bsd/*.c) $(wildcard src/unix/*.c)
13 HDRS +=         $(wildcard src/bsd/*.h) $(wildcard src/unix/*.h)
14
15 LIBS =
16
17 CPPFLAGS +=     -DOLSRD_GLOBAL_CONF_FILE=\"$(CFGFILE)\"
18
19 ifdef NO_80211
20 CPPFLAGS +=     -DFBSD_NO_80211=1
21 endif
22
23 ifdef LIBNET
24
25 CPPFLAGS +=     -DSPOOF -I$(DESTDIR)/include
26 LIBS +=         -L$(DESTDIR)/lib -lnet
27
28 endif
29
30 ifdef OLSRD_PLUGIN
31 CFLAGS +=       -fPIC
32 LDFLAGS +=      -fPIC
33 endif
34
35 PLUGIN_FULLNAME ?= $(PLUGIN_NAME).so.$(PLUGIN_VER)
36 INSTALL_LIB =   install -m 755 $(PLUGIN_FULLNAME) $(LIBDIR)/$(PLUGIN_FULLNAME); \
37                 /sbin/ldconfig
38
39 OS_LIB_PTHREAD = -pthread
40 OS_LIB_DYNLOAD =
41
42 # Local Variables:
43 # mode: makefile
44 # End: