From 9b9f0bd6ee316b78a824e3e2a7b37103cfb48b92 Mon Sep 17 00:00:00 2001 From: _ <_> Date: Thu, 17 May 2018 15:20:39 -0700 Subject: [PATCH] Fixed issues caused by importing from __init__ statements --- bindings/py3devil1geo.py | 8 +++++++- bindings/py3devil1pld.py | 9 ++++++++- bindings/py3devil1tex.py | 8 +++++++- 3 files changed, 22 insertions(+), 3 deletions(-) diff --git a/bindings/py3devil1geo.py b/bindings/py3devil1geo.py index e1bdd9e..5757b6a 100644 --- a/bindings/py3devil1geo.py +++ b/bindings/py3devil1geo.py @@ -1,5 +1,11 @@ import ctypes -from __init__ import libc +import os, sys +sys.path.append( + os.path.abspath( + os.path.join( + os.path.dirname(__file__), "../../"))) +from lib3ddevil1.bindings import libc +del os, sys #--------------------------------------+ # Basic Struct diff --git a/bindings/py3devil1pld.py b/bindings/py3devil1pld.py index 62ed79b..a16c8c5 100644 --- a/bindings/py3devil1pld.py +++ b/bindings/py3devil1pld.py @@ -1,5 +1,12 @@ import ctypes -from __init__ import libc +import os, sys +# This is the folder containing the whole library. +sys.path.append( + os.path.abspath( + os.path.join( + os.path.dirname(__file__), "../../"))) +from lib3ddevil1.bindings import libc +del os, sys #--------------------------------------+ # Basic Struct diff --git a/bindings/py3devil1tex.py b/bindings/py3devil1tex.py index 6300ed1..4c67368 100644 --- a/bindings/py3devil1tex.py +++ b/bindings/py3devil1tex.py @@ -1,5 +1,11 @@ import ctypes -from __init__ import libc +import os, sys +sys.path.append( + os.path.abspath( + os.path.join( + os.path.dirname(__file__), "../../"))) +from lib3ddevil1.bindings import libc +del os, sys #--------------------------------------+ # Basic Struct