11
11
#User can specify an include directory with -I : this will be passed to SWIG. If no such parameter is specified, then -I/usr/include will be passed to SWIG
12
optlist, a = getopt.getopt(sys.argv[2:], 'I:',['all'])
14
includeDir = "/usr/include"
12
optlist, a = getopt.getopt(sys.argv[2:], 'I:L:',['all'])
17
19
for opt in optlist:
23
removeArg = c+2 # +2 because we omitted the 1st and 2nd argument in the beginning!
25
removeArg = c+2 # +2 because we omitted the 1st and 2nd argument in the beginning!
31
removeArg2 = c+2 # +2 because we omitted the 1st and 2nd argument in the beginning!
26
33
if (removeArg >= 0):
27
dummy = sys.argv.pop(removeArg)
34
dummy = sys.argv.pop(removeArg)
36
dummy = sys.argv.pop(removeArg2)
29
38
print "Directory for SWIG -I option : " , includeDir
31
#file_util.copy_file("python_meep_config-nonmpi.py","python_meep_config.py")
39
print "Directory for -L option : " , libDir
41
# file_util.copy_file("python_meep_config-nonmpi.py","python_meep_config.py")
42
# no need for such granularization
33
44
meep_swig = Extension ('_meep', ['meep.i'],
34
45
swig_opts=['-c++','-w503','-I'+includeDir],
47
library_dirs=[libDir],
37
51
setup (name = 'python-meep',
39
author = "Nizamov Shawkat (original author), Emmanuel Lambert (co-author from 08-2009 onwards)",
53
author = "Nizamov Shawkat and Emmanuel Lambert",
40
54
author_email = "http://launchpad.net/~python-meep/+contactuser",
41
55
url = 'http://launchpad.net/~python-meep',
42
description = """Python wrapper module for MEEP""",
56
description = """Python wrapper module for MEEP FDTD""",
43
57
ext_modules = [meep_swig],
44
58
data_files=[(sysconfig.get_python_lib(1,0,""),['custom.hpp'])],
45
59
py_modules = ["meep"],