summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/LibreOfficeKit/LibreOfficeKitInit.h38
1 files changed, 22 insertions, 16 deletions
diff --git a/include/LibreOfficeKit/LibreOfficeKitInit.h b/include/LibreOfficeKit/LibreOfficeKitInit.h
index 8a48bd8392be..ccd42863ba25 100644
--- a/include/LibreOfficeKit/LibreOfficeKitInit.h
+++ b/include/LibreOfficeKit/LibreOfficeKitInit.h
@@ -12,11 +12,6 @@
#include <LibreOfficeKit/LibreOfficeKit.h>
-#ifdef __cplusplus
-extern "C"
-{
-#endif
-
#if defined __GNUC__ || defined __clang__
# define LOK_TOLERATE_UNUSED __attribute__((used))
#else
@@ -48,6 +43,26 @@ extern "C"
#endif
#define SEPARATOR '/'
+#else
+
+ #if !defined WIN32_LEAN_AND_MEAN
+ #define WIN32_LEAN_AND_MEAN
+ #endif
+ #include <windows.h>
+ #define TARGET_LIB "sofficeapp" ".dll"
+ #define TARGET_MERGED_LIB "mergedlo" ".dll"
+ #define SEPARATOR '\\'
+ #define UNOPATH "\\..\\URE\\bin"
+
+#endif
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+#ifndef _WIN32
+
#if !defined(IOS)
static void *lok_loadlib(const char *pFN)
{
@@ -88,15 +103,6 @@ extern "C"
#else
- #if !defined WIN32_LEAN_AND_MEAN
- #define WIN32_LEAN_AND_MEAN
- #endif
- #include <windows.h>
- #define TARGET_LIB "sofficeapp" ".dll"
- #define TARGET_MERGED_LIB "mergedlo" ".dll"
- #define SEPARATOR '\\'
- #define UNOPATH "\\..\\URE\\bin"
-
static void *lok_loadlib(const char *pFN)
{
return (void *) LoadLibraryA(pFN);
@@ -345,12 +351,12 @@ int lok_preinit( const char *install_path, const char *user_profile_url )
#undef SEPARATOR // It is used at least in enum class MenuItemType
-#endif // defined(__linux__) || defined (__FreeBSD__) || defined(_AIX) || defined(_WIN32) || defined(__APPLE__)
-
#ifdef __cplusplus
}
#endif
+#endif // defined(__linux__) || defined (__FreeBSD__) || defined(_AIX) || defined(_WIN32) || defined(__APPLE__)
+
#endif // INCLUDED_LIBREOFFICEKIT_LIBREOFFICEKITINIT_H
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */