libroot_debug: Merge guarded heap into libroot_debug.
[haiku.git] / src / system / runtime_loader / add_ons.h
blobd29f81649c15719b4d93df069e45f4f4bf78b634
1 /*
2 * Copyright 2009, Ingo Weinhold, ingo_weinhold@gmx.de.
3 * Distributed under the terms of the MIT License.
4 */
5 #ifndef ADD_ONS_H
6 #define ADD_ONS_H
8 #include <OS.h>
10 #include <util/DoublyLinkedList.h>
12 #include <runtime_loader.h>
15 // image events
16 enum {
17 IMAGE_EVENT_LOADED,
18 IMAGE_EVENT_RELOCATED,
19 IMAGE_EVENT_INITIALIZED,
20 IMAGE_EVENT_UNINITIALIZING,
21 IMAGE_EVENT_UNLOADING
25 struct RuntimeLoaderAddOn
26 : public DoublyLinkedListLinkImpl<RuntimeLoaderAddOn> {
27 image_t* image;
28 runtime_loader_add_on* addOn;
30 RuntimeLoaderAddOn(image_t* image, runtime_loader_add_on* addOn)
32 image(image),
33 addOn(addOn)
39 struct RuntimeLoaderSymbolPatcher {
40 RuntimeLoaderSymbolPatcher* next;
41 runtime_loader_symbol_patcher* patcher;
42 void* cookie;
44 RuntimeLoaderSymbolPatcher(runtime_loader_symbol_patcher* patcher,
45 void* cookie)
47 patcher(patcher),
48 cookie(cookie)
54 void init_add_ons();
55 status_t add_add_on(image_t* image, runtime_loader_add_on* addOnStruct);
56 void image_event(image_t* image, uint32 event);
59 #endif // ADD_ONS_H