summaryrefslogtreecommitdiff
path: root/dln.c
diff options
context:
space:
mode:
Diffstat (limited to 'dln.c')
-rw-r--r--dln.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/dln.c b/dln.c
index d3408fb0f6..d27d79e8e5 100644
--- a/dln.c
+++ b/dln.c
@@ -1268,6 +1268,16 @@ dln_load(const char *file)
# define RTLD_GLOBAL 0
#endif
+#if defined __SYMBIAN32__
+ { /* Need backslash in the path again */
+ char *p;
+ for (p = (char *)file; *p; p++) {
+ if (*p == '/') {
+ *p = '\\';
+ }
+ }
+ }
+#endif
/* Load file */
if ((handle = (void*)dlopen(file, RTLD_LAZY|RTLD_GLOBAL)) == NULL) {
error = dln_strerror();
@@ -1275,6 +1285,10 @@ dln_load(const char *file)
}
init_fct = (void(*)())dlsym(handle, buf);
+#if defined __SYMBIAN32__
+ if (init_fct == NULL)
+ init_fct = (void(*)())dlsym(handle, "1"); /* Some Symbian versions do not support symbol table in DLL, ordinal numbers only */
+#endif
if (init_fct == NULL) {
error = DLN_ERROR();
dlclose(handle);