Uniquify uno_initEnvironment and uno_ext_getMapping in the static linking case
This commit is contained in:
@@ -196,7 +196,7 @@ static void SAL_CALL environmentDisposing(
|
|||||||
&bridges::cpp_uno::shared::g_moduleCount.modCnt );
|
&bridges::cpp_uno::shared::g_moduleCount.modCnt );
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef IOS
|
#ifndef DISABLE_DYNLOADING
|
||||||
|
|
||||||
SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL component_canUnload(TimeValue * pTime) SAL_THROW_EXTERN_C() {
|
SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL component_canUnload(TimeValue * pTime) SAL_THROW_EXTERN_C() {
|
||||||
return bridges::cpp_uno::shared::g_moduleCount.canUnload(
|
return bridges::cpp_uno::shared::g_moduleCount.canUnload(
|
||||||
@@ -205,8 +205,8 @@ SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL component_canUnload(TimeValue * pTime) SA
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef IOS
|
#ifdef DISABLE_DYNLOADING
|
||||||
#define uno_initEnvironment gcc3_uno_initEnvironment
|
#define uno_initEnvironment CPPU_ENV_uno_initEnvironment
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
void SAL_CALL uno_initEnvironment(uno_Environment * pCppEnv)
|
void SAL_CALL uno_initEnvironment(uno_Environment * pCppEnv)
|
||||||
@@ -227,6 +227,10 @@ void SAL_CALL uno_initEnvironment(uno_Environment * pCppEnv)
|
|||||||
pCppEnv->environmentDisposing = environmentDisposing;
|
pCppEnv->environmentDisposing = environmentDisposing;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef DISABLE_DYNLOADING
|
||||||
|
#define uno_ext_getMapping CPPU_ENV_uno_ext_getMapping
|
||||||
|
#endif
|
||||||
|
|
||||||
void SAL_CALL uno_ext_getMapping(
|
void SAL_CALL uno_ext_getMapping(
|
||||||
uno_Mapping ** ppMapping, uno_Environment * pFrom, uno_Environment * pTo)
|
uno_Mapping ** ppMapping, uno_Environment * pFrom, uno_Environment * pTo)
|
||||||
SAL_THROW_EXTERN_C()
|
SAL_THROW_EXTERN_C()
|
||||||
|
@@ -266,6 +266,12 @@ typedef struct _uno_ExtEnvironment
|
|||||||
typedef void (SAL_CALL * uno_initEnvironmentFunc)( uno_Environment * pEnv );
|
typedef void (SAL_CALL * uno_initEnvironmentFunc)( uno_Environment * pEnv );
|
||||||
#define UNO_INIT_ENVIRONMENT "uno_initEnvironment"
|
#define UNO_INIT_ENVIRONMENT "uno_initEnvironment"
|
||||||
|
|
||||||
|
#ifdef DISABLE_DYNLOADING
|
||||||
|
/* We link statically and have just one kind of environment */
|
||||||
|
void SAL_CALL CPPU_ENV_uno_initEnvironment( uno_Environment * Env )
|
||||||
|
SAL_THROW_EXTERN_C();
|
||||||
|
#endif
|
||||||
|
|
||||||
/** Gets a specific environment. If the specified environment does not exist, then a default one
|
/** Gets a specific environment. If the specified environment does not exist, then a default one
|
||||||
is created and registered. The environment revokes itself on last release() call.
|
is created and registered. The environment revokes itself on last release() call.
|
||||||
|
|
||||||
@@ -375,12 +381,6 @@ CPPU_DLLPUBLIC void SAL_CALL uno_Environment_enter(uno_Environment * pEnv)
|
|||||||
CPPU_DLLPUBLIC int SAL_CALL uno_Environment_isValid(uno_Environment * pEnv, rtl_uString ** pReason)
|
CPPU_DLLPUBLIC int SAL_CALL uno_Environment_isValid(uno_Environment * pEnv, rtl_uString ** pReason)
|
||||||
SAL_THROW_EXTERN_C();
|
SAL_THROW_EXTERN_C();
|
||||||
|
|
||||||
#ifdef IOS
|
|
||||||
/* We link statically on iOS and have just one kind of environment */
|
|
||||||
void SAL_CALL gcc3_uno_initEnvironment(uno_Environment *pCppEnv)
|
|
||||||
SAL_THROW_EXTERN_C();
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@@ -195,6 +195,15 @@ typedef void (SAL_CALL * uno_ext_getMappingFunc)(
|
|||||||
struct _uno_Environment * pFrom,
|
struct _uno_Environment * pFrom,
|
||||||
struct _uno_Environment * pTo );
|
struct _uno_Environment * pTo );
|
||||||
|
|
||||||
|
#ifdef DISABLE_DYNLOADING
|
||||||
|
/* Static linking, this is the uno_ext_getMapping function in the C++/UNO bridge */
|
||||||
|
void SAL_CALL CPPU_ENV_uno_ext_getMapping(
|
||||||
|
struct _uno_Mapping ** ppMapping,
|
||||||
|
struct _uno_Environment * pFrom,
|
||||||
|
struct _uno_Environment * pTo )
|
||||||
|
SAL_THROW_EXTERN_C();
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@@ -348,6 +348,13 @@ int AffineBridge::v_isValid(rtl::OUString * pReason)
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef DISABLE_DYNLOADING
|
||||||
|
|
||||||
|
#define uno_initEnvironment affine_uno_uno_initEnvironment
|
||||||
|
#define uno_ext_getMapping affine_uno_uno_ext_getMapping
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
extern "C" void SAL_DLLPUBLIC_EXPORT SAL_CALL uno_initEnvironment(uno_Environment * pEnv)
|
extern "C" void SAL_DLLPUBLIC_EXPORT SAL_CALL uno_initEnvironment(uno_Environment * pEnv)
|
||||||
SAL_THROW_EXTERN_C()
|
SAL_THROW_EXTERN_C()
|
||||||
{
|
{
|
||||||
|
@@ -262,6 +262,13 @@ void LogProbe(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef DISABLE_DYNLOADING
|
||||||
|
|
||||||
|
#define uno_initEnvironment log_uno_uno_initEnvironment
|
||||||
|
#define uno_ext_getMapping log_uno_uno_ext_getMapping
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
extern "C" void SAL_DLLPUBLIC_EXPORT SAL_CALL uno_initEnvironment(uno_Environment * pEnv)
|
extern "C" void SAL_DLLPUBLIC_EXPORT SAL_CALL uno_initEnvironment(uno_Environment * pEnv)
|
||||||
SAL_THROW_EXTERN_C()
|
SAL_THROW_EXTERN_C()
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user