static int filter_system_shlibs(const char *name, char *path, size_t pathlen) { const char *shlib_path; shlib_path = shlib_list_find_by_name(name); if (shlib_path == NULL) { /* dynamic linker could not resolve */ return (EPKG_FATAL); } if (pkg_object_bool(pkg_config_get("ALLOW_BASE_SHLIBS"))) { if (strstr(shlib_path, "/lib32/") != NULL) return (EPKG_END); } else { /* match /lib, /lib32, /usr/lib and /usr/lib32 */ if (strncmp(shlib_path, "/lib", 4) == 0 || strncmp(shlib_path, "/usr/lib", 8) == 0) return (EPKG_END); /* ignore libs from base */ } if (path != NULL) strncpy(path, shlib_path, pathlen); return (EPKG_OK); }
static int filter_system_shlibs(const char *name, char *path, size_t pathlen) { const char *shlib_path; shlib_path = shlib_list_find_by_name(name); if (shlib_path == NULL) { /* dynamic linker could not resolve */ return (EPKG_FATAL); } /* match /lib, /lib32, /usr/lib and /usr/lib32 */ if (strncmp(shlib_path, "/lib", 4) == 0 || strncmp(shlib_path, "/usr/lib", 7) == 0) return (EPKG_END); /* ignore libs from base */ if (path != NULL) strncpy(path, shlib_path, pathlen); return (EPKG_OK); }