summaryrefslogtreecommitdiff
path: root/src/libtracker-common
Commit message (Collapse)AuthorAgeFilesLines
* libtracker-common: Flip ellipsizingwip/carlosg/term-ellipsizingCarlos Garnacho2021-02-041-3/+3
| | | | | | Due to some brain fart, ellipsizing was made to cut the string the opposite way around to the given TRACKER_ELLIPSIZING_* value. Go for the minimal fix and fully flip the condition/strings.
* libtracker-common: Improve terminal ellipsizing helperCarlos Garnacho2021-02-041-3/+22
| | | | | | | | | | | | | This was in a sorry state for some reasons: - It was pretty oblivious to UTF-8, so it might cut the string mid-character. - It uses g_memdup(), which should be best avoided. See https://gitlab.gnome.org/GNOME/glib/-/merge_requests/1928 For the former, use g_utf8_* API to count characters (which is what we want for terminal formatting purposes). For the latter, use g_strndup(), which is gchar* oriented and takes gsize, to avoid vulnerabilities and incompatibilities.
* libtracker-sparql: Call tracker_get_debug_flags() on connection constructsam/debug-helpSam Thursfield2020-12-011-0/+3
| | | | This ensures our TRACKER_DEBUG=help functionality always works.
* libtracker-common: Ensure to print at least 4 year digitsCarlos Garnacho2020-10-101-1/+1
| | | | | | | Expand the %F in strftime() to %4Y-%M-%D, otherwise for years < 1000 we end up eating digits, and producing a not quite ISO8601 string. Fixes: https://gitlab.gnome.org/GNOME/tracker-miners/-/issues/146
* libtracker-common: Drop unused date/time util functionswip/carlosg/libtracker-common-cleanupCarlos Garnacho2020-09-162-26/+0
| | | | These are unused in the Tracker codebase.
* libtracker-common: Drop type util function helpersCarlos Garnacho2020-09-166-269/+0
| | | | We (now) use none of this, the code can be removed.
* libtracker-common: Drop unused file util functionsCarlos Garnacho2020-09-162-598/+1
| | | | | We use a very limited portion of this API in the Tracker repo, throw away the remainders.
* libtracker-common: Remove unused tracker util functionsCarlos Garnacho2020-09-162-144/+0
| | | | These are only exercised in tests, we can do without them.
* Added Czech stop-wordsMarek Černocký2020-09-012-0/+243
|
* Remove programming terms from stop-words.Sam Thursfield2020-08-241-147/+0
| | | | Tracker is not a source code indexer, so we have no use for these.
* libtracker-common: Add tracker-term-utilsCarlos Garnacho2020-08-194-0/+234
| | | | Copied straight from tracker-miners repo.
* libtracker-common: Add method to build dbus URICarlos Garnacho2020-07-173-0/+35
| | | | | This is the inverse of tracker_util_parse_dbus_uri(), that we can build a DBus URI with.
* build: Use `tracker3` as versioned name, not `tracker-3`Sam Thursfield2020-06-171-1/+1
| | | | | | This corresponds with the package name we expect distros to use. Fixes https://gitlab.gnome.org/GNOME/tracker/-/issues/228
* Add TRACKER_DEBUG=sparqlSam Thursfield2020-04-282-2/+4
| | | | This outputs all queries to the console.
* Add TRACKER_DEBUG=collation,sqlite flagsSam Thursfield2020-04-282-2/+6
|
* libtracker-common: Fix lookup directory for stop wordsCarlos Garnacho2020-04-271-1/+1
| | | | This was missed in the parallel-installable branch.
* Remove TRACKER_VERBOSITY and tracker-log moduleSam Thursfield2020-04-209-376/+0
| | | | | | | | | Users should now use G_MESSAGES_DEBUG=Tracker to see debug messages on the console. The TRACKER_VERBOSITY only worked if tracker_log_init() had been called, which can't be done when libtracker-sparql is being used from an application outside of Tracker.
* Add ONTOLOGY_CHANGES debug flag and hide index creation logs by defualtSam Thursfield2020-04-202-1/+3
|
* libtracker-common: Remove obsolete SCHED_IDLE enumSam Thursfield2020-04-201-6/+0
|
* Add TRACKER_DEBUG environment variable, use for SQL debugSam Thursfield2020-04-204-0/+113
| | | | | | | | This works the same as GTK's GTK_DEBUG variable. It will allow us to include more types of optional debugging info, and will make the default debug output more readlable. See https://gitlab.gnome.org/GNOME/tracker/issues/178
* build: Install ontologies/stop-words in $datadir/tracker-3Carlos Garnacho2020-04-051-1/+1
| | | | So they can be installed in parallel with other major versions
* Update TRACKER_PARSER_VERSIONSam Thursfield2020-02-181-1/+1
|
* libtracker-common: Extend list of reserved wordsCarlos Garnacho2020-02-171-0/+3
| | | | | FTS4 and FTS5 introduced additional syntax. These are most likely stop words too, but we should ignore them right away.
* libtracker-sparql: Add define to export library functionsCarlos Garnacho2020-02-171-0/+1
| | | | | | | | | | And get rid of the map file. This allows us to selectively make API public, so we no longer need it, nor regexps. Also, add the beginning of TRACKER_AVAILABLE_IN_* defines, so we can help with testing minor version changes, add deprecation warnings, etc. So far we're heading towards 3.0, all public API started using this with TRACKER_AVAILABLE_IN_ALL, since we're bumping major version.
* libtracker-data: Expand dbus uris to observe bus and object pathCarlos Garnacho2020-02-172-0/+43
| | | | | The URI scheme is dbus:[system|session]?:<interface>:<path>, and allows us to connect with endpoints in either bus, with arbitrary object paths.
* libtracker-common: Clean up no longer used modulesCarlos Garnacho2020-02-178-1285/+0
| | | | | | With the massive shuffling happening in the tracker repo, some of these utility functions are no longer used, and even meaningless in this source tree. Clean all this up.
* libtracker-common: Remove tracker_sched_idle() codeSam Thursfield2020-01-094-114/+0
| | | | | | | This is still used in tracker-miners.git, but it's no longer used in tracker.git. See: https://gitlab.gnome.org/GNOME/tracker/issues/170
* Use #ifdef with config.h define variable HAVE_STATVFS64Sam Thursfield2019-12-201-1/+1
| | | | | | | This was causing build failures on non-Linux architectures such as Debian/Hurd. Fixes https://gitlab.gnome.org/GNOME/tracker/issues/169
* tests: Enable logging in test data-sparqlSam Thursfield2019-09-221-1/+3
| | | | | This may help with debugging https://gitlab.gnome.org/GNOME/tracker/issues/145.
* Enable G_MESSAGES_DEBUG=Tracker rather than G_MESSAGES_DEBUG=allSam Thursfield2019-09-141-2/+14
| | | | | | | | | | | In order for our g_info()/g_message()/g_debug() log messages to be handled, we need to have G_MESSAGES_DEBUG=Tracker enabled in the environment. Previously we would enable G_MESSAGES_DEBUG=all, which has the effect of also enabling log output from GLib/GIO and other dependencies. In the interests of keeping logs clean, we now require the user to explicitly set G_MESSAGES_DEBUG=all if they want maximum debug output.
* libtracker-data: Implement BASECarlos Garnacho2019-09-102-0/+118
| | | | It is meant to affect all relative IRIs being parsed.
* libtracker-common: Add offset argument to tracker_date_to_string()Carlos Garnacho2019-09-102-7/+23
| | | | So that we can convert losslessly between time+offset and strings.
* meson: Don't install libtracker-common static libraryMarco Trevisan (Treviño)2019-08-221-2/+0
| | | | | As per GNOME/tracker!106 libtracker-common is now a static library, as per this there's not point of installing it.
* libtracker-common: Make TrackerDomainOntology totally not an objectCarlos Garnacho2019-07-313-189/+67
| | | | | | | | | Hopefully the last chapter in the "make libtracker-common static" saga... Turn this object into a refcounted struct, as we still may end up with multiple copies of libtracker-common in libtracker-miner, through libtracker-sparql.so and directly as it also uses libtracker-common. This resulted in assertions when trying to register the same type name twice.
* build: Make libtracker-common a static library, for real this timeSam Thursfield2019-07-151-7/+1
| | | | | | | | | | | I attempted this before in https://gitlab.gnome.org/GNOME/tracker/102 (commit ac856befe3), but reverted it again because it caused errors in tracker-miners about the type TrackerDomainOntology being registered twice. MR https://gitlab.gnome.org/GNOME/tracker-miners/merge_requests/89 removes the TrackerDomainOntology GType from libtracker-miners-common, then we can make this library static for real.
* build: Use tracker_common_dep as a normal dependencySam Thursfield2019-07-101-9/+0
| | | | | | | | | | | | | | We were using 'link_with: libtracker-common' to link to libtracker-common in some places, which worked around an old Meson bug. The bug (https://github.com/mesonbuild/meson/issues/671) was fixed in Meson 0.42 so we can now remove the workaround. The advantage of using 'dependency: tracker_common_dep' is that transitive dependencies are now automatically propagated. We now probably have some redundant dependency information on some of the libraries, but that isn't a problem. Fixes https://gitlab.gnome.org/GNOME/tracker/issues/112
* Add comment to say why libtracker-common is a shared library.Sam Thursfield2019-07-101-0/+6
|
* Revert "build: libtracker-common should be a static library"Sam Thursfield2019-07-101-1/+3
| | | | | | | | | | | | | | | | | | | This reverts commit ac856befe3bc237b4817da0c63285d5098be4f3f. This commit broke tracker-miners, because if we statically link against libtracker-common then it conflicts with libtracker-miners-common and we end up with conflicts within GType like this: (tracker-extract:30499): GLib-GObject-WARNING **: 17:02:03.353: cannot register existing type 'TrackerDomainOntology' (tracker-extract:30499): GLib-GObject-WARNING **: 17:02:03.353: cannot add private field to invalid (non-instantiatable) type '<invalid>' (tracker-extract:30499): GLib-GObject-CRITICAL **: 17:02:03.353: g_type_add_interface_static: assertion 'G_TYPE_IS_INSTANTIATABLE (instance_type)' failed (tracker-extract:30499): GLib-CRITICAL **: 17:02:03.353: g_once_init_leave: assertion 'result != 0' failed (tracker-extract:30499): GLib-GIO-CRITICAL **: 17:02:03.353: g_initable_new_valist: assertion 'G_TYPE_IS_INITABLE (object_type)' faile
* build: libtracker-common should be a static librarySam Thursfield2019-07-101-3/+1
| | | | | This library is API-unstable helper code. In the Autotools build system we only linked to it statically and didn't install it.
* build: Modify how we define the enum headerSam Thursfield2019-05-011-1/+3
| | | | | | | This is another change needed for tracker-miners to use the GSettings schemas from this project when its build as a subproject. See: https://gitlab.gnome.org/GNOME/tracker-miners/merge_requests/61
* libtracker-common: Fix code flow in tracker_unescape_unichars()Carlos Garnacho2019-02-221-3/+1
| | | | | | There was a second if() hidden in the block, meant to be a "else if". Also drop the continues, since there's not much code afterwards in the loop.
* libtracker-common: fix build on OpenBSDAntoine Jacoutot2019-02-211-1/+5
| | | | We need to link with libkvm on OpenBSD (kvm_open, kvm_openfiles, etc.)
* build: Use meson feature option type where appropriateMart Raudsepp2019-02-141-5/+1
|
* Use basename instead of filename for reproducibilityChris Lamb2018-12-052-2/+2
| | | | | | | | | | | | We don't need to store the full path build filename in comments in the header files. This change was recommended by the Reproducible Builds project. https://reproducible-builds.org/ https://bugs.debian.org/915503
* libtracker-common: Add helper function to escape \u and \U sequencesCarlos Garnacho2018-11-132-0/+91
|
* libtracker-common: Drop unused function and its testCarlos Garnacho2018-11-082-82/+0
| | | | | | This function is no longer used, so makes no sense to test for it. This test used to break on CI with the default docker images because of user permissions, so this obstacle is removed.
* libtracker-common,data: Port libicu paths to unorm2_normalizewip/carlosg/compiler-warningsCarlos Garnacho2018-10-122-8/+13
| | | | | The old unorm_normalize() function has been deprecated. This replacement function is available on ICU >= 4.4, so we should be fine dependency-wise.
* libtracker-common: Port TrackerLanguage to G_ADD_PRIVATECarlos Garnacho2018-10-121-32/+27
|
* build: Drop autotoolswip/carlosg/drop-autotoolsCarlos Garnacho2018-09-092-101/+0
|
* libtracker-common: Plug leakCarlos Garnacho2018-09-091-0/+1
|