Skip to content

Instantly share code, notes, and snippets.

@ssokolow
Last active October 4, 2022 00:48
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ssokolow/26a2cc98cded622ecae43035ba0a6cfa to your computer and use it in GitHub Desktop.
Save ssokolow/26a2cc98cded622ecae43035ba0a6cfa to your computer and use it in GitHub Desktop.
Files for making Flatpak builds of lgogdownloader

A Flatpak release of LGOGDownloader to provide easy access to up-to-date builds with the optional QtWebEngine dependency enabled.

Note that the included patch for the htmlcxx dependency was submitted to upstream, but the project appears to be unmaintained.

<?xml version="1.0" encoding="UTF-8"?>
<!-- Copyright 2022 Stephan Sokolow -->
<component type="console-application">
<id>com.github.Sude.lgogdownloader</id>
<metadata_license>CC0-1.0</metadata_license>
<project_license>WTFPL</project_license>
<name>LGOGDownloader</name>
<summary>Download GOG.com Games</summary>
<description>
<p>
LGOGDownloader is an unofficial GOG.com game downloader for Linux users.
It uses the same API as the official GOG Galaxy client and is not limited
to downloading only Linux builds.
</p>
<p>
This release is built with the optional dependency on QtWebEngine to
provide support for displaying reCAPTCHA challenges which GOG.com
may present when you use the --login option. However, it
otherwise has no graphical interface and will not install a desktop
launcher entry.
</p>
<p>Consult the output of the --help option for usage.</p>
<p>
As Flatpak currently limits packages to exporting reverse-DNS command
names, you are advised to place a line such as 'alias
lgogdownloader="flatpak run com.github.Sude.lgogdownloader' into
your shell profile (eg. .bashrc) for ease of use. You may
omit the "flatpak run" portion if you have added Flatpak's
exports directory to your PATH.
</p>
</description>
<categories>
<category>Network</category>
<category>FileTransfer</category>
<category>Qt</category>
<category>ConsoleOnly</category>
</categories>
<screenshots>
<screenshot type="default">
<image>https://raw.githubusercontent.com/Sude-/lgogdownloader/master/screenshot.png</image>
</screenshot>
</screenshots>
<content_rating type="oars-1.0"/>
<url type="homepage">https://sites.google.com/site/gogdownloader/</url>
<url type="bugtracker">https://github.com/Sude-/lgogdownloader/issues</url>
<url type="donation">https://ko-fi.com/lgogdownloader</url>
<url type="donation">https://www.paypal.com/donate/?cmd=_s-xclick&amp;hosted_button_id=PT95NXVLQU6WG</url>
<provides>
<binary>lgogdownloader</binary>
</provides>
<suggests>
<id>org.phoenicis.playonlinux</id>
</suggests>
</component>
{
"app-id": "com.github.Sude.lgogdownloader",
"default-branch": "stable",
"runtime": "org.kde.Platform",
"runtime-version": "5.15-21.08",
"base": "io.qt.qtwebengine.BaseApp",
"base-version": "5.15-21.08",
"sdk": "org.kde.Sdk",
"command": "lgogdownloader",
"cleanup": [
"/include",
"*.a",
"*.la"
],
"cleanup-commands": [ "/app/cleanup-BaseApp.sh" ],
"finish-args": [
"--share=network",
"--filesystem=host",
"--no-talk-name=com.canonical.AppMenu.Registrar",
"--no-talk-name=org.kde.kconfig.notify"
],
"modules": [
{
"name": "boost",
"buildsystem": "simple",
"build-commands": [
"./bootstrap.sh --prefix=/app --with-libraries=regex,date_time,system,filesystem,program_options,iostreams",
"./b2 -j `nproc` install"
],
"sources": [
{
"type": "archive",
"url": "https://boostorg.jfrog.io/artifactory/main/release/1.76.0/source/boost_1_76_0.tar.bz2",
"sha256": "f0397ba6e982c4450f27bf32a2a83292aba035b827a5623a14636ea583318c41"
}
]
},
{
"name": "jsoncpp",
"buildsystem": "meson",
"config-opts": [ "--buildtype=release", "--default-library=shared" ],
"sources": [
{
"type": "git",
"url": "https://github.com/open-source-parsers/jsoncpp.git",
"tag": "1.9.5",
"commit": "5defb4ed1a4293b8e2bf641e16b156fb9de498cc"
}
]
},
{
"name": "htmlcxx",
"buildsystem": "autotools",
"build-options" : { "ldflags": "-Wl,--no-as-needed" },
"cleanup": [ "/bin" ],
"sources": [
{
"type": "archive",
"url": "https://sourceforge.net/projects/htmlcxx/files/v0.87/htmlcxx-0.87.tar.gz",
"sha256": "5d38f938cf4df9a298a5346af27195fffabfef9f460fc2a02233cbcfa8fc75c8"
},
{
"type": "patch",
"path": "htmlcxx-0.87-c++17.patch"
}
]
},
{
"name": "tinyxml2",
"buildsystem": "cmake",
"sources": [
{
"type": "git",
"url": "https://github.com/leethomason/tinyxml2.git",
"tag": "9.0.0",
"commit": "1dee28e51f9175a31955b9791c74c430fe13dc82"
}
]
},
{
"name": "librhash",
"buildsystem": "autotools",
"build-options": { "config-opts": [ "--enable-openssl-runtime" ] },
"cleanup": [ "/bin/*", "/share/man/*" ],
"post-install": ["make install-lib-so-link install-lib-headers"],
"sources": [
{
"type": "git",
"url": "https://github.com/rhash/RHash.git",
"tag": "v1.4.2",
"commit": "02c8b1dbae01c8d56613b6a3034c3698f94a52be"
}
]
},
{
"name": "lgogdownloader",
"buildsystem": "cmake-ninja",
"builddir": true,
"config-opts": [ "-DCMAKE_BUILD_TYPE=Release", "-DUSE_QT_GUI=ON" ],
"sources": [
{
"type": "git",
"url": "https://github.com/Sude-/lgogdownloader.git",
"tag": "v3.8",
"commit": "9d24bd1990985017e8b9c122791dfc7c5f7c7e40"
}
]
}
]
}
diff --color -Naur a/html/CharsetConverter.cc b/html/CharsetConverter.cc
--- a/html/CharsetConverter.cc 2018-12-29 03:13:56.000000000 +0000
+++ b/html/CharsetConverter.cc 2021-05-31 23:03:10.705334580 +0100
@@ -7,7 +7,7 @@
using namespace std;
using namespace htmlcxx;
-CharsetConverter::CharsetConverter(const string &from, const string &to) throw (Exception)
+CharsetConverter::CharsetConverter(const string &from, const string &to)
{
mIconvDescriptor = iconv_open(to.c_str(), from.c_str());
if (mIconvDescriptor == (iconv_t)(-1))
diff --color -Naur a/html/CharsetConverter.h b/html/CharsetConverter.h
--- a/html/CharsetConverter.h 2018-12-29 03:13:56.000000000 +0000
+++ b/html/CharsetConverter.h 2021-05-31 23:03:19.042574598 +0100
@@ -17,7 +17,7 @@
: std::runtime_error(arg) {}
};
- CharsetConverter(const std::string &from, const std::string &to) throw (Exception);
+ CharsetConverter(const std::string &from, const std::string &to);
~CharsetConverter();
std::string convert(const std::string &input);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment