Commit Graph

82 Commits

Author SHA1 Message Date
David Korth
3e853a59da [cmake] Don't enable -Werror or /WX by default; add a CMake option -DENABLE_WERROR.
Newer compilers usually add more warnings, so having -Werror by default
will most likely result in a compile error when new compiler versions
are released.

MSVC: Remove "-D_SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING". This is no
longer relevant, since we don't support anything older than MSVC 2015.
2025-04-28 18:19:53 -04:00
David Korth
5538794477 Missed a few TinyXML2 remnants. Updated for PugiXML. 2025-04-02 00:19:34 -04:00
David Korth
fa932de93f [libfmt] Add an internal copy of libfmt-11.1.2.
Currently used as a header-only build. Will eventually be changed to
build a DLL for Windows and Mac OS X.

Other changes needed to get the Windows version to build with libfmt:

Add #include <fmt/xchar.h> to some files for full wchar_t support
in libfmt. Otherwise, errors like this appear:

src\amiibo-data\amiiboc.cpp(175,8): error C2665: 'fmt::v11::print': no overloaded function could convert all the argument types
extlib\libfmt\include\fmt\base.h(2925,17): message : could be 'void fmt::v11::print<TCHAR*&>(FILE *,fmt::v11::fstring<TCHAR *&>,TCHAR *&)'
src\amiibo-data\amiiboc.cpp(175,8): message : 'void fmt::v11::print<TCHAR*&>(FILE *,fmt::v11::fstring<TCHAR *&>,TCHAR *&)': cannot convert argument 2 from 'wmain::<lambda_1>::()::FMT_COMPILE_STRING' to 'fmt::v11::fstring<TCHAR *&>'
src\amiibo-data\amiiboc.cpp(175,22): message : No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called
extlib\libfmt\include\fmt\base.h(2908,17): message : or       'void fmt::v11::print<wmain::<lambda_1>::()::FMT_COMPILE_STRING,TCHAR*&>(fmt::v11::fstring<wmain::<lambda_1>::()::FMT_COMPILE_STRING,TCHAR *&>,wmain::<lambda_1>::()::FMT_COMPILE_STRING &&,TCHAR *&)'
src\amiibo-data\amiiboc.cpp(175,8): message : 'void fmt::v11::print<wmain::<lambda_1>::()::FMT_COMPILE_STRING,TCHAR*&>(fmt::v11::fstring<wmain::<lambda_1>::()::FMT_COMPILE_STRING,TCHAR *&>,wmain::<lambda_1>::()::FMT_COMPILE_STRING &&,TCHAR *&)': cannot convert argument 1 from 'FILE *' to 'fmt::v11::fstring<wmain::<lambda_1>::()::FMT_COMPILE_STRING,TCHAR *&>'
src\amiibo-data\amiiboc.cpp(175,14): message : No constructor could take the source type, or constructor overload resolution was ambiguous
src\amiibo-data\amiiboc.cpp(175,8): message : while trying to match the argument list '(FILE *, wmain::<lambda_1>::()::FMT_COMPILE_STRING, TCHAR *)' [build.vc17_64\src\amiibo-data\amiiboc.vcxproj]

Files modified for xchar.h:
- amiibo-data/amiiboc.cpp
- libromdata/stdafx.h (needed by WiiUPackage)
- libromdata/tests/RomHeaderTest.cpp

NOTE: Only included on Windows. xchar.h was added in libfmt-8.0.0,
which was first added (in Ubuntu LTS releases) in Ubuntu 20.04.
It's not needed on Linux, anyway.

New option USE_INTERNAL_FMT to force the use of the internal copy of
libfmt on Linux, for testing purposes. (...and also for Ubuntu 16.04)
- TODO: Maybe use it on 18.04, etc. for improved performance?
2025-01-21 23:59:20 -05:00
David Korth
4a82bf28ab New option ENABLE_NETWORKING, which defaults to ON.
If OFF, this disables rp-download and all associated downloading code
in the GTK and KDE UI frontends (e.g. Update Checker and ProxyForUrl),
and disables ExecRpDownload in libcachemanager.

NOTE: The KF5 and KF6 ThumbnailCreator plugins definitely needed the
NetworkManaer D-Bus interface for isMetered(), but it wasn't linked
in before. This didn't seem to cause a problem, but with the adjustments
for ENABLE_NETWORKING, it's now causing a linker error. Add the
generated D-Bus interface source to the ThumbnailCreator plugins
to fix this.

TODO:
- Don't generate or use the NetworkManager D-Bus interface in
  no-network builds.
- Windows UI frontend changes.
- Disable the relevant configuration boxes in rp-config (but don't
  remove them entirely).
- Remove functions from the seccomp() whitelists that are no longer
  needed because we're not executing rp-download.
2025-01-20 18:45:52 -05:00
David Korth
c28063f80f The KDE 6.x and GTK 4.x UI frontends are no longer experimental.
They haven't been experimental for quite a while.

Note that the GTK 4.x property model has far less functionality than
the property page, but that's a Nautilus limitation, so there's not
much that I can do about it.
2024-10-25 01:20:33 -04:00
David Korth
adc780f113 Add some workarounds for issues encountered on NixOS.
Specify -DENABLE_NIXOS=ON to enable the workarounds.

- Using CMAKE_INSTALL_PREFIX in paths causes a double-path issue.
  This only seems to happen on NixOS.

- std::locale's constructor ends up calling getdents64(), so this
  syscall needs to be whitelisted. Only on NixOS though, since other
  Linux distros don't need it...

Fixes #406: Building on NixOS returns "invalid system call"
Reported by @Whovian9369.
2024-10-25 01:02:40 -04:00
David Korth
260a2dca0d More changes for Emscripten.
It doesn't link yet, but it compiles and it's almost there.

Changes:
- Use CPU architecture "wasm32".
- Disable split debug information.
- Disable libromdata.so.
- Don't build rp-download right now instead of failing with a fatal error.

FIXME: rpcli.js is failing to link:

[parse exception: attempted pop from empty stack / beyond block start boundary at 1177738 (at 0:1177738)]
Fatal: error in parsing input
2024-03-16 00:06:44 -04:00
David Korth
7dcfcba3e7 Remove BUILD_GTK2; use BUILD_XFCE everywhere instead.
This broke the GitHub CodeQL and CodeCov.io builds because we're not
installing GTK+ 2.x in those builds, and BUILD_GTK2 isn't a cached
variable; it's a "regular" variable.

The newly-added GTK tests expected BUILD_GTK2 to be unset if GTK2 wasn't
actually found, but this wasn't the case, so it failed to find the
GTK2::gtk target.

[res] Also check for BUILD_GTK4 in addition to BUILD_XFCE and BUILD_GTK3.
Not likely to have caused any problems yet, since no one has a "pure"
GTK4 system yet.
2024-01-25 22:44:44 -05:00
David Korth
e405aed196 [kde] Enable KF6 builds.
With the previous minor changes, the KF6 build seems to be working
exactly like the KF5 build in KDE Neon.
2023-08-04 22:41:57 -04:00
David Korth
16554a91aa Fix some issues causing XFCE to be incorrectly enabled if GTK2 is missing.
BUILD_XFCE is an option; BUILD_GTK2 is not.

We should probably get rid of BUILD_GTK2 entirely, since I'm not planning
on adding support for GNOME 2 Nautilus anytime soon.

Also, don't attempt to build rom-properties-glib if none of the GTK UI
frontends are being built.

Fixes CMake issues when building on KDE Neon. (KF6 testing)
2023-08-04 21:54:03 -04:00
David Korth
9c1db18574 Remove half-hearted support for Windows versions older than XP.
Windows 2000 support only partially worked in rp-config. The actual
shell extension component didn't work.

Support for ANSI Windows was mostly just compile-tested, and it was
becoming a burden to support something almost no one will use.

Removed most `#ifdef UNICODE` and `#ifdef _UNICODE` branches in
favor of using the Unicode path exclusively.

Removed oldwincompat, which was an attempt to get things working
properly on Windows 9x and 2000 with the MSVC 2010 runtime.
rom-properties doesn't compile with MSVC 2010 anymore, so this
probably wasn't very useful anyways.

Consolidated tstring macros in tcharx.h.

Removed GUID_fns.c since it was only useful in ANSI builds.
2023-07-31 21:32:47 -04:00
David Korth
8923ae45c3 [cmake] options.cmake: Disable ENABLE_NLS if compiling with MSVC for non-i386/amd64 CPUs.
Leaving it enabled for MinGW-w64 for now because an MSYS environment
might have gettext available for other architectures.
2023-07-28 19:11:17 -04:00
David Korth
fab48c546b Allow getpid() in coverage builds.
gcov uses getpid() in gcov_open() if GCOV_LOCKED is defined when
compiling gcc.

I'm not sure why this didn't cause any problems before...

[cmake] options.cmake: Define -DGCOV if building with coverage enabled.
This is used to determine if getpid() should be added to syscall
whitelists, assuming it hasn't been added already for other reasons.
2023-07-09 18:26:58 -04:00
David Korth
e7867b7d21 [cmake] options.cmake: Add an option to disable installation of documentation.
Some distributions install documentation using distro-specific build
scripts, so add an option to allow our documentation install to be
disabled.

Specify -DINSTALL_DOC=OFF on the CMake command line.
2023-02-10 18:49:46 -05:00
David Korth
019a0470de Fix some build issues on macOS.
- Split debug symbols doesn't work properly due to an issue with `strip`:
  error: symbols referenced by indirect symbol table entries that can't be stripped in: [library]

- Add "arm64" for M1/M2 Macs.

- zstd: "-fdeclspec" is needed for Clang due to use of __declspec() even
  on non-MS compilers or OSes. Note that we have to check for both
  "Clang" and "AppleClang", since Apple uses its own customized version
  of LLVM/clang.

- msvc.cmake: Make sure "Clang" is quoted when STREQUAL is used.
2023-02-03 19:46:59 -05:00
David Korth
3ee3388996 Enable GTK4 builds.
COMPILING.md: Added packages required for GTK4 (GNOME 43).
2022-10-01 21:08:37 -04:00
David Korth
6e0e0db6d0 [kf6] Preliminary port to KDE Frameworks 6.
KF6 isn't out yet, so this is mostly just a compile test against
Qt 6.

Main changes:

- KeyStoreModel.hpp: #include "KeyStoreQt.hpp" instead of simply
  forward-defining the class.

src/kde/kf6/rom-properties-kf6_autogen/A2AGDIRYKS/moc_KeyStoreModel.cpp:151:1:   required from here
/usr/include/qt6/QtCore/qmetatype.h:858:23: error: invalid application of ‘sizeof’ to incomplete type ‘KeyStoreQt’
  858 |         static_assert(sizeof(T), "Type argument of Q_PROPERTY or Q_DECLARE_METATYPE(T*) must be fully defined");
      |                       ^~~~~~~~~

- stub-export.cpp: Don't set Qt::AA_EnableHighDpiScaling on Qt 6. It's
  always enabled on Qt 6 and this constant is now deprecated.

- AchievementsItemDelegate: QVariant::canConvert(int) is deprecated.
  The recommended replacement is QVariant::canConvert(QMetaType), which
  is Qt 6 only, or alternatively, QVariant::canConvert<T>, which is
  available in Qt 4 and Qt 5.

The only actual compile error I've hit so far is with KFileMetaData
because it uses QMap::insertMulti(), which was removed from Qt 6.
2022-07-02 11:51:37 -04:00
David Korth
510272c7bf Switch to CMake's built-in precompiled headers function.
Among other things, it supports handling multiple targets in a single
subdirectory, which will be needed for the "-dll" targets when converting
libromdata to a DLL on Windows.

NOTE: Requires CMake 3.16. PCH will be disabled if using an earlier
version.

Other changes:

- TARGET_PRECOMPILED_HEADER() ignores force-include flags, so add
  config.libc.h and c++11-compat.h to the header list to ensure that
  stdafx.h has access to them.

- Removed all stdafx.c and stdafx.cpp files. CMake generates its own.
2022-06-21 00:53:13 -04:00
David Korth
1317a931d4 [librptexture] GodotSTEX: Initial implementation of ASTC 8x8 decoding.
Added the ASTC decoder from Basis Universal.

FIXME: The decoded images have swapped R and B channels.
2021-09-03 23:24:42 -04:00
David Korth
bf72456833 [gtk] Initial experimental support for GTK4.
I don't have any GTK4 file browsers to test this, but it compiles.
GTK4 is disabled by default due to this.

GTK4 doesn't support Cairo, so we're falling back to GdkPixbuf for
now. There *is* a new GdkTexture class, which implements most of
GdkPixbuf's functionality without the overhead as Cairo.

Missing functionality:
- Drag & drop needs to be completely rewritten.
- gtk_dialog_run() doesn't exist anymore, so file dialogs need to be
  reworked to use a signal handler. This will work in older versions
  of GTK, too.
  - Also: Handle URIs properly?
- GtkHeaderBar: GTK4 no longer has GtkButtonBox. Figure out "secondary"
  there.
- GTK4 equivalent of gtk_container_set_border_width().

The Nautilus frontend is enabled, but Thunar is not, since that requires
more changes that can't easily be verified at the moment.
2021-07-30 00:08:52 -04:00
David Korth
fd984088a4 Added an option ENABLE_ACHIEVEMENTS to disable the achievement popups.
This won't actually disable achievement tracking, though.

[gtk, kde] Update everything to build properly with achievement popups
disabled.
2020-09-21 21:13:04 -04:00
David Korth
7b282f5d81 [minilzo] Added an internal copy of MiniLZO.
I chose MiniLZO instead of regular LZO because we only need to be able to
decompress LZO1X blocks.

[libromdata] CisoPspReader: Don't call lzo_init() if this JISO isn't
actually using LZO. Otherwise, if the DLL is missing on Windows, the
program will crash.
2020-09-05 11:05:12 -04:00
David Korth
640cb2bf8a [libromdata] CisoPspReader: Added initial support for JISO.
It has a unique header, but the index entries table is similar to the
other formats. It does *not* set the high bit to indicate NC; instead,
it uses the same method as CISOv2, where the compressed block size
matches the uncompressed block size.

Compression algorithm is lzo1x.

TODO:
- JISO supports NC areas. Figure this part out.
- Add LZO to extlib.
2020-09-05 05:03:29 -04:00
David Korth
ad476eb9a0 [lz4] Added a copy of lz4-1.9.2 for PSP CISO. 2020-09-05 02:32:50 -04:00
David Korth
d5d38f67a6 [libromdata] CisoPspReader: Added LZ4 decompression for CISO and ZISO.
ZISO is basically CISO v0/v1 but with LZ4 instead of zlib.

CISO v2 can use either zlib or LZ4 on a per-block basis.

[cmake] Added LZ4 checks.
- TODO: Add an internal copy of LZ4.
2020-09-05 01:27:59 -04:00
David Korth
f8fdaa7ae8 Allow disabling ZSTD entirely using ENABLE_ZSTD.
Similar to ENABLE_XML.

Print ZSTD status in the build summary.
2020-06-27 03:09:19 -04:00
David Korth
dc587561b4 [zstd] Added zstd for use with MiniZip.
MiniZip 2.10.0 added support for zstd as a compression method, so we
should support it.

Note that a system version of zstd is preferred on Linux systems.

Enabled the MiniZip test tools for manual builds only. Info-ZIP hasn't
been updated in a while, so I'm going to use the MiniZip test tools to
compress ZIP archives using zstd.

Enabled MiniZip compression in order to compress stuff using the minizip
test program.

mz_strm_zstd.c: FIXME: Compression level doesn't work. Hard-coded the
maximum compression level for now.
2020-06-27 03:09:15 -04:00
David Korth
fb61cafd1e [gtk] Updated the XFCE (GTK+ 2.x) plugin to use the gtk3 source directory.
The variables have been (mostly) renamed to GTK2, though the user-facing
variable is still BUILD_XFCE, and it shows "XFCE" in the UI_FRONTENDS
status message.

I don't know if I'll be adding support for old GTK+ 2.x Nautilus
versions...
2020-06-23 22:55:24 -04:00
David Korth
58e86c4ab9 [gtk3] Reworked the XFCE (GTK+ 3.x) plugin so it's now part of the GTK+ 3.x plugin.
Same sort of dynamic loading as the Nautilus version, but with separate
plugin initialization code.

thunarx-mini.h: Definitions of various ThunarX structs, since we no longer
use the system-wide version.

Use G_DEFINE_DYNAMIC_TYPE_EXTENDED() instead of the ThunarX version.
Note that for RpThunarProvider, we need to use G_IMPLEMENT_INTERFACE_DYNAMIC().
G_IMPLEMENT_INTERFACE() crashes at runtime, even though the ThunarX
version worked fine. (Presumably, the ThunarX version was actually the
same as the glib DYNAMIC version...)

Added dummy class_finalize() functions, which are needed by the
G_DEFINE_DYNAMIC_TYPE_EXTENDED() macro.
2020-06-23 22:29:40 -04:00
David Korth
9de5d028da [gtk] Renamed the GNOME plugin to gtk3.
Files have been renamed to indicate they're for Nautilus.

The XFCE plugin will be merged in with the GNOME plugin next.
2020-06-23 20:34:21 -04:00
David Korth
6dd716bd1d [gnome] Combine the MATE and Cinnamon plugins into the GNOME plugin.
The only differences are symbol names, which we can resolve at runtime.

Export all three plugin symbols. Depending on which initialization
function is called, we'll dlopen() the appropriate library and load
the symbols.

TODO:
- Create symlinks for the MATE and Cinnamon plugins.
- Update Debian packages to install symlinks.
- Other testing.
2020-04-19 18:01:50 -04:00
David Korth
6234bd0db5 [librpsecure] New consolidated security library.
The os-secure files from rpcli and rp-download have been consolidated
into a single library. seccomp-debug.h has also been moved here and
converted into a .c file with a public interface in the .h file.

rpcli and rp-download can now call rp_secure_enable() with an OS-specific
parameter. A struct is provided that makes the parameter type-safe.

NOTE: syscall_wl (seccomp syscall whitelist) can't be NULL-terminated,
since syscall 0 is valid on most architectures. On x86, it's read().
Hence, we're specifying an explicit array size.

Also moved the Win32 security options and integrity level files here.
Updated Win32 code for this change.

integrity_level.c: Removed the pthread_once() usage for the Windows Vista
check, since we're not linking to librpthreads. The worst that could happen
is both threads set isVista to the same value.

[cmake] Adjusted security options:
- USE_SECCOMP: Moved from cmake/options.cmake to librpsecure/CMakeLists.txt.
- ENABLE_SECCOMP_DEBUG: Added to librpsecure/CMakeLists.txt. Replaces
  the hard-coded SECCOMP_DEBUG in seccomp-debug.h.

[svrplus] Removed the libwin32common dependency. It was only used for the
Windows security options, and that's now handled by librpsecure.

[tests] Updated gtest_init.cpp to use librpsecure. Link all test suites to
librpsecure instead of libwin32common.
- TODO: seccomp() on Linux, pledge() on OpenBSD.
2020-02-26 22:32:21 -05:00
David Korth
058f6c7142 [rp-download] os-secure_linux.c: Linux version using libseccomp.
Tested on Ubuntu 14.04 and Gentoo Linux with glibc-2.31.
2020-02-10 23:14:07 -05:00
David Korth
abdc7efd61 s/Frameowrks/Frameworks/ 2020-01-19 13:32:26 -05:00
David Korth
04db869cee [cmake] options.cmake: "KF5" -> "KDE Frameworks 5" to make it more obvious as to what it is.
[kf5] CMakeLists.txt: Likewise.
2020-01-19 13:31:06 -05:00
David Korth
71a9b61cd8 Renamed the KDE5 frontend to KF5 to match upstream branding guidelines.
Related bug report for LibreOffice:
https://bugs.documentfoundation.org/show_bug.cgi?id=125922

NOTE: dll-search.c still checks for "KDE5" for compatibility.

NOTE 2 We did NOT include "KDE5" in the forwarding plugins for
compatibility because they shouldn't be mixed-and-matched with
rom-properties versions.
2020-01-19 13:28:17 -05:00
David Korth
40e802079f [cmake] options.cmake: Added an option to install AppArmor profiles.
Defaults to ON on Linux; not available on anything else.
(TODO: Disable on *BSD?)
2020-01-19 12:40:37 -05:00
David Korth
6e8c90b906 [oldwincompat] Added stubs for Windows 2000 (and maybe later Win9x) compatibility.
Stubbed functions for MSVC 2010-2017:
- InitializeSListHead()
- GetModuleHandleExW()
- EncodePointer()
- DecodePointer()
- SetFilePointerEx()

rpcli.exe now works, but rom-properties.dll fails to register.

CRT linkage is forced to static when enabling old Windows compatibility
on MSVC 2010 and later, since this is needed in order to get the CRT to
use the stub functions.

References:
- https://stackoverflow.com/questions/19516796/visual-studio-2012-win32-project-targeting-windows-2000/53548116
- https://stackoverflow.com/a/53548116

NOTE: NLS needs to be disabled; otherwise, gettext won't load due to
___mb_cur_max_func not being found in msvcrt.dll. This will require
a rebuild of gettext to use an older version.

Reference:
- https://docs.microsoft.com/en-us/cpp/c-runtime-library/mb-cur-max-func-mb-cur-max-l-func-p-mb-cur-max-mb-cur-max?view=vs-2019
2019-12-21 12:54:28 -05:00
David Korth
4e61fb6668 Make precompiled headers optional.
Enabled by default on MSVC only.

travis-ci still uses Ubuntu 14.04, and PrecompiledHeader.cmake doesn't
seem to pass the `-std=gnu++11` option properly, so gcc-4.8 ends up
failing.

TODO: Use cmake-3.16.0's built-in PCH support if available.
2019-12-18 00:44:56 -05:00
David Korth
0e1af27d94 [gtk] cinnamon: Implementation for Cinnamon desktop with the Nemo file browser.
Nemo is yet another Nautilus fork. Nemo was initially forked from
Nautilus 3.x, so we don't have to worry about GTK+ 2.x versions.

Everything's basically the same as the Caja version, except the
files are named "nemo" instead of "caja".
2019-12-15 15:48:53 -05:00
David Korth
e51803a4fe [librptexture] Use the PowerVR Native SDK (well, a subset) to decode PVRTC.
It seems that the R and B channels are backwards, so we'll need to fix
that next. Other than that, both 2bpp and 4bpp decoding seems to work.
(A lot better than my terrible attempt, at least.)

[cmake] options.cmake: Added an option for PVRTC. The code is licensed
under the MIT license, but we might as well provide an option for it
because it's third-party code instead of my own code.

TODO:
- Fix R/B channel ordering.
- PVRTC-II decoding?
- Add PVRTC decoding to KTX and DDS.
2019-12-10 22:01:21 -05:00
David Korth
2c5a15c559 [librptexture] gl_defs.h: Define all relevant GL enum values here instead of using the system GL headers.
This allows us to eliminate the OpenGL dependency, which lets us get rid
of the CMake option ENABLE_GL.

Removed all ENABLE_GL checks.
Removed #include "config.librptexture.h" where it's no longer needed.
2019-12-09 01:11:30 -05:00
David Korth
c262825fb6 [cmake] options.cmake: Removed USE_INTERNAL_JPEG.
The included copy of libjpeg-turbo was removed in
commit 775a5c9048.
([libjpeg-turbo] Removed the bundled copy of libjpeg-turbo.)
2019-09-21 12:28:58 -04:00
David Korth
255d66f5cc Use GDI+ for JPEG decoding on Windows.
JPEG decoding isn't as strictly checked as PNG decoding, and we don't
need specific JPEG writing functionality e.g. for APNGs and tEXt chunks,
so we can drop the libjpeg-turbo requirement on Windows.

This reduces the Windows distribution by around 1 MB uncompressed.
(521 KB for the 32-bit jpeg62.dll; 535 KB for the 64-bit jpeg32.dll.)

Related: Commit f548b5372d
(Removed the GDI+ PNG loader; renamed RpPng_libpng.cpp to RpPng.cpp.)

[librptexture] rp_image_backend: Allow width and height to be 0 if the
specified format is rp_image::FORMAT_NONE. This is done by
RpGdiplusBackend when constructing a backend using an existing
Gdiplus::Bitmap.
2019-09-21 12:28:58 -04:00
David Korth
de85a062ec Removed S2TC decoding and test images.
S2TC was originally implemented because the S3TC patents were still in
effect. The patents expired in October 2017, which was *before* the
release of v1.2 (the first version with S3TC decoding), but I didn't want
to remove it so close to release.

Pretty much no one used the S2TC version, so it was just wasting space.

Code size reduction: (64-bit Gentoo Linux, gcc-9.1.0, release build)

   text    data     bss     dec     hex filename
  17058       9       0   17067    42ab ImageDecoder_S3TC.cpp.o [before]
  13138       8       0   13146    335a ImageDecoder_S3TC.cpp.o [after]
  -3920      -1       0   -3921    -f51 Difference
2019-06-09 15:06:40 -04:00
David Korth
c0b90585f7 CMakeLists.txt, *.cmake: "INTERNAL" goes *before* the docstring in SET().
This fixes a ton of instances of the following warning, introduced in
cmake-3.14.0:

CMake Warning (dev) at cmake/libs/CheckGettext.cmake:30 (SET):
  implicitly converting 'msgfmt executable.' to 'STRING' type.
Call Stack (most recent call first):
  src/libi18n/CMakeLists.txt:9 (CHECK_GETTEXT)
This warning is for project developers.  Use -Wno-dev to suppress it.
2019-06-09 13:13:44 -04:00
David Korth
19a0394951 [gtk] mate: Initial implementation for MATE Desktop with the Caja file browser.
Caja is a fork of Nautilus 2.x, so everything's basically the same
as the GNOME extension, but with a different prefix.

Note that as of MATE 1.18.0, GTK+ 3.x is used, not 2.x. We're only
supporting GTK+ 3.x for MATE Desktop.

N.B.: Caja is a fork of Nautilus *2.x*, not *3.x*. The extension
interface doesn't seem to have changed, though.

Since the only real changes are names, the mate extension is handled
similarly to xfce3. The subdirectory has a CMakeLists file and defines
an RP_UI_GTK3_MATE macro, but it references the files in the gnome
directory.

gnome: Define RP_UI_GTK3_GNOME to distinguish between the two.

RomDataView: MATE uses the same settings as GNOME.

NOTE: We can't set up the MATE Debian configuration right now, since
Ubuntu 16.04 has a GTK+ 2.x version of MATE. I might set up a separate
"later-debian" directory with the updated files, though.

TODO:
- Both GNOME and MATE use /usr/share/thumbnailers, so the thumbnailer
  file needs to be moved to a common package.
- Caja has an "About Extension" button. Implement this.
- Check Nautilus and other file browsers?
- Make sure all relevant MIME types are added to the XDG service files.
  Caja *requires* the proper MIME types to be added, or else it won't
  thumbnail the files.
2019-06-08 17:12:06 -04:00
David Korth
22ef7f5637 [extlib] libmspack-xenia: Imported libmspack code from the Xenia emulator.
This is a stripped-down version of libmspack containing only the necessary
functionality for Xbox 360 executables.

Xenia commit: e706cf0d5413c31b7e80a50411cc88cc7c71af30
License: LGPLv2.1

config.h.in: Modified for cmake; removed unnecessary checks.

debian/copyright: Added copyright information.
cmake/options.cmake: Added an ENABLE_LIBMSPACK option. (default is ON)
2019-02-01 22:17:56 -05:00
Cameron Cawley
aeceb4fab6 Make building with OpenGL optional. 2018-12-18 23:54:42 +00:00
David Korth
2d2c64f817 [extlib] unice68: Initial import of unice68-2.0.0.690.
This will be used to decompress Atari ST SNDH files.

Note that unice68 is GPLv3, so there's a compile-time option to
disable it.

TODO: Make it a DLL/SO instead and use dlopen().
2018-09-29 11:01:57 -04:00