Skip to content

Commit

Permalink
fix(python): only add valid paths
Browse files Browse the repository at this point in the history
  • Loading branch information
Curve committed Jun 9, 2024
1 parent 2d7c7a9 commit 0a41a34
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion python/__init__.py.in
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,16 @@ microelectronic fabrication processes.
import sys

def _windows_dll_path():

import os

additional_paths = [
os.path.join(os.path.dirname(os.path.dirname(__file__)), 'viennaps.libs')
]

for path in additional_paths:
if not os.path.exists(path):
continue

os.add_dll_directory(path)
os.environ["PATH"] = path + os.pathsep + os.environ["PATH"]

Expand Down

0 comments on commit 0a41a34

Please sign in to comment.