]> git.pld-linux.org Git - packages/csync2.git/blob - csync2-fix-sonames.patch
- fix building with librsync 1.0+
[packages/csync2.git] / csync2-fix-sonames.patch
1 Index: csync2-2.0+git.1368794815.cf835a7/db_mysql.c
2 ===================================================================
3 --- csync2-2.0+git.1368794815.cf835a7.orig/db_mysql.c
4 +++ csync2-2.0+git.1368794815.cf835a7/db_mysql.c
5 @@ -53,16 +53,16 @@ static void *dl_handle;
6  
7  static void db_mysql_dlopen(void)
8  {
9 -       csync_debug(2, "Opening shared library libmysqlclient.so\n");
10 -       dl_handle = dlopen("libmysqlclient.so", RTLD_LAZY);
11 +       csync_debug(2, "Opening shared library libmysqlclient.so.18\n");
12 +       dl_handle = dlopen("libmysqlclient.so.18", RTLD_LAZY);
13         if (dl_handle == NULL) {
14                 csync_fatal
15 -                   ("Could not open libmysqlclient.so: %s\n"
16 +                   ("Could not open libmysqlclient.so.18: %s\n"
17                      "Please install Mysql client library (libmysqlclient) or use other database (sqlite, postgres)\n",
18                      dlerror());
19         }
20  
21 -       csync_debug(2, "Reading symbols from shared library libmysqlclient.so\n");
22 +       csync_debug(2, "Reading symbols from shared library libmysqlclient.so.18\n");
23  
24         LOOKUP_SYMBOL(dl_handle, mysql_init);
25         LOOKUP_SYMBOL(dl_handle, mysql_real_connect);
26 Index: csync2-2.0+git.1368794815.cf835a7/db_postgres.c
27 ===================================================================
28 --- csync2-2.0+git.1368794815.cf835a7.orig/db_postgres.c
29 +++ csync2-2.0+git.1368794815.cf835a7/db_postgres.c
30 @@ -58,16 +58,16 @@ static void *dl_handle;
31  
32  static void db_postgres_dlopen(void)
33  {
34 -       csync_debug(2, "Opening shared library libpq.so\n");
35 +       csync_debug(2, "Opening shared library libpq.so.5\n");
36  
37 -       dl_handle = dlopen("libpq.so", RTLD_LAZY);
38 +       dl_handle = dlopen("libpq.so.5", RTLD_LAZY);
39         if (dl_handle == NULL) {
40                 csync_fatal
41 -                   ("Could not open libpq.so: %s\n"
42 +                   ("Could not open libpq.so.5: %s\n"
43                      "Please install postgres client library (libpg) or use other database (sqlite, mysql)\n",
44                      dlerror());
45         }
46 -       csync_debug(2, "Reading symbols from shared library libpq.so\n");
47 +       csync_debug(2, "Reading symbols from shared library libpq.so.5\n");
48  
49         LOOKUP_SYMBOL(dl_handle, PQconnectdb);
50         LOOKUP_SYMBOL(dl_handle, PQstatus);
51 Index: csync2-2.0+git.1368794815.cf835a7/db_sqlite.c
52 ===================================================================
53 --- csync2-2.0+git.1368794815.cf835a7.orig/db_sqlite.c
54 +++ csync2-2.0+git.1368794815.cf835a7/db_sqlite.c
55 @@ -56,16 +56,16 @@ static void *dl_handle;
56  
57  static void db_sqlite3_dlopen(void)
58  {
59 -       csync_debug(2, "Opening shared library libsqlite3.so\n");
60 +       csync_debug(2, "Opening shared library libsqlite3.so.0\n");
61  
62 -       dl_handle = dlopen("libsqlite3.so", RTLD_LAZY);
63 +       dl_handle = dlopen("libsqlite3.so.0", RTLD_LAZY);
64         if (dl_handle == NULL) {
65                 csync_fatal
66 -                   ("Could not open libsqlite3.so: %s\n"
67 +                   ("Could not open libsqlite3.so.0: %s\n"
68                      "Please install sqlite3 client library (libsqlite3) or use other database (postgres, mysql)\n",
69                      dlerror());
70         }
71 -       csync_debug(2, "Reading symbols from shared library libsqlite3.so\n");
72 +       csync_debug(2, "Reading symbols from shared library libsqlite3.so.0\n");
73  
74         LOOKUP_SYMBOL(dl_handle, sqlite3_open);
75         LOOKUP_SYMBOL(dl_handle, sqlite3_close);
76 Index: csync2-2.0+git.1368794815.cf835a7/db_sqlite2.c
77 ===================================================================
78 --- csync2-2.0+git.1368794815.cf835a7.orig/db_sqlite2.c
79 +++ csync2-2.0+git.1368794815.cf835a7/db_sqlite2.c
80 @@ -54,20 +54,17 @@ static void *dl_handle;
81  
82  static void db_sqlite_dlopen(void)
83  {
84 -       csync_debug(2, "Opening shared library libsqlite.so\n");
85 +       csync_debug(2, "Opening shared library libsqlite.so.0\n");
86  
87 -       dl_handle = dlopen("libsqlite.so", RTLD_LAZY);
88 +       dl_handle = dlopen("libsqlite.so.0", RTLD_LAZY);
89         if (dl_handle == NULL) {
90 -               csync_debug(1, "Libsqlite.so not found, trying libsqlite.so.0\n");
91 -               dl_handle = dlopen("libsqlite.so.0", RTLD_LAZY);
92 -               if (dl_handle == NULL) {
93                         csync_fatal
94 -                           ("Could not open libsqlite.so: %s\n"
95 +                           ("Could not open libsqlite.so.0: %s\n"
96                              "Please install sqlite client library (libsqlite) or use other database (postgres, mysql)\n",
97                              dlerror());
98                 }
99         }
100 -       csync_debug(2, "Opening shared library libsqlite.so\n");
101 +       csync_debug(2, "Opening shared library libsqlite.so.0\n");
102  
103         LOOKUP_SYMBOL(dl_handle, sqlite_open);
104         LOOKUP_SYMBOL(dl_handle, sqlite_close);
This page took 0.060293 seconds and 3 git commands to generate.