]> granicus.if.org Git - libnl/commitdiff
python: Include python/ in distribution and provide a README on how to build & install
authorThomas Graf <tgraf@suug.ch>
Fri, 12 Aug 2011 08:45:47 +0000 (10:45 +0200)
committerThomas Graf <tgraf@suug.ch>
Fri, 12 Aug 2011 08:45:47 +0000 (10:45 +0200)
Makefile.am
configure.in
python/.gitignore
python/Makefile.am [new file with mode: 0644]
python/README [new file with mode: 0644]
python/netlink/Makefile.am [new file with mode: 0644]
python/netlink/route/Makefile.am [new file with mode: 0644]
python/setup.py.in [moved from python/setup.py with 95% similarity]

index 68d236c488dcd985b831e5641cbf8f4ee3efb47d..644fdb1da6d75037d42fe353413876339b12d98b 100644 (file)
@@ -8,7 +8,7 @@ if ENABLE_CLI
 OPT_DIRS += src
 endif
 
-SUBDIRS = include lib doc man $(OPT_DIRS)
+SUBDIRS = include lib doc man python $(OPT_DIRS)
 
 pkgconfig_DATA = libnl-3.1.pc \
                 libnl-route-3.1.pc \
index f217231a859561e6ca62fc3b2712649cb1917c78..7611e92e57f799ba17964a6446a284d065f5b3c6 100644 (file)
@@ -51,5 +51,7 @@ AC_CHECK_LIB([pthread], [pthread_mutex_lock], [], AC_MSG_ERROR([libpthread is re
 AC_CONFIG_FILES([Makefile doc/Doxyfile doc/Makefile lib/Makefile
        include/Makefile src/Makefile src/lib/Makefile man/Makefile
        libnl-3.1.pc libnl-route-3.1.pc libnl-genl-3.1.pc libnl-nf-3.1.pc
+       python/Makefile python/setup.py python/netlink/Makefile
+       python/netlink/route/Makefile
        include/netlink/version.h])
 AC_OUTPUT
index 9f3c73bb9449658c4a149ed712639fb6fe8844a3..a83b94295d0f9fb44f66b9644d49b87a76f86363 100644 (file)
@@ -1,3 +1,4 @@
 build
 capi_wrap.c
 capi.py
+setup.py
diff --git a/python/Makefile.am b/python/Makefile.am
new file mode 100644 (file)
index 0000000..bd5ac11
--- /dev/null
@@ -0,0 +1,3 @@
+# -*- Makefile -*-
+
+SUBDIRS = netlink
diff --git a/python/README b/python/README
new file mode 100644 (file)
index 0000000..4ccc337
--- /dev/null
@@ -0,0 +1,12 @@
+
+***************************************************************************
+
+NOTE: The python wrapper is experimental and may or may not work.
+
+***************************************************************************
+
+For the brave:
+
+  (requires an installed libnl)
+  - $ python ./setup.py build
+  - $ sudo python ./setup.py install
diff --git a/python/netlink/Makefile.am b/python/netlink/Makefile.am
new file mode 100644 (file)
index 0000000..0f1045b
--- /dev/null
@@ -0,0 +1,10 @@
+# -*- Makefile -*-
+
+SUBDIRS = route
+
+EXTRA_DIST = \
+       capi.i \
+       fixes.h \
+       __init__.py \
+       core.py \
+       util.py
diff --git a/python/netlink/route/Makefile.am b/python/netlink/route/Makefile.am
new file mode 100644 (file)
index 0000000..ef714f4
--- /dev/null
@@ -0,0 +1,14 @@
+# -*- Makefile -*-
+
+EXTRA_DIST = \
+       capi.i \
+       __init__.py \
+       address.py \
+       link.py \
+       tc.py \
+       links/__init__.py \
+       links/dummy.py \
+       links/inet.py \
+       links/vlan.py \
+       qdisc/__init__.py \
+       qdisc/htb.py
similarity index 95%
rename from python/setup.py
rename to python/setup.py.in
index f201a84bd1ada7750fca6e8c77ada26028e01cf1..e1a3aca6809f8029a77c65119eaf17c352c290a2 100644 (file)
@@ -3,7 +3,7 @@
 from distutils.core import setup, Extension
 
 opts = ['-O', '-nodefaultctor']
-include = ['../include']
+include = ['@top_builddir@/include']
 
 netlink_capi = Extension('netlink/_capi',
                          sources = ['netlink/capi.i'],