Reduce differences with root_skels in contrib.
[dragonfly.git] / contrib / bsdinstaller-1.1.6 / src / lib / lua / dfui / Makefile
1 # Makefile for luadfui.
2 # $Id: Makefile,v 1.6 2005/04/05 20:53:46 cpressey Exp $
3
4 OSTYPE!=sysctl -n kern.ostype
5
6 COMPAT?=/usr/local/lib/lua/compat-5.1r2
7
8 LIB=    ldfui.so
9 OBJS=   common.o dfui.o progress.o compat-5.1.o
10
11 WARNS=  -W -Werror -Wall -Wstrict-prototypes -Wmissing-prototypes \
12         -Wpointer-arith -Wno-uninitialized -Wreturn-type -Wcast-qual \
13         -Wwrite-strings -Wswitch -Wshadow -Wcast-align -Wchar-subscripts \
14         -Winline -Wnested-externs -Wredundant-decls
15
16 CFLAGS+=${WARNS}
17 .ifdef DEBUG
18 CFLAGS+= -DDEBUG -g 
19 .endif
20 CFLAGS+=-I/usr/local/include -I${COMPAT}
21
22 .if ${OSTYPE} == "NetBSD"
23 CFLAGS+=-I/usr/pkg/include
24 LDADD+= -L/usr/pkg/lib
25 .endif
26
27 LDADD+= -L/usr/local/lib/ -ldfui -laura -lm -llua50 -llualib50
28
29 all: ${LIB}
30
31 # XXX build and link to dependencies here
32 in_cvs: all
33
34 ${LIB}: ${OBJS}
35         ${CC} ${CFLAGS} ${OBJS} -static ${LDADD} -shared -o ${LIB}
36
37 compat-5.1.o: ${COMPAT}/compat-5.1.c
38         ${CC} ${CFLAGS} -c ${COMPAT}/compat-5.1.c
39
40 clean:
41         rm -f *.o *.so