bump product version to 4.1.6.2
[LibreOffice.git] / cppunit / android.patch
blob59ae4517abf164c53203fd91b28a4cc828f2bf7d
1 --- misc/cppunit-1.13.1/config/ltmain.sh
2 +++ misc/build/cppunit-1.13.1/config/ltmain.sh
3 @@ -3228,6 +3228,12 @@
4 fi
5 else
7 + # Force no versioning suffix for Android thanks to silly
8 + # apkbuilder which doesn't add extra native libs unless their
9 + # name ends with .so
11 + version_type=none
13 # Parse the version information argument.
14 save_ifs="$IFS"; IFS=':'
15 set dummy $vinfo 0 0 0
16 --- misc/cppunit-1.13.1/src/cppunit/UnixDynamicLibraryManager.cpp
17 +++ misc/build/cppunit-1.13.1/src/cppunit/UnixDynamicLibraryManager.cpp
18 @@ -13,7 +13,15 @@
19 DynamicLibraryManager::LibraryHandle
20 DynamicLibraryManager::doLoadLibrary( const std::string &libraryName )
22 +#ifdef __ANDROID__
23 + // Use our enhanced dlopen() wrapper, see sal/osl/android/jni/lo-wrapper.c
24 + void *(*lo_dlopen)(const char *) = (void *(*)(const char *)) dlsym( RTLD_DEFAULT, "lo_dlopen" );
25 + if (lo_dlopen == NULL)
26 + return NULL;
27 + return (*lo_dlopen)( libraryName.c_str() );
28 +#else
29 return ::dlopen( libraryName.c_str(), RTLD_NOW | RTLD_GLOBAL );
30 +#endif