Encapsulate soinfo_link_image and soinfo_relocate

Also get rid of needed[] array for these functions

(cherry picked from commit 29bbc9dd4c)

Change-Id: Id208621f66afa2e02a6b3facacee7d874466d81b
This commit is contained in:
Dmitriy Ivanov
2014-09-02 11:47:23 -07:00
parent 4466bd72fb
commit 7210c41fdc
2 changed files with 149 additions and 154 deletions

View File

@@ -204,6 +204,7 @@ struct soinfo {
void CallConstructors();
void CallDestructors();
void CallPreInitConstructors();
bool LinkImage(const android_dlextinfo* extinfo);
void add_child(soinfo* child);
void remove_all_links();
@@ -224,6 +225,11 @@ struct soinfo {
void CallArray(const char* array_name, linker_function_t* functions, size_t count, bool reverse);
void CallFunction(const char* function_name, linker_function_t function);
void resolve_ifunc_symbols();
#if defined(USE_RELA)
int Relocate(ElfW(Rela)* rela, unsigned count);
#else
int Relocate(ElfW(Rel)* rel, unsigned count);
#endif
private:
// This part of the structure is only available