Author: nwhitehorn Date: Sat Jun 26 22:04:52 2010 New Revision: 209544 URL: http://svn.freebsd.org/changeset/base/209544
Log: Ignore versioned dependencies on shared objects to which we do not link. This fixes an error with files like this created by GNU ld under certain circumstances. Modified: head/libexec/rtld-elf/rtld.c Modified: head/libexec/rtld-elf/rtld.c ============================================================================== --- head/libexec/rtld-elf/rtld.c Sat Jun 26 21:44:45 2010 (r209543) +++ head/libexec/rtld-elf/rtld.c Sat Jun 26 22:04:52 2010 (r209544) @@ -3443,9 +3443,13 @@ locate_dependency(const Obj_Entry *obj, if (object_match_name(needed->obj, name)) return needed->obj; } - _rtld_error("%s: Unexpected inconsistency: dependency %s not found", - obj->path, name); - die(); + + /* + * GNU LD sometimes refers to version dependencies on objects to which + * it does not actually link. Treat this as a non-fatal error, and + * ignore this dependency. + */ + return NULL; } static int @@ -3567,6 +3571,9 @@ rtld_verify_object_versions(Obj_Entry *o vn = obj->verneed; while (vn != NULL) { depobj = locate_dependency(obj, obj->strtab + vn->vn_file); + if (depobj == NULL) + break; + vna = (const Elf_Vernaux *) ((char *)vn + vn->vn_aux); for (;;) { if (check_object_provided_version(obj, depobj, vna)) _______________________________________________ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"