GNOME Bugzilla – Bug 708453
stop using libgsystem for 3.11
Last modified: 2015-02-12 23:36:29 UTC
libgsystem grew beyond simple file stuff, and gnome-desktop is only using 2% of it; we could just copy the trivial bits now.
As per Bug 735974, gnome-desktop is using only one function, gs_file_read_noatime(), from libgsystem. Is it even worth copying it (it is quite a large function once you unroll it) just to avoid updating access times? (or is there another advantage to using that function?)
I'd just copy the one file that we use from libgsystem, and add an "update-from-libgsystem.sh" helper, as we do in other cut'n'paste situations: https://git.gnome.org/browse/gnome-control-center/tree/panels/wacom/Makefile.am#n81
Created attachment 296234 [details] [review] Drop libgsystem submodule, stop using O_NOATIME The entire rationale for adding this _noatime function was fairly bogus. See https://bugzilla.gnome.org/show_bug.cgi?id=680326 But the Linux kernel doesn't permit non-root users to use it for root-owned files - which is the default for real world GNOME installations. We end up doing twice the syscall traffic with no benefit at all. The patch does work in jhbuild, but honestly the relatime handling is generally OK for this, and where it's not, change your system to mount O_NOATIME.
I want to have libgsystem potentially become more Linux specific, and having gnome-desktop depend on it is problematic from that perspective.
Review of attachment 296234 [details] [review]: Rest looks fine. ::: libgnome-desktop/gnome-desktop-thumbnail.c @@ -495,1 @@ input_stream = G_INPUT_STREAM (g_file_read (file, NULL, &error)); You'll need to unmangle the indentation of that line.
Attachment 296234 [details] pushed as c394ae4 - Drop libgsystem submodule, stop using O_NOATIME