[tracker/extractor-rules-list: 6/11] libtracker-extract: Use same exclusion preprocessor rules as other headers
- From: Martyn James Russell <mr src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker/extractor-rules-list: 6/11] libtracker-extract: Use same exclusion preprocessor rules as other headers
- Date: Tue, 15 Mar 2011 16:06:11 +0000 (UTC)
commit 77b905a0a48ba5dc6bdfa8f3c0a07ade71988953
Author: Martyn Russell <martyn lanedo com>
Date: Tue Mar 15 13:58:59 2011 +0000
libtracker-extract: Use same exclusion preprocessor rules as other headers
i.e. use #error if the header is included outside of tracker-extract.h
.../tracker-extract-module-manager.h | 11 ++++++-----
1 files changed, 6 insertions(+), 5 deletions(-)
---
diff --git a/src/libtracker-extract/tracker-extract-module-manager.h b/src/libtracker-extract/tracker-extract-module-manager.h
index 9a7eca0..fb0f243 100644
--- a/src/libtracker-extract/tracker-extract-module-manager.h
+++ b/src/libtracker-extract/tracker-extract-module-manager.h
@@ -20,14 +20,17 @@
#ifndef __TRACKER_EXTRACT_MODULE_MANAGER_H__
#define __TRACKER_EXTRACT_MODULE_MANAGER_H__
+#if !defined (__LIBTRACKER_EXTRACT_INSIDE__) && !defined (TRACKER_COMPILATION)
+#error "only <libtracker-extract/tracker-extract.h> must be included directly."
+#endif
+
#include <glib.h>
#include <gmodule.h>
+
#include <libtracker-sparql/tracker-sparql.h>
G_BEGIN_DECLS
-#define __LIBTRACKER_EXTRACT_INSIDE__
-
typedef gboolean (* TrackerExtractMetadataFunc) (const gchar *uri,
const gchar *mime_type,
TrackerSparqlBuilder *preupdate,
@@ -37,9 +40,7 @@ typedef gboolean (* TrackerExtractMetadataFunc) (const gchar *uri,
gboolean tracker_extract_module_manager_init (void) G_GNUC_CONST;
GModule * tracker_extract_module_manager_get_for_mimetype (const gchar *mimetype,
TrackerExtractMetadataFunc *func);
-gboolean tracker_extract_module_manager_mimetype_is_handled (const gchar *mimetype);
-
-#undef __LIBTRACKER_EXTRACT_INSIDE__
+gboolean tracker_extract_module_manager_mimetype_is_handled (const gchar *mimetype);
G_END_DECLS
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]