moved source files to src directory
[wmiirc-lua.git] / src / luaixp / Makefile
blob9004fd5b2373e651fe4a63fce4a68b055aeb93b4
1 TOP = ../..
2 CONFIG_MK = ${TOP}/config.mk
3 include ${CONFIG_MK}
5 SRCS = lixp_main.c lixp_debug.c lixp_util.c lixp_instance.c
6 OBJS = $(SRCS:.c=.o)
8 CFLAGS += ${LUA_INC} ${IXP_INC} -ggdb -O0 -fPIC
9 LIBS += ${LUA_LIB} ${IXP_LIB}
11 #CFLAGS += -DDBG
13 TARGET = ixp.so
15 .PHONY: all test clean install
16 all: ${TARGET}
18 ${TARGET}: ${OBJS}
19 $(CC) ${CFLAGS} -o $@ -shared $^ $(LIBS)
21 ${OBJS}: %.o: %.c Makefile
22 ${CC} ${CFLAGS} -o $@ -c $<
24 test: ${TARGET}
25 ./test.lua
27 clean:
28 -rm -f ${TARGET} ${OBJS}
29 -rm -f *.o *.so *~
31 install: ${TARGET}
32 ${INSTALL} -d ${CORE_LIB_DIR}
33 ${INSTALL} -b -t ${CORE_LIB_DIR} ${TARGET}
35 install-user: ${TARGET}
36 ${INSTALL} -d ${HOME_CORE}
37 ${INSTALL} -m 0744 -b -t ${HOME_CORE} ${TARGET}