diff options
author | Tor Lillqvist <tlillqvist@suse.com> | 2012-11-27 11:05:36 +0200 |
---|---|---|
committer | Tor Lillqvist <tml@iki.fi> | 2012-11-27 13:07:12 +0200 |
commit | b0505048022efeb5c577232534a1c404d435e8b9 (patch) | |
tree | 58e4a86ab58cd5a5e9ae2b68f71751f287290a40 /tools | |
parent | df25641bc1f38d2c9228cea42318a58c4dc2ead5 (diff) |
Simplify SVLIBRARY
No need for a __DLLEXTENSION macro that is used nowhere else, and
which is in the namespace reserved for the compiler implementation
(two initial underscores) even. Just one #ifdef tree is enough.
Change-Id: Ib2612ceba385250792c52066a720b220eb294aea
Diffstat (limited to 'tools')
-rw-r--r-- | tools/inc/tools/solar.h | 28 |
1 files changed, 9 insertions, 19 deletions
diff --git a/tools/inc/tools/solar.h b/tools/inc/tools/solar.h index 0812f3faf630..48d57ce7f6f6 100644 --- a/tools/inc/tools/solar.h +++ b/tools/inc/tools/solar.h @@ -152,36 +152,26 @@ template<typename T> inline T Abs(T a) { return (a>=0?a:-a); } #pragma warning(error : 4002 4003) #endif -// dll file extensions - -#if defined WNT - #define __DLLEXTENSION "lo" -#elif defined MACOSX - #define __DLLEXTENSION "lo.dylib" -#elif defined UNX - #define __DLLEXTENSION "lo.so" -#else - #error unknown platform -#endif - #define UniString String #define XubString String #define xub_StrLen sal_uInt16 -#define LIBRARY_CONCAT3( s1, s2, s3 ) \ +#define STRING_CONCAT3( s1, s2, s3 ) \ s1 s2 s3 -#define LIBRARY_CONCAT4( s1, s2, s3, s4 ) \ - s1 s2 s3 s4 + +// dll file extensions #if defined WNT #define SVLIBRARY( Base ) \ - LIBRARY_CONCAT3( Base, __DLLEXTENSION, ".DLL" ) + STRING_CONCAT3( Base, "lo", ".dll" ) +#elif defined MACOSX +#define SVLIBRARY( Base ) \ + STRING_CONCAT3( "lib", Base, "lo.dylib" ) #elif defined UNX #define SVLIBRARY( Base ) \ - LIBRARY_CONCAT3( "lib", Base, __DLLEXTENSION ) + STRING_CONCAT3( "lib", Base, "lo.so" ) #else -#define SVLIBRARY( Base ) \ - LIBRARY_CONCAT2( Base, __DLLEXTENSION ) + #error unknown platform #endif #endif |