Merge from waqas
[prosody.git] / util-src / Makefile
1
2 include ../config.unix
3
4 LUA_SUFFIX?=5.1
5 LUA_INCDIR?=/usr/include/lua$(LUA_SUFFIX)
6 LUA_LIB?=lua$(LUA_SUFFIX)
7 IDN_LIB?=idn
8 OPENSSL_LIB?=ssl
9
10
11
12 all: encodings.so hashes.so
13
14 install: encodings.so hashes.so
15         strip *.so
16         cp *.so ../util/
17         
18
19 clean:
20         rm -f *.so
21         rm -f ../util/*.so
22
23 encodings.so: encodings.c
24         gcc -shared -fPIC encodings.c -I$(LUA_INCDIR) -l$(LUA_LIB) -l$(IDN_LIB) -o encodings.so
25
26 hashes.so: hashes.c
27         gcc -shared -fPIC hashes.c -I$(LUA_INCDIR) -l$(LUA_LIB) -l$(OPENSSL_LIB) -o hashes.so
28