[PATCH] make Inflater and Deflater classes available for other packages to use
Peter Jentsch
pjotr at guineapics.de
Sat Mar 26 06:14:51 PDT 2011
Currently, those are used within an extension function used by the
Word 2003 ML XSLT filters
---
package/inc/Deflater.hxx | 3 ++-
package/inc/Inflater.hxx | 3 ++-
package/inc/packagedllapi.hxx | 15 +++++++++++++++
package/prj/d.lst | 3 +++
package/source/zipapi/makefile.mk | 2 ++
package/util/makefile.mk | 1 -
package/util/package.pmk | 2 ++
7 files changed, 26 insertions(+), 3 deletions(-)
create mode 100644 package/inc/packagedllapi.hxx
create mode 100644 package/util/package.pmk
diff --git a/package/inc/Deflater.hxx b/package/inc/Deflater.hxx
index 3f2c1fc..d866f7b 100644
--- a/package/inc/Deflater.hxx
+++ b/package/inc/Deflater.hxx
@@ -29,13 +29,14 @@
#define _DEFLATER_HXX_
#include <com/sun/star/uno/Sequence.hxx>
+#include "packagedllapi.hxx"
extern "C"
{
typedef struct z_stream_s z_stream;
}
-class Deflater
+class OOO_DLLPUBLIC_PACKAGE Deflater
{
protected:
com::sun::star::uno::Sequence< sal_Int8 > sInBuffer;
diff --git a/package/inc/Inflater.hxx b/package/inc/Inflater.hxx
index ee7efec..84dd3a4 100644
--- a/package/inc/Inflater.hxx
+++ b/package/inc/Inflater.hxx
@@ -29,12 +29,13 @@
#define _INFLATER_HXX_
#include <com/sun/star/uno/Sequence.hxx>
+#include "packagedllapi.hxx"
extern "C"
{
typedef struct z_stream_s z_stream;
}
-class Inflater
+class OOO_DLLPUBLIC_PACKAGE Inflater
{
protected:
sal_Bool bFinish, bFinished, bSetParams, bNeedDict;
diff --git a/package/inc/packagedllapi.hxx b/package/inc/packagedllapi.hxx
new file mode 100644
index 0000000..f4351d2
--- /dev/null
+++ b/package/inc/packagedllapi.hxx
@@ -0,0 +1,15 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+#ifndef INCLUDED_PACKAGEDLLAPI_H
+#define INCLUDED_PACKAGEDLLAPI_H
+
+#include "sal/types.h"
+
+#if defined(OOO_DLLIMPLEMENTATION_PACKAGE)
+#define OOO_DLLPUBLIC_PACKAGE SAL_DLLPUBLIC_EXPORT
+#else
+#define OOO_DLLPUBLIC_PACKAGE SAL_DLLPUBLIC_IMPORT
+#endif
+
+#endif /* INCLUDED_PACKAGEDLLAPI_H */
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/package/prj/d.lst b/package/prj/d.lst
index 919a171..85f8c19 100644
--- a/package/prj/d.lst
+++ b/package/prj/d.lst
@@ -5,3 +5,6 @@
..\dtd\*.dtd %_DEST%\bin%_EXT%\*.*
..\%__SRC%\misc\package2.component %_DEST%\xml%_EXT%\package2.component
..\%__SRC%\misc\xstor.component %_DEST%\xml%_EXT%\xstor.component
+..\inc\Inflater.hxx %_DEST%\inc%_EXT%\package\Inflater.hxx
+..\inc\Deflater.hxx %_DEST%\inc%_EXT%\package\Deflater.hxx
+..\inc\packagedllapi.hxx %_DEST%\inc%_EXT%\package\packagedllapi.hxx
diff --git a/package/source/zipapi/makefile.mk b/package/source/zipapi/makefile.mk
index 1b941fa..ec8d636 100644
--- a/package/source/zipapi/makefile.mk
+++ b/package/source/zipapi/makefile.mk
@@ -34,12 +34,14 @@ ENABLE_EXCEPTIONS=TRUE
# --- Settings -----------------------------------------------------
.INCLUDE : settings.mk
+.INCLUDE : $(PRJ)$/util$/package.pmk
# --- Files --------------------------------------------------------
.IF "$(L10N_framework)"==""
.IF "$(SYSTEM_ZLIB)" == "YES"
CFLAGS+=-DSYSTEM_ZLIB
.ENDIF
+
SLOFILES= \
$(SLO)$/CRC32.obj \
$(SLO)$/ByteChucker.obj \
diff --git a/package/util/makefile.mk b/package/util/makefile.mk
index 344b2cf..827060a 100644
--- a/package/util/makefile.mk
+++ b/package/util/makefile.mk
@@ -55,7 +55,6 @@ LIB1FILES= \
SHL1TARGET=$(TARGET)$(MAJOR_VERSION)
SHL1IMPLIB=i$(TARGET)
-SHL1VERSIONMAP=$(SOLARENV)$/src$/component.map
SHL1STDLIBS=\
$(CPPULIB) \
diff --git a/package/util/package.pmk b/package/util/package.pmk
new file mode 100644
index 0000000..68c8df4
--- /dev/null
+++ b/package/util/package.pmk
@@ -0,0 +1,2 @@
+VISIBILITY_HIDDEN = TRUE
+CDEFS += -DOOO_DLLIMPLEMENTATION_PACKAGE
\ No newline at end of file
--
1.7.1
--=-szL+c1JEPjOMtJUM1XDu
Content-Disposition: attachment; filename*0=0003-replaced-saxon-j-extension-functions-with-libxslt-cx.pat; filename*1=ch
Content-Type: text/x-patch; name="0003-replaced-saxon-j-extension-functions-with-libxslt-cx.patch"; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
More information about the LibreOffice
mailing list