Handle error from RPATH already existing
@@ -32,9 +32,15 @@ if __name__ == '__main__':
print('Changing {lib} to {new_lib}'.format(lib=lib, new_lib=new_lib))
cmd = ['install_name_tool', '-change', lib, new_lib, bin_file]
print(' '.join(cmd))
+ try:
output = check_output(cmd)
+ except CalledProcessError:
+ pass
cmd = ['install_name_tool', '-add_rpath',
os.path.join('@loader_path', '..', 'lib'),
bin_file]
print(' '.join(cmd))
+ try:
output = check_output(cmd)
+ except CalledProcessError:
+ pass
