Commit f827695a authored by Olly Betts's avatar Olly Betts
Browse files

Automatically find packaged LO on 64bit Fedora

parent d0acbe0e
......@@ -23,7 +23,8 @@ the content of, but fetching arbitrary documents is equivalent to automatically
opening email attachments.
The code checks for LibreOffice installed in /usr/lib/libreoffice/program
(which is where the Debian packages install to) and if it's not there, tries
or /usr/lib64/libreoffice/program (which is where the Debian and Fedora
packages install to) and if it's not there, tries
/opt/libreoffice<major>.<minor>/program for known <major>.<minor> versions
(which is where the .debs from install to). You can override
this by setting environmental variable LO_PATH, either to handle an install in
/* - Convert documents using LibreOfficeKit
* Copyright (C) 2014,2015,2016,2018 Olly Betts
* Copyright (C) 2014,2015,2016,2018,2019 Olly Betts
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
......@@ -27,9 +27,12 @@
using namespace std;
using namespace lok;
// Install location for Debian packages:
// Install location for Debian packages (also Fedora on 32-bit architectures):
#define LO_PATH_DEBIAN "/usr/lib/libreoffice/program"
// Install location for Fedora packages on 64-bit architectures:
#define LO_PATH_FEDORA64 "/usr/lib64/libreoffice/program"
// Install location for .deb files from
#define LO_PATH_LIBREOFFICEORG(V) "/opt/libreoffice"#V"/program"
......@@ -44,6 +47,7 @@ get_lo_path()
struct stat sb;
#define CHECK_DIR(P) if (!lo_path && stat(P"/versionrc", &sb) == 0 && S_ISREG(sb.st_mode)) lo_path = P
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment