summaryrefslogtreecommitdiff
blob: 073a46eb386dc42852f4b008320c2ee0c60c5181 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
 scons/install.py | 10 ----------
 sconstruct       |  6 +++++-
 2 files changed, 5 insertions(+), 11 deletions(-)

diff --git a/scons/install.py b/scons/install.py
index b2d355a..d7c7911 100644
--- a/scons/install.py
+++ b/scons/install.py
@@ -109,16 +109,6 @@ def install(target, source, env):
         symlink(env['RELAX_PATH'] + sep + 'relax', env['SYMLINK'])
 
 
-    # Byte compile.
-    ###############
-
-    # Run relax to create the *.pyc files.
-    print("\nCreating the byte-compiled *.pyc files.")
-    python_path = sys.prefix + path.sep + 'bin' + path.sep + 'python' + `sys.version_info[0]` + '.' + `sys.version_info[1]`
-    cmd = "cd %s; %s -m compileall . ; %s -O -m compileall ." % (env['RELAX_PATH'], python_path, python_path)
-    print(cmd)
-    system(cmd)
-
     # Final printout.
     print("\n\n\n")
 
diff --git a/sconstruct b/sconstruct
index 8e968cd..8e7d949 100644
--- a/sconstruct
+++ b/sconstruct
@@ -26,7 +26,7 @@
 
 # Import statements.
 from numpy import get_include
-from os import getcwd, path, remove, rmdir, sep, walk
+from os import getcwd, path, remove, rmdir, sep, walk, environ
 import platform
 from re import search
 from shutil import rmtree
@@ -596,6 +596,10 @@ class Main:
         for file in files:
             nodes.append(env.SharedObject(dir + path.sep + file, CCFLAGS=cflags))
 
+        env.Append(LINKFLAGS = environ['LDFLAGS'])
+        env.Append(CFLAGS = environ['CFLAGS'])
+        env.Replace(CC = environ['CC'])
+
         # Build the relaxation curve fitting module.
         self.relax_fit_object = env.SharedLibrary(target=dir + path.sep + 'relax_fit', source=nodes, SHLIBPREFIX=prefix, SHLIBSUFFIX=suffix)