Skip to content

Commit

Permalink
fixed windows 64 bit dll loading
Browse files Browse the repository at this point in the history
  • Loading branch information
dev-jam committed Mar 14, 2023
1 parent e3556a7 commit f5f6616
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,16 @@ def prepare(self):
except ImportError as e:
raise osexception(u'The ctypes module can not be loaded. Check if ctypes is installed correctly.', exception=e)

path_to_dll_file = os.path.join(os.path.dirname(__file__), 'inpout32.dll')
import platform

if platform.architecture()[0] == "32bit":
self.dll_file = 'inpout32.dll'
elif platform.architecture()[0] == "64bit":
self.dll_file = 'inpoutx64.dll'
else:
raise osexception('Platform not supported')

path_to_dll_file = os.path.join(os.path.dirname(__file__), self.dll_file)
self.show_message(path_to_dll_file)

try:
Expand Down

0 comments on commit f5f6616

Please sign in to comment.