GCC Middle and Back End API Reference
|
Functions | |
static bfd_vma | read_value () |
static bool | string_within_bounds_p () |
static bool | within_object_p () |
static bool | read_xcoff_object (LDFILE *ldfile, size_t offset, size_t object_size, off_t next_member) |
static bool | read_archive_member () |
static bool | read_big_archive () |
static bool | open_file () |
static void | free_object () |
static void | free_ldfile () |
LDFILE * | ldopen () |
int | ldtbread () |
char * | ldgetname () |
int | ldclose () |
|
static |
Free LDFILE and all resources associated with it.
References internal_ldfile::fd.
|
static |
Release the memory associated with the current object, if one has been mapped.
References internal_ldfile::object, internal_ldfile::object_size, and internal_ldfile::page_offset.
int ldclose | ( | ) |
Implement the API-defined ldclose function.
References free_ldfile(), free_object(), internal_ldfile::next_member, and read_archive_member().
char* ldgetname | ( | ) |
Implement the API-defined ldgetname function.
References internal_syment::n_name, internal_syment::n_zeroes, internal_ldfile::object, internal_ldfile::object_size, offset, and string_within_bounds_p().
LDFILE* ldopen | ( | ) |
Implement the API-defined ldopen function.
References free_ldfile(), free_object(), and open_file().
int ldtbread | ( | ) |
Implement the API-defined ldtbread function.
References memcpy(), external_syment::n_numaux, external_syment::n_sclass, external_syment::n_scnum, external_syment::n_type, internal_ldfile::object, offset, external_syment::u, and within_object_p().
|
static |
LDFILE is a zero-initialized structure. Try to open FILENAME, returning true on success.
References internal_ldfile::fd, read_big_archive(), and read_xcoff_object().
Referenced by ldopen().
|
static |
Try to read an archive member at OFFSET bytes into LDFILE. Return true on success, recording the member and object information in LDFILE.
References external_big_ar_member::ar_namlen, external_big_ar_member::ar_nextoff, external_big_ar_member::ar_size, internal_ldfile::fd, and read_xcoff_object().
Referenced by ldclose(), and read_big_archive().
|
static |
Try to treat LDFILE as a non-empty big archive. Return true on success, storing the member and object information for the first member in LDFILE.
References internal_ldfile::fd, external_big_ar_filehdr::fl_firstmemoff, external_big_ar_filehdr::fl_magic, offset, and read_archive_member().
Referenced by open_file().
|
inlinestatic |
@verbatim AIX cross support for collect2.
Copyright (C) 2009-2013 Free Software Foundation, Inc.
This file is part of GCC.
GCC is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3, or (at your option) any later version.
GCC is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with GCC; see the file COPYING3. If not see http://www.gnu.org/licenses/.
Read SIZE bytes starting at DATA as a big-endian value.
Referenced by read_xcoff_object().
|
static |
Try to read the file header for an XCOFF object at OFFSET bytes into LDFILE. The object is expected to be OBJECT_SIZE bytes in size. If the object is a member of an archive, NEXT_MEMBER is the offset of the next member, otherwise it is -1. Return true on success, recording the object information in LDFILE.
References internal_filehdr::f_flags, internal_filehdr::f_nscns, internal_filehdr::f_nsyms, internal_filehdr::f_opthdr, internal_filehdr::f_symptr, internal_filehdr::f_timdat, internal_ldfile::fd, internal_ldfile::filehdr, getpagesize(), map, internal_ldfile::next_member, internal_ldfile::object, internal_ldfile::object_size, internal_ldfile::page_offset, read_value(), and within_object_p().
Referenced by open_file(), and read_archive_member().
|
static |
Return true if STRING is less than SIZE bytes long. EXTRA_TERMINATOR is another character (besides '\0') that acts as a terminator, or '\0' if none.
Referenced by ldgetname().
|
inlinestatic |
Check that LDFILE's current object has SIZE bytes starting at OFFSET.
References internal_ldfile::object_size.
Referenced by ldtbread(), and read_xcoff_object().