Only configure distcc variables if a module does not have the "nodistcc" flag.
Skip builder/setup modules to avoid having distcc changes propagate to modules built from them.
This allows easily disabling distcc for certain modules that are not compatible.
Pi5 needs an additional X11 configuration stanza for xorg-xserver to start properly. This configuration is handled by the `gldriver-test` package, which installs a couple of services that create the needed configuration files based on the displays connected to the board (HDMI/DSI/etc.). Technically, once the services have run the package can be removed IIF the type of display connection will not change (i.e. will always use HDMI or DSI, etc.)
Since this package is only installed with `raspberrrypi-ui-mods` (i.e. the RaspiOS desktop), let's install it by default on Pi5. The only dependency for the package is `raspi-config`, which is already present on any RaspiOS installation.
Bookworm has changed the RP repo location to 'archive.raspberryp.com', due to a larger RPF operation to leave the .org just for the Foundation.
To detect whether we're running on RasPI OS, make sure we check for the new domain in the output from `apt-cache`.
The 'Hardware' field has been removed from the output of '/proc/cpuinfo' after [1], so the setup script will not correctly identify it's running on a Raspberry PI.
Use '/proc/device-tree/compatible' to check whether we're on a Raspberry Pi, the same method used for other SBCs.
Model calculation based on the Revision field from '/proc/cpuinfo' needs to be run in 2 places, so the code has been put in a separate function.
[1] 17804c2030
Added support for detecting if running on a Armbian built system.
Armbian is built on Debian/Ubuntu, so we're not changing the OS release/name.
* Added support for Armbian's Linux kernel package naming, in order to be able to install the kernel headers.
* Removed the ZRAM config from our own menu, Since Armbian has its own configuration tool (`armbian-config`) that handles it. ZRAM is configured and enabled y default on Armbian images.
Added basic support for detecting and building on the Rockchip 3588(s) SOC.
The SOC is used in several ARM based SBC including Radxa Rock 5(A/B), Orange Pi 5(B), Khadas Edge 2.
The CPU is an octocore package with 4x Cortex-A76 + 4x Cortex-A55 cores.
There are several distributions that support these systems, vendor provided images including a proprietary Mali blob with OpenGLES 3.2/OpenCL support or community provided images using either a Mesa fork for GLES/X11/Wayland support. For now, the platform has an `x11` flag to allow most of the emulators to be installed, but we might switch to dynamically detecting the desktop platform (i.e. `wayland` / `x11` depending on the system).
gcc -dumpversion on GCC >= 7 seems to provide the major version but the documentation suggests this depends on how it's configured.
We only need to test the major version so using compareVersions isn't required.
https://gcc.gnu.org/onlinedocs/gcc/Developer-Options.html states:
>Print the compiler version (for example, 3.0, 6.3.0 or 7)—and don’t do anything else. This is the compiler
>version used in filesystem paths and specs. Depending on how the compiler has been configured it can be
>just a single number (major version), two numbers separated by a dot (major and minor version) or three
>numbers separated by dots (major, minor and patchlevel version).
Ensure __gcc_version only contains the major version just in case in system.sh
There was a mix of compareVersions "$__os_debian_ver" OP $arg and [[ "$__os_debian_ver OP $arg ]] around the code.
As $__os_debian_ver is always an integer, use the bash built in operators for performance.
The compareVersions call is significantly slower as it uses an external command (dpkg).
Add the Debian version for the Debian Edition of Linux Mint.
- version 4 is based on Debian 10 'buster
- version 5 is based on Debian 11 'bullseye'
Older versions (1 to 3) are no longer supported upstream.
crc and simd and enable by default in all versions of gcc so would be redundant to add here.
Cortex-A57 armv8.0 has optional crypto extensions so they are not enabled by default. TX1 and TX2 have these extensions available in hardware.
For architectures not handled by custom logic, we previously checked `uname -m` for i686/x86_64/amd64 and then set __platform=x86.
This change switches to using the actual output of `uname -m` as the __platform variable. If a platform_$__platform function exists, we will call it, otherwise we call platform_native (which used to be platform_x86).
In platform_native we check if the platform is i386/i686/x86_64 and then set an x86 flag.
This seems more logical and allows us to more easily check for x86_86 in scriptmodule flags. It also resolves redream incorrectly having x86_64 added to the flags in d877a81 (which work after this change).
The error: fatalError "Unknown platform - please manually set the __platform variable to one of the following is now removed. As we default to platform_native this could potentially allow RetroPie-Setup to work on something we don't specifically support.
It was reported that Elementary OS Odin identifies as "Elementary" rather than "elementary" via
lsb_release so switch to using "[eE]lementary" in case statement to recognise both.
This doesn't guarantee modules will work as this isn't a distro we test on ourselves.
Move much of the helpers.sh start/stop logic and default parameters to a joy2key wrapper script.
Switch runcommand.sh to use new wrapper script
Add tab button to "y" key for use in edit dialogs
Remove runcommand $md_inst on update. If old joy2key is present in runcommand install, trigger joy2key module install.
Remove system.sh python3-sdl2 dependency check - moved to joy2key_depends
Added a new `joy2key` implementation, using PySDL2 for joystick event handling.
PySDL2 is a python module that wraps SDL2 (and other SDL libraries) using the built-in `ctypes` module.
Pros:
* event handling is simplified a bit, using SDL's event loop.
* (subjective) the code is a bit more structured and easy to follow.
* joystick handling is rewritten based on EmulationStation code, movement is smoother and scrolling is improved.
* support for input repeat to improve scrolling, just keep the input pressed and scrolling continues
Cons:
* module is a bit larger (296 LOC vs 224 in current joy2key.py)
* needs PySDL2 (which might not be packaged, see the notes below) and SDL2
* arguably, device config to keyboard event mapping is more complex (abstracted as InputDev)
Notes:
* availability of PySDL2 as a system package is good, but it's not standard in Debian 10 (stable) at the moment.
The module is present though (as a backport) in Ubuntu 18.04 (and later) and Raspberry Pi OS (Buster).
When it will be universally available, we should probably revisit the code that checks for the version and make it a hard requirement in `get_retropie_depends`, similar to `python3-pyudev`.
* added PgUp/PgDown to the default parameters for `joy2key`, they are mapped in a similar fashion to EmulationStation to the shoulder buttons. This doesn't apply to Runcommand's invocation, since it uses a different set of parameters.
* added a configuration option in `runcommand` for selecting the joy2key version used. Default is the SDL version (when PySDL2 is installed), with the ability to fallback to the previous version (udev based).
* dropped hotkey hack patch as now integrated with config option input_hotkey_block_delay with default of 5 (as was our patch)
* rebased disable search patch (code moved back to retroarch.c for now)
* rebased / updated shader path config enable patch (thanks @cmitu)
* revert the default saves/states/sytem path change as we rely on the old behaviour
* default to using ON/OFF text instead of rgui_switch_icons graphics
* added gles3.1/3.2 configure parameters using gles31/gles32 flags
* added gles31 flag to rpi4 system. Mali boards should support 3.2 but need to test before adding
Also moved the retropie email used for checking to __gpg_retropie_key and use this rather than __gpg_signing_key
as we hardcode the install of the actual key - so the logic didn't make sense in the case of wanting to sign
with another key. But __gpg_signing_key can now be set to an empty string to bypass signing of binaries as used
by the build scripts. This is only useful for developers/testing binary creation on systems without our signing key.