summaryrefslogtreecommitdiff
path: root/goo
diff options
context:
space:
mode:
authorAlbert Astals Cid <aacid@kde.org>2021-01-17 18:31:19 +0100
committerAlbert Astals Cid <tsdgeos@yahoo.es>2021-03-01 21:37:34 +0000
commitce1fcd4352f920a59d965310440be18ff48acb8f (patch)
tree63eade90c9942eb9da6e6e526941c5723ef95ef9 /goo
parentd1e5c5b29214d82f43eb72d51b2df5184fcbbe33 (diff)
Hide symbols by default
Use cmake for better import/export defines
Diffstat (limited to 'goo')
-rw-r--r--goo/GooString.h4
-rw-r--r--goo/GooTimer.h4
-rw-r--r--goo/ImgWriter.h4
-rw-r--r--goo/JpegWriter.h3
-rw-r--r--goo/NetPBMWriter.h3
-rw-r--r--goo/PNGWriter.h3
-rw-r--r--goo/TiffWriter.h3
-rw-r--r--goo/gbase64.h4
-rw-r--r--goo/gbasename.h3
-rw-r--r--goo/gfile.h15
-rw-r--r--goo/glibc.h7
-rw-r--r--goo/gstrtod.h4
12 files changed, 37 insertions, 20 deletions
diff --git a/goo/GooString.h b/goo/GooString.h
index 11762645..81c2d5b7 100644
--- a/goo/GooString.h
+++ b/goo/GooString.h
@@ -38,6 +38,8 @@
#ifndef GooString_H
#define GooString_H
+#include "poppler_private_export.h"
+
#include <cstdarg>
#include <string>
@@ -47,7 +49,7 @@
# define GOOSTRING_FORMAT
#endif
-class GooString : private std::string
+class POPPLER_PRIVATE_EXPORT GooString : private std::string
{
public:
// Create an empty string.
diff --git a/goo/GooTimer.h b/goo/GooTimer.h
index c4faaaba..00b85618 100644
--- a/goo/GooTimer.h
+++ b/goo/GooTimer.h
@@ -18,6 +18,8 @@
#define GOOTIMER_H
#include "poppler-config.h"
+#include "poppler_private_export.h"
+
#ifdef HAVE_GETTIMEOFDAY
# include <sys/time.h>
#endif
@@ -33,7 +35,7 @@
// GooTimer
//------------------------------------------------------------------------
-class GooTimer
+class POPPLER_PRIVATE_EXPORT GooTimer
{
public:
// Create a new timer.
diff --git a/goo/ImgWriter.h b/goo/ImgWriter.h
index e69b59e1..64f60efb 100644
--- a/goo/ImgWriter.h
+++ b/goo/ImgWriter.h
@@ -15,9 +15,11 @@
#ifndef IMGWRITER_H
#define IMGWRITER_H
+#include "poppler_private_export.h"
+
#include <cstdio>
-class ImgWriter
+class POPPLER_PRIVATE_EXPORT ImgWriter
{
public:
ImgWriter() = default;
diff --git a/goo/JpegWriter.h b/goo/JpegWriter.h
index a598ec34..8cdbc70e 100644
--- a/goo/JpegWriter.h
+++ b/goo/JpegWriter.h
@@ -19,6 +19,7 @@
#define JPEGWRITER_H
#include "poppler-config.h"
+#include "poppler_private_export.h"
#ifdef ENABLE_LIBJPEG
@@ -27,7 +28,7 @@
struct JpegWriterPrivate;
-class JpegWriter : public ImgWriter
+class POPPLER_PRIVATE_EXPORT JpegWriter : public ImgWriter
{
public:
/* RGB - 3 bytes/pixel
diff --git a/goo/NetPBMWriter.h b/goo/NetPBMWriter.h
index 9f864a1d..c3e5faa8 100644
--- a/goo/NetPBMWriter.h
+++ b/goo/NetPBMWriter.h
@@ -16,6 +16,7 @@
#define NETPBMWRITER_H
#include "poppler-config.h"
+#include "poppler_private_export.h"
#include "ImgWriter.h"
@@ -24,7 +25,7 @@
// http://netpbm.sourceforge.net/doc/pbm.html
// http://netpbm.sourceforge.net/doc/ppm.html
-class NetPBMWriter : public ImgWriter
+class POPPLER_PRIVATE_EXPORT NetPBMWriter : public ImgWriter
{
public:
/* RGB - 3 bytes/pixel
diff --git a/goo/PNGWriter.h b/goo/PNGWriter.h
index 67281258..f2f94c17 100644
--- a/goo/PNGWriter.h
+++ b/goo/PNGWriter.h
@@ -17,6 +17,7 @@
#define PNGWRITER_H
#include "poppler-config.h"
+#include "poppler_private_export.h"
#ifdef ENABLE_LIBPNG
@@ -24,7 +25,7 @@
struct PNGWriterPrivate;
-class PNGWriter : public ImgWriter
+class POPPLER_PRIVATE_EXPORT PNGWriter : public ImgWriter
{
public:
/* RGB - 3 bytes/pixel
diff --git a/goo/TiffWriter.h b/goo/TiffWriter.h
index 2f7159ea..d0358efc 100644
--- a/goo/TiffWriter.h
+++ b/goo/TiffWriter.h
@@ -15,6 +15,7 @@
#define TIFFWRITER_H
#include "poppler-config.h"
+#include "poppler_private_export.h"
#ifdef ENABLE_LIBTIFF
@@ -23,7 +24,7 @@
struct TiffWriterPrivate;
-class TiffWriter : public ImgWriter
+class POPPLER_PRIVATE_EXPORT TiffWriter : public ImgWriter
{
public:
/* RGB - 3 bytes/pixel
diff --git a/goo/gbase64.h b/goo/gbase64.h
index 0a402773..08990687 100644
--- a/goo/gbase64.h
+++ b/goo/gbase64.h
@@ -15,10 +15,12 @@
#ifndef GOO_GBASE64_H
#define GOO_GBASE64_H
+#include "poppler_private_export.h"
+
#include <string>
#include <vector>
-std::string gbase64Encode(const void *input, size_t len);
+std::string POPPLER_PRIVATE_EXPORT gbase64Encode(const void *input, size_t len);
inline std::string gbase64Encode(const std::vector<char> &input)
{
diff --git a/goo/gbasename.h b/goo/gbasename.h
index 5e8d6c45..33e97649 100644
--- a/goo/gbasename.h
+++ b/goo/gbasename.h
@@ -17,7 +17,8 @@
#define GBASENAME_H
#include <string>
+#include "poppler_private_export.h"
-std::string gbasename(const char *filename);
+std::string POPPLER_PRIVATE_EXPORT gbasename(const char *filename);
#endif // ndef GBASENAME_H
diff --git a/goo/gfile.h b/goo/gfile.h
index 4eb2cf4a..97cd517f 100644
--- a/goo/gfile.h
+++ b/goo/gfile.h
@@ -36,6 +36,7 @@
#define GFILE_H
#include "poppler-config.h"
+#include "poppler_private_export.h"
#include <cstdio>
#include <cstdlib>
#include <cstddef>
@@ -82,27 +83,27 @@ typedef long long Goffset;
// Append a file name to a path string. <path> may be an empty
// string, denoting the current directory). Returns <path>.
-extern GooString *appendToPath(GooString *path, const char *fileName);
+extern GooString POPPLER_PRIVATE_EXPORT *appendToPath(GooString *path, const char *fileName);
#ifndef _WIN32
// Open a file descriptor
// Could be implemented on WIN32 too, but the only external caller of
// this function is not used on WIN32
-extern int openFileDescriptor(const char *path, int flags);
+extern int POPPLER_PRIVATE_EXPORT openFileDescriptor(const char *path, int flags);
#endif
// Open a file. On Windows, this converts the path from UTF-8 to
// UCS-2 and calls _wfopen (if available). On other OSes, this simply
// calls fopen.
-extern FILE *openFile(const char *path, const char *mode);
+extern FILE POPPLER_PRIVATE_EXPORT *openFile(const char *path, const char *mode);
// Just like fgets, but handles Unix, Mac, and/or DOS end-of-line
// conventions.
-extern char *getLine(char *buf, int size, FILE *f);
+extern char POPPLER_PRIVATE_EXPORT *getLine(char *buf, int size, FILE *f);
// Like fseek/ftell but uses platform specific variants that support large files
-extern int Gfseek(FILE *f, Goffset offset, int whence);
-extern Goffset Gftell(FILE *f);
+extern int POPPLER_PRIVATE_EXPORT Gfseek(FILE *f, Goffset offset, int whence);
+extern Goffset POPPLER_PRIVATE_EXPORT Gftell(FILE *f);
// Largest offset supported by Gfseek/Gftell
extern Goffset GoffsetMax();
@@ -111,7 +112,7 @@ extern Goffset GoffsetMax();
// GooFile
//------------------------------------------------------------------------
-class GooFile
+class POPPLER_PRIVATE_EXPORT GooFile
{
public:
GooFile(const GooFile &) = delete;
diff --git a/goo/glibc.h b/goo/glibc.h
index fc8b12cf..3de68e9f 100644
--- a/goo/glibc.h
+++ b/goo/glibc.h
@@ -15,19 +15,20 @@
#define GLIBC_H
#include "config.h"
+#include "poppler_private_export.h"
#include <ctime>
#ifndef HAVE_GMTIME_R
-struct tm *gmtime_r(const time_t *timep, struct tm *result);
+struct tm POPPLER_PRIVATE_EXPORT *gmtime_r(const time_t *timep, struct tm *result);
#endif
#ifndef HAVE_LOCALTIME_R
-struct tm *localtime_r(const time_t *timep, struct tm *result);
+struct tm POPPLER_PRIVATE_EXPORT *localtime_r(const time_t *timep, struct tm *result);
#endif
#ifndef HAVE_TIMEGM
-time_t timegm(struct tm *tm);
+time_t POPPLER_PRIVATE_EXPORT timegm(struct tm *tm);
#endif
#ifndef HAVE_STRTOK_R
diff --git a/goo/gstrtod.h b/goo/gstrtod.h
index 66ba4694..fbf1872f 100644
--- a/goo/gstrtod.h
+++ b/goo/gstrtod.h
@@ -23,6 +23,8 @@
#ifndef GSTRTOD_H
#define GSTRTOD_H
+#include "poppler_private_export.h"
+
#ifdef __cplusplus
extern "C" {
#endif
@@ -33,7 +35,7 @@ extern "C" {
* A limitation of the implementation is that this function
* will still accept localized versions of infinities and NANs.
*/
-double gatof(const char *nptr);
+double POPPLER_PRIVATE_EXPORT gatof(const char *nptr);
double gstrtod(const char *nptr, char **endptr);
#ifdef __cplusplus