- Put this in a method of its own even though it's used
only once, so we can put a good name on it.
- If there are no FS choices (e.g. the sample settings file)
then there is no combo-box, and the check was crashing.
FIXES#2029
This works around older CMakes that refuse to set arbitrary
properties on a target. Instead, use calamares::kpmcore
as the specific indicator that kpmcore was found.
Breaks build of libcalamares, since that needs **something**
regardless of whether KPMcore was found.
- wrangle the test framework so it hands the same data to
two different collections of tests; do KDE neon and FreeBSD
separately so it's clearer which lookups are being done
(and a failure in one doesn't prevent the test of the other).
- the alias libraries calapmcore and calamares::kpmcore
are always created; if there is no KPMcore, they handle
definitions to signal that.
- upstream kpmcore target is the one we should be testing
to see if KPMcore itself is there (or, use KPMcore_FOUND).
- FileSystem.h depends on KPMcore and only compiles when
KPMcore is present; it can use KPMcore identifiers.
- Global.h doesn't.
- Move the few functions introduced into Global.h that need
KPMcore, to FileSystem.h instead.
When KPMcore is present, the calamares::kpmcore wraps that
and provides suitable API detection. If KPMcore is not
present, the same interface library provides -DWITHOUT_KPMcore.
- kpmcore (when used as target "kpmcore") has an interface
include directory that does not contain the "kpmcore/"
subdirectory. But the headers it has installed, assume it
is there (e.g. kpmcore internals use #include <fs/filesystem.h>).
- add an alias at Calamares level that sticks in some more
includes, adds the relevant WITHOUT_kpmcore when it's
not there, etc.
The distinction CalamaresUtils and Calamares is old-fashioned,
since we can use nested namespaces (and already do) for a lot
of things; make libcalamares/locale/ a bit more consistent
by using namespace Calamares::Locale for everything.
Some distro's let the user change the hostname at will;
others don't, and yet others don't have systemd to change
the hostname with at all. Check if we **can** change the
hostname (as a non-root user), before setting expectations.
- remove "bogus" key when it's not needed
- check for existence of "branding" key in GS before
subscripting it (this happens in tests, where no
GS contents are loaded, but not in regular use,
where startup loads the branding data into GS)