blob: 76abd27d2a0cc4cbaaed2efd444621950420877d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
IP_CFLAGS = -std=gnu99 -I$(STAGING_DIR)/usr/include/libnl-tiny/
IP_LDFLAGS = -llua -lm -lnl-tiny
IP_OBJ = ip.o
IP_LIB = ip.so
%.o: %.c
$(CC) $(CPPFLAGS) $(CFLAGS) $(LUA_CFLAGS) $(IP_CFLAGS) $(FPIC) -c -o $@ $<
compile: $(IP_OBJ)
$(CC) $(LDFLAGS) -shared -o $(IP_LIB) $(IP_OBJ) $(IP_LDFLAGS)
install: compile
mkdir -p $(DESTDIR)/usr/lib/lua/luci
cp $(IP_LIB) $(DESTDIR)/usr/lib/lua/luci/$(IP_LIB)
clean:
rm -f *.o *.so
|