Skip to content

Commit 30821ca

Browse files
committed
Silly error: path not updated...
1 parent e96e7cc commit 30821ca

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

setup.py

+7-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import sys
2-
from typing import Type
2+
from typing import Type, Optional
33

44
import os
55
import shutil
@@ -125,6 +125,7 @@ def build_nova_physics():
125125

126126

127127
NOVA_TO_LINK = Path("dummy/path")
128+
EXTENSION: Optional[Extension] = None
128129

129130
BUILD_BINARIES = "--dont-build-binaries" not in sys.argv
130131
if not BUILD_BINARIES:
@@ -178,6 +179,8 @@ def pre_build(self):
178179
global NOVA_TO_LINK
179180
innit_checks()
180181
NOVA_TO_LINK = get_nova_to_link().relative_to(PACKAGE_DIR)
182+
if EXTENSION is not None:
183+
EXTENSION.extra_objects = [str(NOVA_TO_LINK)]
181184
self._old_run()
182185

183186

@@ -186,6 +189,7 @@ def generate_cmd_class(orig: Type[DistCommand]):
186189

187190

188191
def main():
192+
global EXTENSION
189193
innit_checks()
190194

191195
nova_to_link = str(NOVA_TO_LINK)
@@ -204,6 +208,8 @@ def main():
204208
optional=False
205209
)
206210

211+
EXTENSION = extension
212+
207213
print(
208214
"See https://github.com/gresm/nova-physics-python-fixed/blob/master/troubleshooting-guide.md if error occurred "
209215
"to see whether there is solution for your problem."

0 commit comments

Comments
 (0)