Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(263)

Unified Diff: dlwrap/dlwrap.h

Issue 8713008: Add dlwrap.c to binutils to simulate dlopen/dlsym for gold plugin (Closed)
Patch Set: x Created 8 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « binutils-2.20/ld/sysdep.h ('k') | dlwrap/dlwrap.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dlwrap/dlwrap.h
===================================================================
new file mode 100644
--- /dev/null
+++ b/dlwrap/dlwrap.h
@@ -0,0 +1,30 @@
+/* This header is a drop-in replacement for dlfcn.h */
+/* See dlwrap.c for more information */
+
+#ifndef __DLWRAP_H
+#define __DLWRAP_H
+
+#ifdef ENABLE_DLWRAP
+
+#define RTLD_NOW 0x2
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *pnacl_dlopen(const char *filename, int flag);
+char *pnacl_dlerror(void);
+void *pnacl_dlsym(void *handle, const char *symbol);
+int pnacl_dlclose(void *handle);
+
+#ifdef __cplusplus
+}
+#endif
+
+#define dlopen pnacl_dlopen
+#define dlerror pnacl_dlerror
+#define dlsym pnacl_dlsym
+#define dlclose pnacl_dlclose
+
+#endif /* ENABLE_DLWRAP */
+#endif /* __DLWRAP_H */
« no previous file with comments | « binutils-2.20/ld/sysdep.h ('k') | dlwrap/dlwrap.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698