aboutsummaryrefslogtreecommitdiff
path: root/libXfont/src/stubs/stubs.h
diff options
context:
space:
mode:
Diffstat (limited to 'libXfont/src/stubs/stubs.h')
-rw-r--r--libXfont/src/stubs/stubs.h53
1 files changed, 50 insertions, 3 deletions
diff --git a/libXfont/src/stubs/stubs.h b/libXfont/src/stubs/stubs.h
index 7f0eef298..7d499d5b6 100644
--- a/libXfont/src/stubs/stubs.h
+++ b/libXfont/src/stubs/stubs.h
@@ -19,6 +19,54 @@
#endif
#endif
+#if defined(NO_WEAK_SYMBOLS) && defined(PIC)
+#include <stdarg.h>
+extern int _font_init_stubs(void);
+#define OVERRIDE_DATA(sym) \
+ _font_init_stubs(); \
+ if (__ptr_##sym && __ptr_##sym != &sym) \
+ sym = *__ptr_##sym
+#define OVERRIDE_SYMBOL(sym,...) \
+ _font_init_stubs(); \
+ if (__##sym && __##sym != sym) \
+ return (*__##sym)(__VA_ARGS__)
+#define OVERRIDE_VA_SYMBOL(sym,f) \
+ va_list _args; \
+ _font_init_stubs(); \
+ va_start(_args, f); \
+ if (__##sym) \
+ (*__##sym)(f, _args); \
+ va_end(_args)
+
+int (*__client_auth_generation)(ClientPtr);
+Bool (*__ClientSignal)(ClientPtr);
+void (*__DeleteFontClientID)(Font);
+void (*__VErrorF)(const char *, va_list);
+FontPtr (*__find_old_font)(FSID);
+FontResolutionPtr (*__GetClientResolutions)(int *);
+int (*__GetDefaultPointSize)(void);
+Font (*__GetNewFontClientID)(void);
+unsigned long (*__GetTimeInMillis)(void);
+int (*__init_fs_handlers)(FontPathElementPtr, BlockHandlerProcPtr);
+int (*__RegisterFPEFunctions)(NameCheckFunc, InitFpeFunc, FreeFpeFunc,
+ ResetFpeFunc, OpenFontFunc, CloseFontFunc, ListFontsFunc,
+ StartLfwiFunc, NextLfwiFunc, WakeupFpeFunc, ClientDiedFunc,
+ LoadGlyphsFunc, StartLaFunc, NextLaFunc, SetPathFunc);
+void (*__remove_fs_handlers)(FontPathElementPtr, BlockHandlerProcPtr, Bool);
+void **__ptr_serverClient;
+int (*__set_font_authorizations)(char **, int *, ClientPtr);
+int (*__StoreFontClientFont)(FontPtr, Font);
+Atom (*__MakeAtom)(const char *, unsigned, int);
+int (*__ValidAtom)(Atom);
+char *(*__NameForAtom)(Atom);
+unsigned long *__ptr_serverGeneration;
+void (*__register_fpe_functions)(void);
+#else /* NO_WEAK_SYMBOLS && PIC */
+#define OVERRIDE_DATA(sym)
+#define OVERRIDE_SYMBOL(sym,...)
+#define OVERRIDE_VA_SYMBOL(sym,f)
+#endif
+
/* This is really just a hack for now... __APPLE__ really should be using
* the weak symbols route above, but it's causing an as-yet unresolved issue,
* so we're instead building with flat_namespace.
@@ -29,13 +77,12 @@
#endif
extern FontPtr find_old_font ( FSID id );
-extern int set_font_authorizations ( char **authorizations,
- int *authlen,
+extern int set_font_authorizations ( char **authorizations,
+ int *authlen,
ClientPtr client );
extern unsigned long GetTimeInMillis (void);
extern void ErrorF(const char *format, ...);
-extern void FatalError(const char *format, ...);
/* end of file */