[tracker/libtracker-common-cleanup: 14/16] libtracker-data: Moved internal API tracker_crc32() here from libtracker-common



commit 705436694cd7154ea898238d31356dcd92427ee1
Author: Martyn Russell <martyn lanedo com>
Date:   Sun Sep 28 19:22:48 2014 +0100

    libtracker-data: Moved internal API tracker_crc32() here from libtracker-common
    
    It's only used in libtracker-data and libtracker-common isn't a public library

 src/libtracker-common/Makefile.am                  |    2 --
 src/libtracker-data/Makefile.am                    |    2 ++
 .../tracker-crc32.c                                |    2 +-
 .../tracker-crc32.h                                |    0
 src/libtracker-data/tracker-db-journal.c           |    3 +--
 tests/libtracker-common/.gitignore                 |    3 +--
 tests/libtracker-common/Makefile.am                |    3 ---
 tests/libtracker-data/.gitignore                   |    3 ++-
 tests/libtracker-data/Makefile.am                  |    2 ++
 .../tracker-crc32-test.c                           |    6 ++++--
 tests/libtracker-data/tracker-db-journal.c         |    4 +---
 11 files changed, 14 insertions(+), 16 deletions(-)
---
diff --git a/src/libtracker-common/Makefile.am b/src/libtracker-common/Makefile.am
index d2660a0..a3223f2 100644
--- a/src/libtracker-common/Makefile.am
+++ b/src/libtracker-common/Makefile.am
@@ -29,7 +29,6 @@ libtracker_common_la_SOURCES = \
        tracker-storage.c \
        tracker-type-utils.c \
        tracker-utils.c \
-       tracker-crc32.c \
        tracker-locale.c \
        tracker-miner-locale.c
 
@@ -49,7 +48,6 @@ noinst_HEADERS = \
        tracker-storage.h \
        tracker-type-utils.h \
        tracker-utils.h \
-       tracker-crc32.h \
        tracker-locale.h \
        tracker-miner-locale.h
 
diff --git a/src/libtracker-data/Makefile.am b/src/libtracker-data/Makefile.am
index e25b766..bf26e65 100644
--- a/src/libtracker-data/Makefile.am
+++ b/src/libtracker-data/Makefile.am
@@ -27,6 +27,7 @@ libtracker_data_la_SOURCES =                           \
        tracker-turtle-reader.vala                     \
        tracker-class.c                                \
        tracker-collation.c                            \
+       tracker-crc32.c \
        tracker-data-backup.c                          \
        tracker-data-manager.c                         \
        tracker-data-query.c                           \
@@ -56,6 +57,7 @@ endif
 
 noinst_HEADERS =                                       \
        tracker-class.h                                \
+       tracker-crc32.h \
        tracker-data.h                                 \
        tracker-collation.h                            \
        tracker-data-backup.h                          \
diff --git a/src/libtracker-common/tracker-crc32.c b/src/libtracker-data/tracker-crc32.c
similarity index 99%
rename from src/libtracker-common/tracker-crc32.c
rename to src/libtracker-data/tracker-crc32.c
index 82bd3d8..152044f 100644
--- a/src/libtracker-common/tracker-crc32.c
+++ b/src/libtracker-data/tracker-crc32.c
@@ -44,7 +44,7 @@
  *
  */
 
-#include <libtracker-common/tracker-crc32.h>
+#include "tracker-crc32.h"
 
 static const guint32 crcTable[256] = {
   0x00000000UL, 0x77073096UL, 0xEE0E612CUL, 0x990951BAUL, 0x076DC419UL, 0x706AF48FUL, 0xE963A535UL, 
0x9E6495A3UL,
diff --git a/src/libtracker-common/tracker-crc32.h b/src/libtracker-data/tracker-crc32.h
similarity index 100%
rename from src/libtracker-common/tracker-crc32.h
rename to src/libtracker-data/tracker-crc32.h
diff --git a/src/libtracker-data/tracker-db-journal.c b/src/libtracker-data/tracker-db-journal.c
index b997daf..1f26ae0 100644
--- a/src/libtracker-data/tracker-db-journal.c
+++ b/src/libtracker-data/tracker-db-journal.c
@@ -37,8 +37,7 @@
 # define O_LARGEFILE 0
 #endif
 
-#include <libtracker-common/tracker-crc32.h>
-
+#include "tracker-crc32.h"
 #include "tracker-db-journal.h"
 
 #ifndef DISABLE_JOURNAL
diff --git a/tests/libtracker-common/.gitignore b/tests/libtracker-common/.gitignore
index f6a4ae9..0014f9c 100644
--- a/tests/libtracker-common/.gitignore
+++ b/tests/libtracker-common/.gitignore
@@ -8,6 +8,5 @@ tracker-ontology
 tracker-thumbnailer
 tracker-type-utils
 tracker-utils
-tracker-crc32-test
 tracker-date-time-test
-tracker-media-art-test
\ No newline at end of file
+tracker-media-art-test
diff --git a/tests/libtracker-common/Makefile.am b/tests/libtracker-common/Makefile.am
index 2907d84..68d6cbe 100644
--- a/tests/libtracker-common/Makefile.am
+++ b/tests/libtracker-common/Makefile.am
@@ -8,7 +8,6 @@ test_programs = \
        tracker-file-utils                             \
        tracker-utils                                  \
        tracker-sched-test                             \
-       tracker-crc32-test                             \
        tracker-date-time-test
 
 AM_CPPFLAGS =                                      \
@@ -36,8 +35,6 @@ tracker_utils_SOURCES = tracker-utils-test.c
 
 tracker_sched_test_SOURCES = tracker-sched-test.c
 
-tracker_crc32_test_SOURCES = tracker-crc32-test.c
-
 tracker_date_time_test_SOURCES = tracker-date-time-test.c
 
 EXTRA_DIST += non-utf8.txt
diff --git a/tests/libtracker-data/.gitignore b/tests/libtracker-data/.gitignore
index 5be8339..47f150f 100644
--- a/tests/libtracker-data/.gitignore
+++ b/tests/libtracker-data/.gitignore
@@ -1,5 +1,6 @@
 tracker
 tracker-backup
+tracker-crc32-test
 tracker-ontology
 tracker-ontology-change
 tracker-sparql
@@ -7,4 +8,4 @@ tracker-sparql-blank
 tracker-db-dbus
 tracker-db-journal
 tracker-index-writer
-tracker-store.journal
\ No newline at end of file
+tracker-store.journal
diff --git a/tests/libtracker-data/Makefile.am b/tests/libtracker-data/Makefile.am
index beaef61..db90a2a 100644
--- a/tests/libtracker-data/Makefile.am
+++ b/tests/libtracker-data/Makefile.am
@@ -29,6 +29,7 @@ test_programs = \
        tracker-sparql-blank                           \
        tracker-ontology                               \
        tracker-backup                                 \
+       tracker-crc32-test                             \
        tracker-ontology-change                        \
        tracker-db-journal
 
@@ -54,6 +55,7 @@ tracker_sparql_blank_SOURCES = tracker-sparql-blank-test.c
 tracker_ontology_SOURCES = tracker-ontology-test.c
 tracker_ontology_change_SOURCES = tracker-ontology-change-test.c
 tracker_backup_SOURCES = tracker-backup-test.c
+tracker_crc32_test_SOURCES = tracker-crc32-test.c
 tracker_db_journal_SOURCES = tracker-db-journal.c
 
 EXTRA_DIST += \
diff --git a/tests/libtracker-common/tracker-crc32-test.c b/tests/libtracker-data/tracker-crc32-test.c
similarity index 95%
rename from tests/libtracker-common/tracker-crc32-test.c
rename to tests/libtracker-data/tracker-crc32-test.c
index 43d94f5..6a26480 100644
--- a/tests/libtracker-common/tracker-crc32-test.c
+++ b/tests/libtracker-data/tracker-crc32-test.c
@@ -16,10 +16,12 @@
  * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
  * Boston, MA  02110-1301, USA.
  */
-#include <glib.h>
+
+#include "config.h"
+
 #include <glib-object.h>
 
-#include <libtracker-common/tracker-crc32.h>
+#include <libtracker-data/tracker-crc32.h>
 
 // Using http://crc32-checksum.waraxe.us/ to check the result
 static void
diff --git a/tests/libtracker-data/tracker-db-journal.c b/tests/libtracker-data/tracker-db-journal.c
index febee15..bea1813 100644
--- a/tests/libtracker-data/tracker-db-journal.c
+++ b/tests/libtracker-data/tracker-db-journal.c
@@ -17,12 +17,10 @@
  * Boston, MA  02110-1301, USA.
  */
 
-#include <config.h>
+#include "config.h"
 
 #include <glib/gstdio.h>
 
-#include <libtracker-common/tracker-crc32.h>
-
 #include <libtracker-data/tracker-db-journal.h>
 
 #ifndef DISABLE_JOURNAL


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]