diff options
author | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2019-09-05 19:08:10 +0200 |
---|---|---|
committer | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2019-09-05 19:08:10 +0200 |
commit | f8a92529ec04b560b5b9e647b976892412f78134 (patch) | |
tree | 5308d7f500df46ef64423708ed40a37675f4020c /include/sqfs/table.h | |
parent | 320ae4f8e752f6652c7b5c8201d7267cd4de17c1 (diff) |
Fix API visibility for libsquashfs.so
This commit adds a "predef.h" header to libsquashfs that exposes two
macros, SQFS_API and SQFS_INTERNAL that are used to explicilty set
the visibiliy of stuff that ends up in libsquashfs to default or
hidden.
For compatibillity with Windows which may at some point eventually be
considered, the SQFS_API define is set to dllexport IF the cpp symbol
SQFS_BUILDING_DLL is defined and set to import otherwise.
Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'include/sqfs/table.h')
-rw-r--r-- | include/sqfs/table.h | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/include/sqfs/table.h b/include/sqfs/table.h index b5eeb54..0bd3112 100644 --- a/include/sqfs/table.h +++ b/include/sqfs/table.h @@ -7,6 +7,7 @@ #ifndef SQFS_TABLE_H #define SQFS_TABLE_H +#include "sqfs/predef.h" #include "sqfs/compress.h" #include "sqfs/super.h" @@ -28,12 +29,14 @@ extern "C" { Returns 0 on success. Internally prints error messages to stderr. */ -int sqfs_write_table(int outfd, sqfs_super_t *super, sqfs_compressor_t *cmp, - const void *data, size_t table_size, uint64_t *start); - -void *sqfs_read_table(int fd, sqfs_compressor_t *cmp, size_t table_size, - uint64_t location, uint64_t lower_limit, - uint64_t upper_limit); +SQFS_API int sqfs_write_table(int outfd, sqfs_super_t *super, + sqfs_compressor_t *cmp, + const void *data, size_t table_size, + uint64_t *start); + +SQFS_API void *sqfs_read_table(int fd, sqfs_compressor_t *cmp, + size_t table_size, uint64_t location, + uint64_t lower_limit, uint64_t upper_limit); #ifdef __cplusplus } |