重击:
LD_LIBRARY_PATH=my_pathsqsub -np /path/to/executable
在Python中类似:
import osimport subprocessimport sysos.environ['LD_LIBRARY_PATH'] = "my_path" # visible in this process + all childrensubprocess.check_call(['sqsub', '-np', sys.argv[1], '/path/to/executable'],env=dict(os.environ, SQSUB_VAR="visible in this subprocess"))
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)