Bug 47470 - sofficerc should be installed in /etc/
Summary: sofficerc should be installed in /etc/
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: Other Linux (All)
: medium enhancement
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Installer-Linux
  Show dependency treegraph
 
Reported: 2012-03-18 01:32 UTC by Tomáš Chvátal
Modified: 2023-12-10 17:43 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tomáš Chvátal 2012-03-18 01:32:28 UTC
sofficerc and the other theme files should be put into etc for user to mess with.

Same is that configuration should be overridable in ~/.config/libreoffice/ per user basis.

This bug is somehow hacked in debian so they can put sofficerc into /etc/libreoffice/sofficerc and then the /usr/libdir/libreoffice/program/sofficerc contain some hack that loads the etc one.

I would say that this would be highly desirable by most packagers. Also see downstream bug [1].


[1] https://bugs.gentoo.org/show_bug.cgi?id=406295

@petr: I don't know the complexity but could this be turned to some easy hack? If so would you mind helping me adding all the relevant info?
Comment 1 Petr Mladek 2012-04-11 03:01:54 UTC
A generic pointer is to search for "sofficerc" at http://opengrok.libreoffice.org/

The following found locations look interesting:

   + "/* costruct the sofficerc file location */" comment in  
     desktop/unx/source/splashx.c

   + "#define SVERSION_PROFILE" and "osl_openProfile" function definition in
     sal/osl/unx/profile.c

   + "// read keys from soffice.ini (sofficerc)" comment
     in uui/source/newerverwarn.cxx


In each case, we could take inspiration in the hack that is used in Debian. I wonder if Rene could point us to the patch.
Comment 3 Rene Engelhard 2012-04-11 03:47:51 UTC
which then results in

$ cat /usr/lib/libreoffice/program/sofficerc 
# *DO NOT* CHANGE THIS FILE. IT ONLY TAKES THE SETTINGS FROM
# /etc/libreoffice/sofficerc. CHANGE THAT FILE IF YOU
# REALLY WANT TO CHANGE SOMETHING.
FHS_CONFIG_FILE=file:///etc/libreoffice/sofficerc

[Bootstrap]
HideEula=${$FHS_CONFIG_FILE:Bootstrap:HideEula}
Logo=${$FHS_CONFIG_FILE:Bootstrap:Logo}
NativeProgress=${$FHS_CONFIG_FILE:Bootstrap:NativeProgress}
ProgressBarColor=${$FHS_CONFIG_FILE:Bootstrap:ProgressBarColor}
ProgressFrameColor=${$FHS_CONFIG_FILE:Bootstrap:ProgressFrameColor}
ProgressPosition=${$FHS_CONFIG_FILE:Bootstrap:ProgressPosition}
ProgressSize=${$FHS_CONFIG_FILE:Bootstrap:ProgressSize}
URE_BOOTSTRAP=${ORIGIN}/fundamentalrc

(afaicr this was a hint from sberg in OOo times)
Comment 4 Julien Nabet 2015-08-22 18:14:43 UTC
On pc Debian testing x86-64 with LO Debian package 4.4.5.2, it's the case now.
root@julienPC:/# ls /etc/libreoffice/
psprint.conf  sofficerc  soffice.sh

Tomáš: don't hesitate to reopen this tracker if I'm wrong.

https://bugs.gentoo.org/show_bug.cgi?id=406295 is also indicated FIXED.
Comment 5 Tomáš Chvátal 2015-08-22 18:38:32 UTC
Debian does symlink. It is nothing comming from tdf package or buildsystem - > problem is still present.
Comment 6 Rene Engelhard 2015-08-23 20:35:04 UTC
strictly speaking, no, we don't symlink:

(sid)rene@frodo:~$ ls -l /etc/libreoffice/sofficerc 
-rw-r--r-- 1 root root 206 Jun  4 05:50 /etc/libreoffice/sofficerc
(sid)rene@frodo:~$ cat /usr/lib/libreoffice/program/sofficerc 
# *DO NOT* CHANGE THIS FILE. IT ONLY TAKES THE SETTINGS FROM
# /etc/libreoffice/sofficerc. CHANGE THAT FILE IF YOU
# REALLY WANT TO CHANGE SOMETHING.
FHS_CONFIG_FILE=file:///etc/libreoffice/sofficerc

[Bootstrap]
HideEula=${$FHS_CONFIG_FILE:Bootstrap:HideEula}
Logo=${$FHS_CONFIG_FILE:Bootstrap:Logo}
NativeProgress=${$FHS_CONFIG_FILE:Bootstrap:NativeProgress}
ProgressBarColor=${$FHS_CONFIG_FILE:Bootstrap:ProgressBarColor}
ProgressFrameColor=${$FHS_CONFIG_FILE:Bootstrap:ProgressFrameColor}
ProgressPosition=${$FHS_CONFIG_FILE:Bootstrap:ProgressPosition}
ProgressSize=${$FHS_CONFIG_FILE:Bootstrap:ProgressSize}
ProgressTextBaseline=${$FHS_CONFIG_FILE:Bootstrap:ProgressTextBaseline}
ProgressTextColor=${$FHS_CONFIG_FILE:Bootstrap:ProgressTextColor}
URE_BOOTSTRAP=${ORIGIN}/fundamentalrc
(sid)rene@frodo:~$ cat /etc/libreoffice/sofficerc 
[Bootstrap]
HideEula=1
Logo=1
NativeProgress=false
ProgressBarColor=215,7,81
ProgressFrameColor=245,245,245
ProgressPosition=72,189
ProgressSize=409,8
ProgressTextBaseline=170
ProgressTextColor=255,255,255

But yes, it's a Debianism.
Comment 7 Buovjaga 2015-10-09 18:37:44 UTC
Bug does not meet the criteria for Status 'REOPENED'
https://wiki.documentfoundation.org/QA/Bugzilla/Fields/Status/REOPENED#Criteria
Status -> NEW

Any update on this, folks?