Installer import into contrib (real import this time)
[dragonfly.git] / contrib / bsdinstaller-1.1.6 / src / lib / lua / gettext / Makefile
1 # Makefile for luagettext.
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 OBJS=   lua_gettext.o compat-5.1.o
9
10 WARNS=  -W -Werror -Wall -Wstrict-prototypes -Wmissing-prototypes \
11         -Wpointer-arith -Wno-uninitialized -Wreturn-type -Wcast-qual \
12         -Wwrite-strings -Wswitch -Wshadow -Wcast-align -Wchar-subscripts \
13         -Winline -Wnested-externs -Wredundant-decls
14
15 CFLAGS+=${WARNS}
16 .ifdef DEBUG
17 CFLAGS+= -DDEBUG -g 
18 .endif
19 CFLAGS+=-I/usr/local/include -I${COMPAT}
20
21 .if ${OSTYPE} == "NetBSD"
22 CFLAGS+=-I/usr/pkg/include
23 LDADD+= -L/usr/pkg/lib
24 .endif
25
26 LDADD+= -L/usr/local/lib/ -lintl -lm -llua50 -llualib50
27
28 all: lgettext.so
29
30 in_cvs: all
31
32 lgettext.so: ${OBJS}
33         ${CC} ${CFLAGS} ${OBJS} -static ${LDADD} -shared -o lgettext.so
34
35 compat-5.1.o: ${COMPAT}/compat-5.1.c
36         ${CC} ${CFLAGS} -c ${COMPAT}/compat-5.1.c
37
38 clean:
39         rm -f *.o *.so