blob: ffed8a687020ac9af7c12d66c1c0ee44c1f4020d (
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) $(FPIC)
install: compile
mkdir -p $(DESTDIR)/usr/lib/lua/luci
cp $(IP_LIB) $(DESTDIR)/usr/lib/lua/luci/$(IP_LIB)
clean:
rm -f *.o *.so
|