forked from bigswitch/mininet
-
Notifications
You must be signed in to change notification settings - Fork 1
/
setup.py
49 lines (43 loc) · 1.37 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
#!/usr/bin/env python
"Setuptools params"
import os, setuptools
import distutils.command.build_scripts
import distutils.command.clean
import distutils.ccompiler
modname = distname = 'mininet'
class build_scripts(distutils.command.build_scripts.build_scripts):
def run(self):
distutils.ccompiler.new_compiler().link_executable(["mnexec.c"], "bin/mnexec")
distutils.command.build_scripts.build_scripts.run(self)
class clean(distutils.command.clean.clean):
def run(self):
if os.path.exists("bin/mnexec"):
os.unlink("bin/mnexec")
distutils.command.clean.clean.run(self)
setuptools.setup(
name=distname,
version='0.0.0',
description='Process-based OpenFlow emulator',
author='Bob Lantz',
author_email='[email protected]',
packages=setuptools.find_packages(exclude='test'),
classifiers=[
"License :: OSI Approved :: GNU General Public License (GPL)",
"Programming Language :: Python",
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"Topic :: Internet",
],
keywords='networking protocol Internet OpenFlow',
license='unspecified',
install_requires=[
'setuptools',
'networkx'
],
scripts=[
'bin/mn',
'bin/mnexec'
],
cmdclass={"build_scripts": build_scripts,
"clean": clean}
)