summaryrefslogtreecommitdiff
path: root/packages/python/python-pywpa-0.3.4/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'packages/python/python-pywpa-0.3.4/Makefile')
-rw-r--r--packages/python/python-pywpa-0.3.4/Makefile28
1 files changed, 28 insertions, 0 deletions
diff --git a/packages/python/python-pywpa-0.3.4/Makefile b/packages/python/python-pywpa-0.3.4/Makefile
new file mode 100644
index 0000000000..0206f1c229
--- /dev/null
+++ b/packages/python/python-pywpa-0.3.4/Makefile
@@ -0,0 +1,28 @@
+# Simple Makefile
+
+NAME = pywpa/_pywpa
+CFLAGS += -Iwpactrl
+OBJS = pywpa.o
+
+%.o: %.c
+ @echo "Compiling $(<)"
+ @$(CC) $(CFLAGS) -c $(<) -o $(@)
+
+$(NAME).so: objects libwpactrl
+ @echo "Statically Linking $(NAME)"
+ @$(CC) $(CFLAGS) $(OBJS) wpactrl/wpa_ctrl.o -shared -o $(NAME).so
+
+main: objects libwpactrl
+ @echo "Creating test"
+ @$(CC) $(CFLAGS) $(OBJS) wpactrl/wpa_ctrl.o -o test -lpython2.4
+
+objects: $(OBJS)
+
+libwpactrl:
+ @make -C wpactrl > /dev/null
+
+clean:
+ @rm -rf *.o
+ @rm -rf $(NAME).so
+ @rm -rf $(NAME).so.t*
+ @make -C wpactrl clean 2>/dev/null