Commit Graph

381 Commits

Author SHA1 Message Date
Mario Limonciello
661990ed98 Convert build system to use meson tristate features
tristate features will automatically disable if dependencies marked
as required are missing.

Packagers can manually override using `auto_features`.

Link: https://mesonbuild.com/Build-options.html#features
2022-02-28 08:34:48 -06:00
Mario Limonciello
513e75b628 trivial: Add libqrtr-glib-dev to build dependencies
It's needed in debian unstable now for Modem Manager plugin
2022-02-28 06:53:19 -06:00
Richard Hughes
a3efbe51f6 scsi: Add a simple plugin to enumerate SCSI hardware
We might want this to tag insecure or broken SAS drives, cough.
2022-02-24 17:21:51 +00:00
Richard Hughes
da90fca348 trivial: Turn off GPIO support by default
We can swap the default to auto-detection once the auto-features branch
has landed.
2022-02-21 20:37:30 +00:00
Ricardo Cañuelo
9466e778f5 Add a new plugin to handle HP M2xfd monitors
Added support for genesys logic devices.
2022-02-21 08:30:43 +00:00
Richard Hughes
c71ca76235 Add a plugin to set GPIOs for the duration of an update 2022-02-16 14:01:07 +00:00
Richard Hughes
02f003a195 trivial: Build pcre when building static CI tools 2022-02-09 11:58:50 +00:00
Richard Hughes
740bddf7dd trivial: Do not use use sudo to use firmware-build
It's not needed anymore.
2022-02-09 11:58:50 +00:00
Richard Hughes
c716cac45c trivial: Move the CI to Fedora 35 2022-01-30 20:02:32 +00:00
Mario Limonciello
e742e4fc10 trivial: ci: fix ubuntu ci 2022-01-27 15:02:19 -06:00
Crag Wang
fbcc031ae4 trivial: refresh bash completion to reflect recent changes 2022-01-17 13:41:20 -06:00
Mario Limonciello
8918a4f168 trivial: ci: don't enable debian unstable apt pins 2022-01-02 12:28:54 -06:00
Richard Hughes
60d266cbc6 Add support for UF2 devices
A UF2 device exposes a VFAT block device (sometimes called a Mass
Storage Device) which has a virtual file called `INFO_UF2.TXT` where
metadata can be read. It may also have a the current firmware exported
as a file called `CURRENT.UF2` which is in a 512 byte-block UF2 format.

Writing any file to the MSD will cause the firmware to be written.
Sometimes the device will restart and the volume will be unmounted
and then mounted again. In some cases the volume may not “come back”
until the user manually puts the device back in programming mode.

Match the block devices using the VID*PID, UUID or label, and then
create a UF2 device which can be used to flash firmware.

Note: We only read metadata from allow-listed IDs to avoid causing
regressions on non-UF2 volumes. To get the UUID and label you can
use commands like:

    udisksctl info -b /dev/sda1
2021-12-21 10:06:18 +00:00
Mario Limonciello
db94a995bd trivial: contrib/setup: if markdown isn't installed don't show an error
```
Install developer-friendly **unsafe** PolicyKit rules into /etc/polkit-1/rules.d? (y/N) n
Traceback (most recent call last):
  File "/home/supermario/fwupd/./contrib/ci/fwupd_setup_helpers.py", line 154, in <module>
    test_markdown()
  File "/home/supermario/fwupd/./contrib/ci/fwupd_setup_helpers.py", line 34, in test_markdown
    import markdown
ModuleNotFoundError: No module named 'markdown'
Collecting markdown
  Downloading Markdown-3.3.6-py3-none-any.whl (97 kB)
     |████████████████████████████████| 97 kB 1.1 MB/s
Collecting importlib-metadata>=4.4
  Downloading importlib_metadata-4.8.2-py3-none-any.whl (17 kB)
Collecting zipp>=0.5
  Downloading zipp-3.6.0-py3-none-any.whl (5.3 kB)
Installing collected packages: zipp, importlib-metadata, markdown
Successfully installed importlib-metadata-4.8.2 markdown-3.3.6 zipp-3.6.0
```
2021-12-16 07:07:33 -06:00
Mario Limonciello
dabfac661e trivial: win32: disable motd writing by default 2021-12-15 06:46:27 -06:00
Richard Hughes
251f6348aa trivial: Add the missing plugin_cpu
I think using the plugin_uefi_pk option was probably a typo.
2021-12-10 12:00:33 +00:00
Richard Hughes
c47446c411 trivial: Add liblzma-dev the deps in case we're building a subproject 2021-12-06 17:57:23 +00:00
Richard Hughes
02eac5c75f Make more plugins optional 2021-11-29 09:30:57 +00:00
Richard Hughes
dc1d5de057 Make the HSI tests optional for embedded targets
70% of the plugins installed on OpenBMC are not being used...
2021-11-29 09:30:57 +00:00
Richard Hughes
3291bd40ce Make Upower and powerd support optional
In some cases you really know that the daemon is never going to exist.
2021-11-27 18:46:27 +00:00
Richard Hughes
71d93a65fb Make sqlite optional
This isn't required when fwupd is installed on targets like a BMC.
2021-11-23 15:09:05 +00:00
Richard Hughes
6ac7b93d70 trivial: Remove the libelf dep for CI
Fixes https://github.com/fwupd/fwupd/issues/4009
2021-11-19 11:03:24 +00:00
Richard Hughes
9ef27052d5 altos: Remove support for the ChaosKey
The hardware is discontinued, and no further update from 1.6.7 was ever
supplied.
2021-11-15 15:17:38 +00:00
Richard Hughes
a9e696ab62 solokey: Remove support for the SoloKey device
The vendor does not intend on uploading firmware for this EOL device.
For the Solo V2 the vendor wants to use a different flashing protocol,
so all this is just dead code now.
2021-11-15 15:17:07 +00:00
Richard Hughes
5f01678daa Use -Doffline=false to reduce the install size by over 100Kb
If there's no SuperIO chip then there's no need to support this.
2021-11-12 21:06:34 +00:00
Richard Hughes
34d531074c Use -Dmetainfo=false to reduce the install size by over 100Kb 2021-11-12 21:06:34 +00:00
Richard Hughes
36d7077f65 Add a new plugin to handle MTD devices 2021-11-05 20:01:51 +00:00
Crag Wang
1be055fb1e trivial: check-license: exclude files from build directory earlier 2021-10-29 12:21:55 +08:00
Richard Hughes
28678235cd Move the fuzzing files into the plugin directories
We only had to pile everything into the src/fuzzing/firmware directory
because honggfuzz could not cope with more than one input path.

This way each plugin is self contained and easy to copy.
Also, install the fuzzing builder objects as this fixes the installed
tests when srcdir does not exist.

Based on a patch by Jan Tojnar <jtojnar@gmail.com>, many thanks.
2021-10-22 15:24:05 +01:00
Richard Hughes
2d00cda464 Remove PLUGINBUILDDIR and use G_TEST_SRCDIR and G_TEST_BUILDDIR instead
This allows us to override the location we load data files from, which
allows us to do more kinds of installed tests in the future.

Also, move the global data/tests content into the place that it is used
as it was getting impossible to manage.
2021-10-21 18:36:22 +01:00
Richard Hughes
a5ef3629d4 trivial: Build the fuzzers with -g to get stacktraces 2021-10-18 20:02:03 +01:00
Richard Hughes
7f5b0c0b60 Rename the development branch from master to main
Fixes https://github.com/fwupd/fwupd/issues/3799
2021-09-24 14:20:24 -05:00
michaelcheng04
10549674b1 Add a plugin to flash Elan fingerprint reader hardware 2021-09-23 10:41:00 +01:00
Mario Limonciello
cc8eb5ca8c trivial: Merge python steps from contrib/setup into helper script
This avoids having to hardcode profile targets in multiple places
and also fixes the confusing entry points into scripts both by
arguments and environment variables.

It also makes the setup script a lot more debuggable and scalable.

OS detection is a lot more robust, where it will try to use pip to
set up the distro python package, and if pip is missing try to install
it.

If OS detection fails now, a user can use --os on contrib/setup for
specifying it.
2021-09-17 10:59:35 -05:00
Mario Limonciello
349975bb70 trivial: setup: drop the special case for python3-venv
Install it via dependencies.xml like the rest
2021-09-17 10:59:35 -05:00
Mario Limonciello
24970acf4a trivial: generate_dependencies: add variant to OS strings that are generated 2021-09-16 06:43:55 -05:00
Mario Limonciello
15f0029624 trivial: generate_dependencies: fallback to "like" distros
This should cause linuxmint to run the Ubuntu dependency resolution.
2021-09-16 06:43:55 -05:00
Mario Limonciello
0c77e34c73 trivial: drop the flatpak target
We don't use it for dependency building at all.
2021-09-16 06:43:55 -05:00
Mario Limonciello
05a3ee1fc8 trivial: generate_dependencies: use distro.id() to better find defaults 2021-09-16 06:43:55 -05:00
dkwo
d6645e1447 update void linux ci target 2021-09-14 16:07:10 -05:00
Simon Ho
5e67108ab8
plugins: add new plugin for Synaptics CAPE devices (#3746)
CAPE family is Audio DSP for a board range of applications in IOT, PC
and mobile can be interfaced via I2C, UART or USB interface. This patch
is only for CX31993 and CX31988 chips, there is not immediate plans is
to add support to other CAPE devices.

CX31993 have two separate firmware .hid file for for each partition. It
need to convert two .hid files into a .fw file for fwupd tool to
consume.

Currently, this patch is only support for EPOS headsets with basic
firmware update feature. Either new code singing or manifest.xml are
unsupported yet.

The code has been tested with CX31993 EVK board.

A test firmware file is put at 'src/fuzzing/firmware/synaptics-cape.fw'

synaptics-cape: Port to new FuProgress API and style fixups

synaptics-cape: Fix compile errors and add missing test fw file

Signed-off-by: Simon Ho <simon.ho@synaptics.com>

synaptics-cape: Fix fuzzer test

Signed-off-by: Simon Ho <simon.ho@synaptics.com>

synaptics-cape: Fix progress bar number

Signed-off-by: Simon Ho <simon.ho@synaptics.com>

synaptics-cape: Mark the fuzzing target

trivial: Use a stable GLib branch for fuzzing

synaptics-cape: Fix progress bar number

Signed-off-by: Simon Ho <simon.ho@synaptics.com>

synaptics-cape: Fix readme

synaptics-cape: Style fixups

synaptics-cape: Fix progress bar percentage

synaptics-cape: Style fixups
2021-09-15 03:42:07 +08:00
Mario Limonciello
113c784ce4 trivial: run Ubuntu CI target tests with "nobody" user account
This should ensure that self tests are never trying to access or
create things they shouldn't be.
2021-09-03 15:10:38 -05:00
Sean Rhodes
42136840bd contri/ci: Add dependancies for flashrom
Add libpci-dev for Ubuntu and Debian as it's required for flashrom
2021-09-03 12:49:57 -05:00
Sanjay Sheth
b6ff1ea40e Add support for devices supporting the Logitech bulk controller protocol 2021-08-29 20:33:16 +01:00
Mario Limonciello
55de39c077 trivial: reformat the whole tree to match new format 2021-08-24 11:18:40 -05:00
Richard Hughes
c1ff02f055 trivial: Make the quirk style more consistent 2021-08-23 18:10:12 +01:00
Richard Hughes
6a8f285ee2 Check the quirk format as part of precommit 2021-08-23 18:10:12 +01:00
Norbert Kamiński
3fe782cddd build_freebsd_package.sh: Build package with generated pkg-plist
Signed-off-by: Norbert Kamiński <norbert.kaminski@3mdeb.com>
2021-08-18 08:39:11 -05:00
Norbert Kamiński
c1f06b6b82 freebsd-ci: Change FreeBSD artifact extension
Signed-off-by: Norbert Kamiński <norbert.kaminski@3mdeb.com>
2021-08-18 08:39:11 -05:00
Mario Limonciello
684bc03813 trivial: fix various shellcheck warnings 2021-08-18 07:58:17 -05:00