From 2a9eaa0aa4a046bb2dfd4c2aeb1ebbdcff0770b9 Mon Sep 17 00:00:00 2001 From: Joseph Hunkeler Date: Sat, 7 Mar 2020 01:45:07 -0500 Subject: Refactor RPATH creation: * Decreased complexity * Most rpath_* functions accept a FSTree structure now * Fewer calls to chdir() overall * Deeply nested libraries are detected * Libraries are no longer confined to lib/ and /lib64 --- include/rpath.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/rpath.h b/include/rpath.h index 742d969..2411b84 100644 --- a/include/rpath.h +++ b/include/rpath.h @@ -2,11 +2,12 @@ #define SPM_RPATH_H Process *patchelf(const char *_filename, const char *_args); -char *rpath_autodetect(const char *filename); +FSTree *rpath_libraries_available(const char *root); +char *rpath_autodetect(const char *filename, FSTree *tree); int has_rpath(const char *_filename); char *rpath_get(const char *_filename); -char *rpath_generate(const char *_filename); -int rpath_autoset(const char *filename); +char *rpath_generate(const char *_filename, FSTree *tree); +int rpath_autoset(const char *filename, FSTree *tree); int rpath_set(const char *filename, const char *rpath); #endif //SPM_RPATH_H -- cgit