|
3 | 3 | from shutil import copyfile |
4 | 4 | from sys import platform |
5 | 5 |
|
6 | | -# dirname = path.dirname(path.abspath(__file__)) |
| 6 | +dirname = path.dirname(path.abspath(__file__)) |
7 | 7 |
|
8 | | -# if platform == "linux" or platform == "linux2": |
9 | | -# lib_path = path.abspath(path.join(dirname, '../build/lib/libFedTree.so')) |
10 | | -# elif platform == "win32": |
11 | | -# lib_path = path.abspath(path.join(dirname, '../build/bin/Debug/libFedTree.dll')) |
12 | | -# elif platform == "darwin": |
13 | | -# lib_path = path.abspath(path.join(dirname, '../build/lib/libFedTree.dylib')) |
14 | | -# else: |
15 | | -# print("OS not supported!") |
16 | | -# exit() |
| 8 | +if platform == "linux" or platform == "linux2": |
| 9 | + lib_path = path.abspath(path.join(dirname, '../build/lib/libFedTree.so')) |
| 10 | +elif platform == "win32": |
| 11 | + lib_path = path.abspath(path.join(dirname, '../build/bin/Debug/libFedTree.dll')) |
| 12 | +elif platform == "darwin": |
| 13 | + lib_path = path.abspath(path.join(dirname, '../build/lib/libFedTree.dylib')) |
| 14 | +else: |
| 15 | + print("OS not supported!") |
| 16 | + exit() |
17 | 17 |
|
18 | | -# if not path.exists(path.join(dirname, "fedtree", path.basename(lib_path))): |
19 | | -# copyfile(lib_path, path.join(dirname, "fedtree", path.basename(lib_path))) |
| 18 | +if not path.exists(path.join(dirname, "fedtree", path.basename(lib_path))): |
| 19 | + copyfile(lib_path, path.join(dirname, "fedtree", path.basename(lib_path))) |
20 | 20 |
|
21 | | -lib_path = "./fedtree/libFedTree.so" |
| 21 | +# lib_path = "./fedtree/libFedTree.so" |
22 | 22 |
|
23 | 23 |
|
24 | 24 | setuptools.setup(name="fedtree", |
|
0 commit comments