Changeset fb69211 in sasmodels
- Timestamp:
- Apr 27, 2016 11:06:41 AM (9 years ago)
- Branches:
- master, core_shell_microgels, costrafo411, magnetic_model, release_v0.94, release_v0.95, ticket-1257-vesicle-product, ticket_1156, ticket_1265_superball, ticket_822_more_unit_tests
- Children:
- 3a45c2c, ff97458
- Parents:
- 9ccf580
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sasmodels/kerneldll.py
r29464ba rfb69211 48 48 import sys 49 49 import os 50 from os.path import join as joinpath, split as splitpath, realpath, splitext 50 51 import tempfile 51 52 import ctypes as ct … … 78 79 else: 79 80 COMPILE = " ".join((CC, LN)) 80 else: 81 # fPIC is unused on windows 82 # COMPILE = "gcc -shared -fPIC -std=c99 -O2 -Wall %(source)s -o %(output)s -lm" 81 elif True: # Don't use mingw 82 # fPIC is not needed on windows 83 83 COMPILE = "gcc -shared -std=c99 -O2 -Wall %(source)s -o %(output)s -lm" 84 84 if "SAS_OPENMP" in os.environ: 85 85 COMPILE = COMPILE + " -fopenmp" 86 #COMPILE = "z:/tcc/tcc -shared -rdynamic -Wall %(source)s -o %(output)s" 86 else: 87 from tinycc import TCC 88 COMPILE = TCC + " -shared -rdynamic -Wall %(source)s -o %(output)s" 87 89 else: 88 90 COMPILE = "cc -shared -fPIC -fopenmp -std=c99 -O2 -Wall %(source)s -o %(output)s -lm" 89 91 90 92 # Assume the default location of module DLLs is in top level /models dir. 91 DLL_PATH = os.path.join(os.path.split(os.path.realpath(sys.argv[0]))[0], "models")93 DLL_PATH = joinpath(splitpath(realpath(sys.argv[0]))[0], "models") 92 94 93 95 ALLOW_SINGLE_PRECISION_DLLS = True … … 98 100 Path to the compiled model defined by *model_info*. 99 101 """ 100 from os.path import join as joinpath, split as splitpath, splitext101 102 basename = splitext(splitpath(model_info['filename'])[1])[0] 102 103 if np.dtype(dtype) == generate.F32:
Note: See TracChangeset
for help on using the changeset viewer.