mirror of
https://github.com/CoolProp/CoolProp.git
synced 2026-04-01 03:00:13 -04:00
Some changes to get examples to run properly
This commit is contained in:
@@ -10,8 +10,8 @@ def tee_call(call, file, **kwargs):
|
||||
**kwargs)
|
||||
stdout, stderr = callee.communicate()
|
||||
print(stdout, stderr)
|
||||
file.write(stdout.decode('ascii'))
|
||||
file.write(stderr.decode('ascii'))
|
||||
file.write()
|
||||
file.write()
|
||||
if callee.poll() != 0:
|
||||
raise ValueError('Return code is non-zero')
|
||||
|
||||
@@ -73,7 +73,7 @@ if __name__=='__main__':
|
||||
subprocess.check_call('cmake ../../../.. -DCOOLPROP_R_MODULE=ON -DCMAKE_VERBOSE_MAKEFILE=ON -DR_BIN=/usr/bin', **kwargs)
|
||||
subprocess.check_call('cmake --build .', **kwargs)
|
||||
with open('R/Example.out','w') as fp:
|
||||
tee_call(r'R -f Example.R', fp, shell = True, cwd = 'R')
|
||||
tee_call(r'DYLD_LIBRARY_PATH=/opt/refprop R -f Example.R', fp, shell = True, cwd = 'R')
|
||||
copyfiles('R','R')
|
||||
|
||||
if not os.path.exists('MATLAB'): os.mkdir('MATLAB')
|
||||
|
||||
Reference in New Issue
Block a user