• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#!/usr/bin/env python
2
3from distutils.core import setup, Extension
4
5opts = ['-O', '-nodefaultctor']
6include = ['@top_builddir@/include', '@top_srcdir@/include']
7library_dirs = ['@top_builddir@/lib/.libs']
8
9netlink_capi = Extension('netlink/_capi',
10                         sources = ['@srcdir@/netlink/capi.i'],
11			 include_dirs = include,
12			 swig_opts = opts,
13			 library_dirs = library_dirs,
14			 libraries = ['nl-3'],
15			)
16
17route_capi = Extension('netlink/route/_capi',
18                         sources = ['@srcdir@/netlink/route/capi.i'],
19			 include_dirs = include,
20			 swig_opts = opts,
21			 library_dirs = library_dirs,
22			 libraries = ['nl-3', 'nl-route-3'],
23			)
24
25genl_capi = Extension('netlink/genl/_capi',
26			 sources = ['@srcdir@/netlink/genl/capi.i'],
27			 include_dirs = include,
28			 swig_opts = opts,
29			 library_dirs = library_dirs,
30			 libraries = ['nl-3', 'nl-genl-3'],
31			)
32
33setup(name = 'netlink',
34      version = '1.0',
35      description = 'Python wrapper for netlink protocols',
36      author = 'Thomas Graf',
37      author_email = 'tgraf@suug.ch',
38      ext_modules = [netlink_capi, route_capi, genl_capi],
39      package_dir = {'': '@srcdir@'},
40      packages = ['netlink', 'netlink.genl', 'netlink.route',
41		  'netlink.route.links', 'netlink.route.qdisc'],
42     )
43