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 <burgholzer@me.com>
  • Loading branch information
burgholzer committed Apr 30, 2024
1 parent e55cdb6 commit 56b1891
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 56b1891

Please sign in to comment.