[tracker/wip/carlosg/meson-fixes: 1/10] tests: Link to internal library in libtracker-miner tests



commit 23272929766ac26afb303b0fa549c6ada170d2ce
Author: Carlos Garnacho <carlosg gnome org>
Date:   Mon Sep 3 14:57:25 2018 +0200

    tests: Link to internal library in libtracker-miner tests
    
    It does test internal API, so explicitly link to it.

 src/libtracker-miner/meson.build   | 8 +-------
 tests/libtracker-miner/meson.build | 6 ++++--
 2 files changed, 5 insertions(+), 9 deletions(-)
---
diff --git a/src/libtracker-miner/meson.build b/src/libtracker-miner/meson.build
index 5fd0a6c0a..ce6b5b501 100644
--- a/src/libtracker-miner/meson.build
+++ b/src/libtracker-miner/meson.build
@@ -1,7 +1,3 @@
-shared_libtracker_miner_monitor_sources = files('tracker-monitor.c')
-shared_libtracker_miner_file_system_sources = files('tracker-file-system.c')
-shared_libtracker_miner_crawler_sources = files('tracker-crawler.c')
-
 miner_enums = gnome.mkenums('tracker-miner-enum-types',
     sources: 'tracker-miner-enums.h',
     c_template: 'tracker-miner-enum-types.c.template',
@@ -15,6 +11,7 @@ private_sources = [
     'tracker-file-data-provider.c',
     'tracker-file-notifier.c',
     'tracker-file-system.c',
+    'tracker-monitor.c',
     'tracker-priority-queue.c',
     'tracker-task-pool.c',
     'tracker-sparql-buffer.c',
@@ -34,9 +31,6 @@ miner_headers = [
 ]
 
 miner_sources = (
-    shared_libtracker_miner_monitor_sources +
-    shared_libtracker_miner_file_system_sources +
-    shared_libtracker_miner_crawler_sources +
     ['tracker-data-provider.c',
     'tracker-decorator.c',
     'tracker-decorator-fs.c',
diff --git a/tests/libtracker-miner/meson.build b/tests/libtracker-miner/meson.build
index c125f08ca..f4cb1bdad 100644
--- a/tests/libtracker-miner/meson.build
+++ b/tests/libtracker-miner/meson.build
@@ -34,7 +34,8 @@ foreach base_name: libtracker_miner_tests
 
     binary = executable(binary_name, source,
       dependencies: libtracker_miner_test_deps,
-      c_args: libtracker_miner_test_c_args)
+      c_args: libtracker_miner_test_c_args,
+      link_with: [libtracker_miner_private])
 
     test(test_name, binary,
       env: libtracker_miner_test_environment)
@@ -47,7 +48,8 @@ foreach base_name: libtracker_miner_slow_tests
 
     binary = executable(binary_name, source,
       dependencies: libtracker_miner_test_deps,
-      c_args: libtracker_miner_test_c_args)
+      c_args: libtracker_miner_test_c_args,
+      link_with: [libtracker_miner_private])
 
     test(test_name, binary,
       env: libtracker_miner_test_environment,


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