22 lines
581 B
C
22 lines
581 B
C
#pragma once
|
|
#include <stddef.h>
|
|
#include <stdint.h>
|
|
#include <exec/list.h>
|
|
|
|
struct Library {
|
|
struct Node node;
|
|
uint8_t flags;
|
|
uintptr_t entry;
|
|
uintptr_t base;
|
|
uintptr_t *vectors;
|
|
};
|
|
|
|
struct Librarian {
|
|
struct Node node;
|
|
struct Library *(*find_library)(const char *name);
|
|
};
|
|
|
|
struct Library *MakeLibrary(uintptr_t *vectors, void *structure, uintptr_t init, uint32_t dataSize);
|
|
void AddLibrary(struct Library *library);
|
|
void AddLibrarian(struct Librarian *librarian);
|
|
struct Librarian *CreateLibrarian(struct Library *(*f)(const char *name), int8_t pri); |