headers: Don't make private structures public
authorMichael Tremer <michael.tremer@ipfire.org>
Fri, 29 Dec 2017 11:22:22 +0000 (11:22 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Fri, 29 Dec 2017 11:22:22 +0000 (11:22 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Makefile.am
src/loc/private.h

index eddef93..0572567 100644 (file)
@@ -60,6 +60,7 @@ EXTRA_DIST += src/libloc.sym
 
 src_libloc_la_CFLAGS = \
        $(AM_CFLAGS) \
+       -DLIBLOC_PRIVATE \
        -fvisibility=hidden
 
 src_libloc_la_LDFLAGS = \
index abfa59d..19e0398 100644 (file)
@@ -17,6 +17,8 @@
 #ifndef LIBLOC_PRIVATE_H
 #define LIBLOC_PRIVATE_H
 
+#ifdef LIBLOC_PRIVATE
+
 #include <stdbool.h>
 #include <syslog.h>
 
@@ -55,3 +57,4 @@ void loc_log(struct loc_ctx *ctx,
        const char *format, ...) __attribute__((format(printf, 6, 7)));
 
 #endif
+#endif