Turnstone Operating System
|
linker functions and types More...
#include <types.h>
#include <buffer.h>
#include <hashmap.h>
#include <tosdb/tosdb.h>
#include <utils.h>
Classes | |
struct | linker_relocation_entry_t |
struct | linker_section_locations_t |
section information More... | |
struct | linker_global_offset_table_entry_t |
struct | program_header_t |
program definition header. More... | |
struct | linker_section_t |
struct | linker_module_t |
struct | linker_context_t |
Macros | |
#define | ___LINKER_H 0 |
#define | TOS_EXECUTABLE_OR_LIBRARY_MAGIC "TOSELF" |
#define | LINKER_GOT_SYMBOL_ID 0x1 |
#define | LINKER_GOT_SECTION_ID 0x1 |
Typedefs | |
typedef enum linker_section_type_t | linker_section_type_t |
shorthand for enum | |
typedef enum linker_relocation_type_t | linker_relocation_type_t |
shorthand for enum | |
typedef enum linker_symbol_type_t | linker_symbol_type_t |
shorthand for enum | |
typedef enum linker_symbol_scope_t | linker_symbol_scope_t |
shorthand for enum | |
typedef struct linker_relocation_entry_t | linker_relocation_entry_t |
shorthand for struct | |
typedef struct linker_section_locations_t | linker_section_locations_t |
shorthand for struct | |
typedef struct linker_global_offset_table_entry_t | linker_global_offset_table_entry_t |
shorthand for struct | |
typedef struct program_header_t | program_header_t |
shorthand for struct | |
typedef struct linker_section_t | linker_section_t |
typedef struct linker_module_t | linker_module_t |
typedef struct linker_context_t | linker_context_t |
typedef enum linker_program_dump_type_t | linker_program_dump_type_t |
Functions | |
_Static_assert (sizeof(linker_global_offset_table_entry_t) % 8==0, "linker_global_offset_table_entry_t align mismatch") | |
_Static_assert (sizeof(linker_global_offset_table_entry_t)==0x38, "linker_global_offset_table_entry_t size mismatch") | |
_Static_assert (offsetof_field(program_header_t, trampoline_code)==256, "program_header_t trampoline code align mismatch") | |
int8_t | linker_destroy_context (linker_context_t *ctx) |
int8_t | linker_build_module (linker_context_t *ctx, uint64_t module_id, boolean_t recursive) |
int8_t | linker_build_symbols (linker_context_t *ctx, uint64_t module_id, uint64_t section_id, uint8_t section_type, uint64_t section_offset) |
int8_t | linker_build_relocations (linker_context_t *ctx, uint64_t section_id, uint8_t section_type, uint64_t section_offset, linker_module_t *module, boolean_t recursive) |
boolean_t | linker_is_all_symbols_resolved (linker_context_t *ctx) |
int8_t | linker_calculate_program_size (linker_context_t *ctx) |
int8_t | linker_bind_linear_addresses (linker_context_t *ctx) |
int8_t | linker_bind_got_entry_values (linker_context_t *ctx) |
int8_t | linker_link_program (linker_context_t *ctx) |
int64_t | linker_get_section_count_without_relocations (linker_context_t *ctx) |
buffer_t * | linker_build_efi_image_relocations (linker_context_t *ctx) |
buffer_t * | linker_build_efi_image_section_headers_without_relocations (linker_context_t *ctx) |
buffer_t * | linker_build_efi (linker_context_t *ctx) |
int8_t | linker_dump_program_to_array (linker_context_t *ctx, linker_program_dump_type_t dump_type, uint8_t *array) |
void | linker_build_modules_at_memory (void) |
void | linker_print_modules_at_memory (void) |
void | linker_print_module_info_at_memory (uint64_t module_id) |
Variables | |
const char_t *const | linker_section_type_names [LINKER_SECTION_TYPE_NR_SECTIONS] |
linker section type names | |
linker functions and types
This work is licensed under TURNSTONE OS Public License. Please read and understand latest version of Licence.
#define ___LINKER_H 0 |
prevent duplicate header error macro
#define TOS_EXECUTABLE_OR_LIBRARY_MAGIC "TOSELF" |
linker executable or library magic TOSEL
relocation stypes
linker section types.
enum linker_symbol_type_t |