You've already forked macports-ports
mirror of
https://github.com/encounter/macports-ports.git
synced 2026-03-30 11:29:27 -07:00
38 lines
1.5 KiB
Diff
38 lines
1.5 KiB
Diff
--- setup.py.orig 2020-03-02 01:23:13.000000000 +0300
|
|
+++ setup.py 2020-03-02 01:26:39.000000000 +0300
|
|
@@ -24,6 +24,7 @@
|
|
sys.exit(1)
|
|
|
|
ninja_available = shutil.which("ninja") is not None
|
|
+ninja_available = False
|
|
if not (ninja_available or shutil.which("make")):
|
|
print("ERROR: NetworKit compilation requires Make or Ninja.")
|
|
sys.exit(1)
|
|
@@ -117,7 +118,7 @@
|
|
def cythonizeFile(filepath):
|
|
cpp_file = filepath.replace("pyx","cpp")
|
|
|
|
- cython_available = shutil.which("cython") is not None
|
|
+ cython_available = shutil.which("@@CYTHON@@") is not None
|
|
if not cython_available:
|
|
if not os.path.isfile(cpp_file):
|
|
print("ERROR: Neither cython nor _NetworKit.cpp is provided. Build cancelled", flush=True)
|
|
@@ -134,7 +135,7 @@
|
|
if not os.path.isfile(filepath):
|
|
print("_NetworKit.pyx is not available. Build cancelled.")
|
|
exit(1)
|
|
- comp_cmd = ["cython","-3","--cplus","-t",filepath]
|
|
+ comp_cmd = ["@@CYTHON@@","-3","--cplus","-t",filepath]
|
|
if not subprocess.call(comp_cmd) == 0:
|
|
print("cython returned an error, exiting setup.py")
|
|
exit(1)
|
|
@@ -163,6 +164,8 @@
|
|
comp_cmd.append(os.getcwd()) #call CMakeLists.txt from networkit root
|
|
if rpath:
|
|
comp_cmd.append("-DNETWORKIT_PYTHON_RPATH="+rpath)
|
|
+ comp_cmd.append("-DLIBOMP_PATH=@@PREFIX@@/lib/libomp")
|
|
+ comp_cmd.append("-DLIBOMP_INCLUDE=@@PREFIX@@/include/libomp")
|
|
# Run cmake
|
|
print("initializing NetworKit compilation with: '{0}'".format(" ".join(comp_cmd)), flush=True)
|
|
if not subprocess.call(comp_cmd, cwd=buildDirectory) == 0:
|