summaryrefslogtreecommitdiffhomepage
path: root/contrib/package/iwinfo/src/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/package/iwinfo/src/Makefile')
-rw-r--r--contrib/package/iwinfo/src/Makefile15
1 files changed, 15 insertions, 0 deletions
diff --git a/contrib/package/iwinfo/src/Makefile b/contrib/package/iwinfo/src/Makefile
new file mode 100644
index 000000000..1d4319fb0
--- /dev/null
+++ b/contrib/package/iwinfo/src/Makefile
@@ -0,0 +1,15 @@
+IWINFO_LDFLAGS = $(LDFLAGS) -shared -llua $(if $(CRAP),,-lnl-tiny)
+IWINFO_CFLAGS = $(CFLAGS) -std=gnu99 -fstrict-aliasing $(if $(CRAP),-DUSE_WL,-DUSE_MADWIFI -DUSE_NL80211)
+IWINFO_SO = iwinfo.so
+IWINFO_OBJ = $(if $(CRAP),iwinfo_wl.o,iwinfo_madwifi.o iwinfo_nl80211.o) \
+ iwinfo_wext.o iwinfo_wext_scan.o iwinfo_lualib.o
+
+%.o: %.c
+ $(CC) $(IWINFO_CFLAGS) $(LUA_CFLAGS) $(FPIC) -c -o $@ $<
+
+compile: clean $(IWINFO_OBJ)
+ $(LD) $(IWINFO_LDFLAGS) -o $(IWINFO_SO) $(IWINFO_OBJ)
+
+clean:
+ rm -f *.o $(IWINFO_SO)
+