Skip to content

Commit

Permalink
🔧 properly set Windows DLL path
Browse files Browse the repository at this point in the history
Signed-off-by: Lukas Burgholzer <[email protected]>
  • Loading branch information
burgholzer committed Feb 12, 2024
1 parent 8b1b2f5 commit 73ca1ad
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/mqt/core/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,17 @@

from __future__ import annotations

import sys

# under Windows, make sure to add the appropriate DLL directory to the PATH
if sys.platform == "win32":
import os
import sysconfig
from pathlib import Path

bin_dir = Path(sysconfig.get_paths()["purelib"]) / "mqt" / "core" / "bin"
os.add_dll_directory(str(bin_dir))

from ._core import Permutation, QuantumComputation
from ._version import version as __version__
from ._version import version_tuple as version_info
Expand Down

0 comments on commit 73ca1ad

Please sign in to comment.