Skip to content

Commit

Permalink
try adding custom rpaths
Browse files Browse the repository at this point in the history
  • Loading branch information
AndrewSazonov committed Jul 25, 2024
1 parent 7c98870 commit 0ccb86b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion pybuild.py
Original file line number Diff line number Diff line change
Expand Up @@ -281,6 +281,8 @@ def _compile_obj_script_line(src_path: str,
return cmd

def _compile_pycfml_shared_obj_or_dynamic_lib_script_line():
rpaths = '-Wl,-rpath,/opt/homebrew/opt/python@3.11/Frameworks/Python.framework/Versions/3.11/lib/python3.11/config-3.11-darwin -Wl,-rpath,/opt/homebrew/opt/python@3.11/Frameworks/Python.framework/Versions/3.11/lib -Wl,-rpath,/opt/homebrew/opt/python@3.11/Frameworks/Python.framework/Versions/3.11'

src_name = CONFIG['pycfml']['src-name']
shared_lib_ext = CONFIG['build']['shared-lib-ext'][_platform()]
cfml_lib_name = CONFIG['cfml']['static-lib-name']
Expand All @@ -297,7 +299,7 @@ def _compile_pycfml_shared_obj_or_dynamic_lib_script_line():
cmd = cmd.replace('{CFML_LIB_PATH}', cfml_lib_dist_path)
cmd = cmd.replace('{CFML_LIB_NAME}', cfml_lib_name)
cmd = cmd.replace('{IFPORT_LIB}', _ifport_lib())
cmd = cmd.replace('{PYTHON_LIB}', _python_lib())
cmd = cmd.replace('{PYTHON_LIB}', _python_lib() + ' ' + rpaths)
return cmd

def _compile_objs_script_lines(modules: str,
Expand Down
3 changes: 2 additions & 1 deletion pybuild.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ dist-progs = 'dist/CFML/progs' # for test programs

[cfml.git]
url = 'https://code.ill.fr/scientific-software/crysfml2008.git'
branch = 'powder_mod_fix'
#branch = 'powder_mod_fix'
branch = 'master'

[cfml.scripts]
pyapigen = 'repo/CFML/Scripts/PythonAPI/apigen.py'
Expand Down

0 comments on commit 0ccb86b

Please sign in to comment.