summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorMichael Stahl <mst@openoffice.org>2011-04-15 17:27:07 +0000
committerBjoern Michaelsen <bjoern.michaelsen@canonical.com>2011-06-17 17:38:42 +0200
commit0d96c68e594c46f20ac300981833e0526fce1e69 (patch)
treee791e6b051ed0f605adb95668855b8c0fc0a272d /sw
parent5758400c3d092a35c31b00547da48a57667b0a92 (diff)
gnumake4: #i117845#: sw: do not link objects into two libraries [hg:0c13175d5e5e]
Diffstat (limited to 'sw')
-rw-r--r--sw/Library_sw.mk2
-rw-r--r--sw/Library_swd.mk3
-rw-r--r--sw/Library_swui.mk1
-rw-r--r--sw/inc/iodetect.hxx16
-rw-r--r--sw/source/filter/basflt/iodetect.cxx4
5 files changed, 16 insertions, 10 deletions
diff --git a/sw/Library_sw.mk b/sw/Library_sw.mk
index caffa1357e22..0b1ff66ca2e7 100644
--- a/sw/Library_sw.mk
+++ b/sw/Library_sw.mk
@@ -71,6 +71,7 @@ $(eval $(call gb_Library_add_linked_libs,sw,\
svt \
svx \
svxcore \
+ swd \
tk \
tl \
ucbhelper \
@@ -472,7 +473,6 @@ $(eval $(call gb_Library_add_exception_objects,sw,\
sw/source/filter/ascii/wrtasc \
sw/source/filter/basflt/docfact \
sw/source/filter/basflt/fltini \
- sw/source/filter/basflt/iodetect \
sw/source/filter/basflt/shellio \
sw/source/filter/html/SwAppletImpl \
sw/source/filter/html/css1atr \
diff --git a/sw/Library_swd.mk b/sw/Library_swd.mk
index 67898f996bed..32bcc4868126 100644
--- a/sw/Library_swd.mk
+++ b/sw/Library_swd.mk
@@ -41,6 +41,8 @@ $(eval $(call gb_Library_set_include,swd,\
-I$(OUTDIR)/inc/offuh \
))
+$(eval $(call gb_Library_add_defs,swd,\
+ -DSWD_DLLIMPLEMENTATION \
$(eval $(call gb_Library_add_linked_libs,swd,\
comphelper \
cppu \
@@ -58,7 +60,6 @@ $(eval $(call gb_Library_add_linked_libs,swd,\
))
$(eval $(call gb_Library_add_exception_objects,swd,\
- sw/source/core/except/errhdl \
sw/source/filter/basflt/iodetect \
sw/source/ui/uno/detreg \
sw/source/ui/uno/swdet2 \
diff --git a/sw/Library_swui.mk b/sw/Library_swui.mk
index 9701339798a8..386a10cf5d4d 100644
--- a/sw/Library_swui.mk
+++ b/sw/Library_swui.mk
@@ -56,6 +56,7 @@ $(eval $(call gb_Library_add_linked_libs,swui,\
svx \
svxcore \
sw \
+ swd \
tk \
tl \
ucbhelper \
diff --git a/sw/inc/iodetect.hxx b/sw/inc/iodetect.hxx
index 2fb66559b98d..315279b17950 100644
--- a/sw/inc/iodetect.hxx
+++ b/sw/inc/iodetect.hxx
@@ -34,7 +34,7 @@
#include <osl/endian.h>
#include <errhdl.hxx> // for ASSERT
#include <tools/string.hxx>
-#include <swdllapi.h>
+#include <swddllapi.h>
#define FILTER_RTF "RTF" // RTF-Filter
#define sRtfWH "WH_RTF"
@@ -86,7 +86,7 @@ enum ReaderWriterEnum {
MAXFILTER
};
-extern SwIoDetect aFilterDetect[];
+extern SWD_DLLPUBLIC SwIoDetect aFilterDetect[];
// Die folgende Klasse ist ein Wrappe fuer die Basic-I/O-Funktionen
// des Writer 3.0. Alles ist statisch. Alle u.a. Filternamen sind die
@@ -97,13 +97,15 @@ class SwIoSystem
{
public:
// suche ueber den internen FormatNamen den Filtereintrag
- SW_DLLPUBLIC static const SfxFilter* GetFilterOfFormat( const String& rFormat,
+ SWD_DLLPUBLIC static const SfxFilter*
+ GetFilterOfFormat( const String& rFormat,
const SfxFilterContainer* pCnt = 0 );
// Feststellen des zu verwendenden Filters fuer die uebergebene
// Datei. Der Filtername wird zurueckgeliefert. Konnte kein Filter
// zurueckgeliefert werden, wird der Name des ASCII-Filters geliefert!
- static const SfxFilter* GetFileFilter( const String& rFileName,
+ SWD_DLLPUBLIC static const SfxFilter*
+ GetFileFilter( const String& rFileName,
const String& rPrefFltName,
SfxMedium* pMedium = 0 );
@@ -115,13 +117,15 @@ public:
static sal_Bool IsValidStgFilter( SotStorage& , const SfxFilter& );
static sal_Bool IsValidStgFilter( const com::sun::star::uno::Reference < com::sun::star::embed::XStorage >& rStg, const SfxFilter& rFilter);
- static bool IsDetectableText( const sal_Char* pBuf, sal_uLong &rLen,
+ SWD_DLLPUBLIC static bool
+ IsDetectableText( const sal_Char* pBuf, sal_uLong &rLen,
CharSet *pCharSet=0, bool *pSwap=0, LineEnd *pLineEnd=0, bool bEncodedFilter = false );
// static bool IsDetectableW4W(const String& rFileName, const String& rUserData);
static const SfxFilter* GetTextFilter( const sal_Char* pBuf, sal_uLong nLen );
- static const String GetSubStorageName( const SfxFilter& rFltr );
+ SWD_DLLPUBLIC static const String
+ GetSubStorageName( const SfxFilter& rFltr );
};
#endif
diff --git a/sw/source/filter/basflt/iodetect.cxx b/sw/source/filter/basflt/iodetect.cxx
index aaabab41895f..a5acfa1782f7 100644
--- a/sw/source/filter/basflt/iodetect.cxx
+++ b/sw/source/filter/basflt/iodetect.cxx
@@ -201,9 +201,9 @@ sal_Bool SwIoSystem::IsValidStgFilter(SotStorage& rStg, const SfxFilter& rFilter
void TerminateBuffer(sal_Char *pBuffer, sal_uLong nBytesRead, sal_uLong nBufferLen)
{
- ASSERT(nBytesRead <= nBufferLen - 2,
+ OSL_ENSURE(nBytesRead <= nBufferLen - 2,
"what you read must be less than the max + null termination");
- ASSERT(!(nBufferLen & 0x00000001), "nMaxReadBuf must be an even number");
+ OSL_ENSURE(!(nBufferLen & 0x00000001),"nMaxReadBuf must be an even number");
if (nBytesRead <= nBufferLen - 2)
{
pBuffer[nBytesRead] = '\0';