Commit graph

237 commits

Author SHA1 Message Date
Pascal de Bruijn 5ba81d0109 package/systemd: use interface name for networkd config file
By using the interface in the filename for the networkd config file,
we have a clear association between the config file and the interface
it applies to.

This is beneficical for systems that have multiple interfaces.

Signed-off-by: Pascal de Bruijn <p.debruijn@unilogic.nl>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2020-02-03 23:43:49 +01:00
Yann E. MORIN b0d94ad5ad package/systemd: add dependency on host-coreutils
This is needed as systemd has gained a dependency on realpath(1) which
was introduced in coreutils too recently for our supported distro to
have it (Ubuntu 14.04 does not have it from coreutils, although there is
a dedicated package for it).

This also means that we now have a ln that understands --relative, so we
can drop our workaround, that upstream said they would never accept
anyway [0].

[0] https://github.com/systemd/systemd/pull/5682

Fixes:
    http://autobuild.buildroot.org/results/a9a/a9a285e482285d062892bab0d1a2e2f89928c92d/
    http://autobuild.buildroot.org/results/6f5/6f5b1065859d866af6fa719f611c3ea7f4b88760/
    ...

Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
Cc: Adam Duskett <aduskett@gmail.com>
Cc: Maxime Hadjinlian <maxime.hadjinlian@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2020-01-06 21:44:00 +01:00
Jérémy Rosen 9bdeb0b344 package/systemd: bump to 244.1
Signed-off-by: Jérémy Rosen <jeremy.rosen@smile.fr>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2019-12-19 18:04:49 +01:00
Jérémy Rosen 6c3944a057 package/systemd: fix tty handling
Handling of tty is a bit tricky, we need to aggressively disable what
systemd does with tty1 then update for what buildroot wants to do

Rework the whole tty generation to work with presets

Signed-off-by: Jérémy Rosen <jeremy.rosen@smile.fr>
[yann.morin.1998@free.fr:
  - fold long lines
  - drop spurious empty lines removals
]
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2019-12-18 18:27:41 +01:00
Jérémy Rosen 231ad359bc package/systemd: use host-systemctl preset all to enable units
since v234 upstream recommands using systemctl preset-all to enable units.
* add a buildroot specific preset file
* use that file to disable getty@tty1
* make systemd depend on host-systemd
* remove all link-creating code that systemd does for us.

Most packages will not be affected by this change, but a few packages
were installing units without manually enabling them. Those packages
will now be automatically enabled.

The fact that those packages were not enabled is almost certainly a bug,
but it is a change of behaviour that needs to be reported

host-systemd also builds udevadm for the host. That means we no longer
need to depend on host-eudev to provide udevadm (that would conflict).

Signed-off-by: Jérémy Rosen <jeremy.rosen@smile.fr>
[yann.morin.1998@free.fr:
  - also remove the hwdb sources on fs generation
  - fix check-package errors
  - few typoes and reformatting in commit log
]
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2019-12-18 18:27:41 +01:00
Jérémy Rosen 35c11a027c package/systemd: add host variant
Add the infrastructure to build the host version of systemd
* disable all optional features, they can be re-added when needed
* systemd has creative way of dealing with cross compile
  we build a "normal" host systemd, but install it in $HOST_DIR
  we use systemctl --root to correctly act on TARGET_DIR
* we need to adjust RPATH using patchelf because meson can't do it
  correctly by itsel

The first question is: why do we use --prefix=/usr ?

systemd will store its --prefix in all the executables it generates. As
such, systemctl will have a hardcoded 'prefix', where it will manipulate
and create files/symlinks in. When called natively, this is nice and
shinny.

However, for cross-setup, that does not work obviously.

So, systemd has its tools know about the 'root' directory where this
prefix should be related to. We can call systemctl --root=$(TARGET_DIR)
and systemctl wil do the links and such in there.

However, it does so by appending its known prefix to it.

So, if we were to configure host-systemd as we usually do, with
--prefix=$(HOST_DIR), then when we would call host systemctl --root=$(TARGET_DIR)
it would look for files in $(TARGET_DIR)/$(HOST_DIR), which is wrong.

Calling the host systemctl without --root is also wrong, as it would look for
files in $(HOST_DIR)

So, there is no satisfying official support for this case.

The trick then, is to configure systemd with the prefix it would expect
at runtime (on the target!), that is with /usr, but install out-of-tree.

That was it for the first part of the question: why do we use --prefix.

Now, the second question is: why do we need to muck up with the rpath
after installation?

Well, this boils down to meson (and not systemd itself). When it
installs executables, meson will handily insert whatever rpath the
package meson.build would tell it to use. systemd installs libs in
$(prefix)/lib/systemd and has a NEEDED to those libs, so it uses an
RPATH to find those libs, and meson does inject that RPATH into the
installed executables.

However, we Buildroot also want to insert our own RPATH, because systemd
uses util-linux' libs and libcap, installed in $(HOST_DIR), so it needs
our RPATH.

However, meson can not extend the RPATH from the LDFLAGS in the
environment; meson can only set the RPATH from what it knows about from
the package's meson.build.

That, in addition to the --prefix=/usr issue above, means that the
executables installed by host-systemd have an RPATH set to
/usr/lib/systemd. when we would want it to be set to
$(HOST_DIR)/lib:$(HOST_DIR)/lib/systemd

That's what is done in the post-install hook: set the RPATH to the
appropriate values.

Signed-off-by: Jérémy Rosen <jeremy.rosen@smile.fr>
[yann.morin.1998@free.fr:
  - reformatting in commit log
  - declare host variant after target variant
  - simplify comments
  - slight reordering of variable (HOST_SYSTEMD_NINJA_ENV moved)
  - reformatting for mutli-line variable (HOST_SYSTEMD_HOST_TOOLS)
  - don't split HOST_SYSTEMD_CONF_OPTS in two sets
]
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2019-12-18 16:51:44 +01:00
Adam Duskett 35f1195979 package/systemd: bump to version 244
Other changes:
  - Update hash for README due to added licence directory tools/chromiumos.
  - Add hash for tools/chromiumos/LICENSE
  - Added BSD-3-Clause (tools/chromiumos) in systemd.mk due to the new
    tools/chromiumos directory.
  - Added tools/chromiumos/LICENSE to SYSTEMD_LICENSE_FILES in systemd.mk

Signed-off-by: Adam Duskett <Aduskett@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-12-08 16:53:36 +01:00
Adam Duskett ce2a5eff78 package/polkit: bump to version 0.116
Other changes:
  - Add spidermonkey as a dependency.
  - Add 0001-make-netgroup-support-optional.patch to allow building on musl.
  - Add a runtime dependency on dbus.
  - Add --disable-libelongind.
  - Add --disable-libsystemd-login.
  - Update dependencies for systemd pam support.
  - Update dependencies for udisks.

Signed-off-by: Adam Duskett <Aduskett@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-12-08 15:56:32 +01:00
Fabrice Fontaine 274a4092ee package/systemd: fix license hash
Bump to 243.4 forgot to update hash of README file (update to the
requirements).

Fixes:
 - http://autobuild.buildroot.org/results/eae13046b90253cdb2bf260e10b316386dff4eb1

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
[yann.morin.1998@free.fr: explain why README was changed]
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2019-11-24 20:14:40 +01:00
Jérémy Rosen d3af5d7040 package/systemd: bump to v243.4
Upstream systemd-stable has started tagging point releses.

The commit we currently used has now been tagged as v243.3, and this
brings us to v243.4.

Signed-off-by: Jérémy Rosen <jeremy.rosen@smile.fr>
[yann.morin.1998@free.fr:
  - expand commit log to explain previous version
]
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2019-11-23 22:23:12 +01:00
Christian Stewart 272695277e package/systemd: hybrid cgroupfs hierarchy for docker compatibility
Docker fails to start with "Devices cgroup isn't mounted" as of systemd 243.
According to the systemd documentation:

  systemd now defaults to the "unified" cgroup hierarchy setup during
  build-time, i.e. -Ddefault-hierarchy=unified is now the build-time default.
  Previously, -Ddefault-hierarchy=hybrid was the default. [...] Downstream
  production distributions might want to continue to use
  -Ddefault-hierarchy=hybrid (or even =legacy) for their builds as unfortunately
  the popular container managers have not caught up with the kernel API changes.

Changing this option to "hybrid" or "legacy" fixes the Docker startup.

Reference: https://github.com/opencontainers/runc/issues/654

Signed-off-by: Christian Stewart <christian@paral.in>
Tested-by: Jérémy Rosen <jeremy.rosen@smile.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-11-11 16:28:36 +01:00
Jérémy Rosen 1be112679d package/systemd: bump to 243-78
The systemd project maintains a separate repository on github where patches
are backported on top of released version by the systemd maintainers.

This patch changes the SYSTEMD_SITE to point on that repository and points
to the latest version of v243, which was the previous version used by
systemd.

Unfortunately, upstream does not tag any version,so we use 'git describe'
as a SYSTEMD_VERSION

Signed-off-by: Jérémy Rosen <jeremy.rosen@smile.fr>
Reviewed-by: James Hilliard <james.hilliard1@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-11-01 11:37:41 +01:00
Yann E. MORIN 6feba7cba1 packagesystemd: generate the hwdb.bin
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
Cc: Peter Korsgaard <peter@korsgaard.com>
Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Cc: Carlos Santos <unixmania@gmail.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2019-11-01 08:53:04 +01:00
Titouan Christophe f81b26ec52 package/systemd: fix README hash
Fixes: http://autobuild.buildroot.net/results/487/4878af2ed318925ab530062576f91e7a1af47bd5/

Signed-off-by: Titouan Christophe <titouan.christophe@railnova.eu>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-10-27 19:24:18 +01:00
Carlos Santos 0e51737575 package/systemd: create /etc/resolv.conf only if resolved is selected
Or else it becomes a dangling link to
/run/systemd/resolve/resolv.conf, which is never created. Even worst,
it also prevents NetworkManager from updating resolv.conf.

Fixes:
  https://bugs.busybox.net/show_bug.cgi?id=9881

Signed-off-by: Carlos Santos <unixmania@gmail.com>
Reviewed-by: Yann E. MORIN <yann.morin.1998@free.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-10-26 19:03:15 +02:00
James Hilliard cb402832a9 package/systemd: bump version to 243
Added config option for new systemd-pstore feature.

Removed patches that have been committed upstream.

Added symlinks required to enable some services.

After extensive discussion with upstream it does not seem there is any
acceptable option to have symlink installation handled on their side.

The recommended solution from upstream is to have systemctl handle
service installation, however this has a number of downsides such as
requiring us to build a host-systemd just to install a few symlinks.

Since we already customize service installation it is simpler for us
to create the symlinks ourselves, this will also simplify service
customization on our side as we will not need to disable any systemd
default services in cases where we need to make customizations.

In addition using systemctl would introduce a minimum host headers
dependency in which we don't have the infrastructure to handle
properly.

The downside to this approach is that we need to track service creation
changes from upstream ourselves, however this is relatively straightforward
and since upstream service file locations are relatively stable regressions
should be limited. This will mostly be a concern in regards to adding
support for new systemd features.

Details:
https://github.com/systemd/systemd/issues/12767
https://github.com/systemd/systemd/pull/12164
https://github.com/systemd/systemd/pull/12769
https://github.com/systemd/systemd/pull/12775

Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
Tested-by: Jérémy Rosen <jeremy.rosen@smile.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-10-26 16:14:33 +02:00
Arnout Vandecappelle (Essensium/Mind) 1fa9b0d267 Revert "package/util-linux: build programs and libraries in separate packages"
This commit was pushed accidentally, it was not yet ready for prime
time. A better way to implement it was proposed.

In addition, it still introduces a circular dependency: systemd ->
polkit -> libglib2 -> util-linux -> systemd

This reverts commit 335c77b667.
2019-08-23 00:29:51 +02:00
Carlos Santos 335c77b667 package/util-linux: build programs and libraries in separate packages
The findmount and lsblk utilities need udev to work correctly but cannot
be built with udev support because the packages providing libudev (eudev
and systemd) depend on util-linux, creating a chicken-egg problem. Solve
it by means of the following changes:

- Split util-linux into three packages:
  - util-linux-libs, providing lib{blkid,fdisk,mount,smartcols,uuid}.
  - util-linux-programs, providing both the aforementioned libs and the
    programs.
  - util-linux, a dummy package that drives configuration and building
    of the other ones.
- Add blind selections for -libs and -programs, i.e. they are indirectly
  selected according to the util-linux options.
- Make util-linux have build dependencies on util-linux-{libs,programs}
  if they are selected.
- host-util-linux has a build dependency on either host-util-linux-libs
  or host-util-linux-programs (not on both, since they are installed on
  the same destination).
- Make eudev and systemd have build dependencies on util-linux-libs.
  This can be extended to other packages in the future but is not needed
  right now because the configuration options are backward-compatible.
- Make util-linux-programs have an optional build dependency on the
  package that provides libudev (either eudev or systemd), if it is
  selected.

util-linux-libs is installed on STAGING_DIR by default and on TARGET_DIR
if util-linux-programs is not selected. Conversely, util-linux-programs
installs on TARGET_DIR by default and on STAGING_DIR if util-linux-libs
is not selected. This prevents installing the libraries twice on the
same destination, which would confuse check-uniq-files.

With this approach we don't need to patch configuration files neither
change other packages besides eudev and systemd. Other packages that
require util-linux libraries and whose libraries can be used by
util-linux programs can be updated later. We also don't need to change
any existing defcconfig, since all configuration options are kept in
the dummy util-linux package.

The main drawback of this approach is that util-linux-rebuild, as wel as
-reinstall, -reconfigure and even -dirclean targets do not have real
effect. It's necessary to use util-linux-libs-rebuild, for instance, but
this is a reasonable price to pay for the solution.

Fixes: https://bugs.busybox.net/show_bug.cgi?id=11811

Signed-off-by: Carlos Santos <unixmania@gmail.com>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
2019-08-21 00:48:07 +02:00
Fabrice Fontaine dfcd5b9ff9 package/systemd: drop host-intltool dependency
intltool is not needed since version 236 and
c81217920e
9e8f3893e3

So drop it and replace it by TARGET_NLS_DEPENDENCIES

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-08-12 22:47:14 +02:00
Adam Duskett 819cfcf7aa Standardize Adam Duskett's email address
Globally change Adam Duskett's email address to aduskett@gmail.com.

Note that one or two of the patches may have been applied upstream with
the old email address, but in that case those patches will anyway be
removed when bumping.

Signed-off-by: Adam Duskett <Aduskett@gmail.com>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
2019-07-04 00:10:47 +02:00
Yi Zheng 2dbce34b3a package/systemd: add option to enable systemd-journal-remote
systemd-journal-remote was added in systemd v211, so add a new option
to enable or disable it.

Signed-off-by: Yi Zheng <goodmenzy@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-06-17 21:28:36 +02:00
Fabrice Fontaine 67cfbbd2ee package/systemd: fix build due to missing -lrt
Fixes:
 - http://autobuild.buildroot.org/results/a27d2e865ca620b6b2c6f39a07385f74fcfbb385

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
2019-05-01 15:38:34 +02:00
Fabrice Fontaine 29d6181885 package/systemd: fix patch order
Rename 0002-install-don-t-use-ln-relative.patch to
0001-install-don-t-use-ln-relative.patch as there is two 0002-xxx
patches

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
2019-05-01 15:38:23 +02:00
Fabrice Fontaine 9443d2b24c package/systemd: update BR2_PACKAGE_SYSTEMD_ARCH_SUPPORTS
systemd supports:
 - nios2 since version 230 and
 b79660e6ac
 - riscv sinc version 232 and
 171b533800
 - aarch64_be (tested with qemu_aarch64_virt_defconfig reconfigured to
 aarch64_be)
 - sparc64 (tested with qemu_sparc64_sun4u_defconfig)
 - mips64 and mips64el (tested with qemu_mips64el_malta_defconfig)

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
2019-04-16 00:06:51 +02:00
Yann E. MORIN 2ff6ee0947 package/systemd: drop optiopns that are now conditional
Commit 6f28ce5322 (package/systemd: enable building of systemd-boot)
made the efi and gnu-efi optiona conditional upon whether systemd-boot
is built or not, but forgot to remove the non-conditional ones.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: James Hilliard <james.hilliard1@gmail.com>
Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-03-17 14:21:23 +01:00
James Hilliard 6f28ce5322 package/systemd: enable building of systemd-boot
systemd-boot is the integration of gummiboot into systemd, when
gummiboot is no longer maintained [0].

Add an option to build systemd-boot as part of the systemd build.

Install the boot files, that can serve as a template for the user
to tweak for their system.

[0] https://cgit.freedesktop.org/gummiboot/commit/?id=55df1539c9d330732e88bd196afee386db6e4a1d

Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
[yann.morin.1998@free.fr:
  - add missing depends on i386 || x86_64
  - add missing dependency to gnu-efi
  - add missing boot files
]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-03-17 13:46:55 +01:00
Adam Duskett 8085b9eaa4 package/systemd: fix patch series order
With the removal of old patches, 0018 should be 0002 and 0019 should be 0003.

Signed-off-by: Adam Duskett <Aduskett@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-03-14 22:38:12 +01:00
Adam Duskett 6da59bc29e package/systemd: fix patch 0019
This patch was backported to work with systemd v240. Now that systemd
is at v241, we must update the patch.

Signed-off-by: Adam Duskett <Aduskett@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-03-14 22:31:54 +01:00
Yann E. MORIN af839d25cb package/systemd: use util-linux' agetty, drop patch
We currently have a patch that replaces the use of (hard-coded) agetty
in systemd, to use just plain getty. That patch dates back to commit
f4a5eed474 (Add the systemd package), when util-linux was not a
dependency, and we relied on busybox to actually provide getty.

But nowadays, util-linux is a mandatory dependency of systemd anyway.
agetty is about 42KiB, while busybox' getty is around 5KiB (give or
take). That's an extra ~40KiB, but it has to be balanced against the
rest of the system: systemd only runs on a glibc system, needs dbus and
thus expat, and kmod, that a ~40KiB overhead is barely noticeable (a
miminal systemd setup with nothing enabled, on ARM, is already ~20MiB)

So, drop our agetty-dropping patch, and forcibly enable agetty in
util-linux.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Adam Duskett <aduskett@gmail.com>
Cc: Maxime Hadjinlian <maxime.hadjinlian@gmail.com>
Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-03-14 22:14:51 +01:00
Adam Duskett fbe8d0b24a package/systemd: bump version to 241
In addition:
  - Remove patches that have been committed upstream.
  - Update hash for the README file. (Meson and Dbus dependency version updates)

./support/testing/run-tests -d dl -o output -k tests.init.test_systemd
14:18:20 TestInitSystemSystemdRwNetworkd          Starting
14:18:21 TestInitSystemSystemdRwNetworkd          Building
14:26:20 TestInitSystemSystemdRwNetworkd          Building done
14:27:01 TestInitSystemSystemdRwNetworkd          Cleaning up
.14:27:01 TestInitSystemSystemdRwIfupdown         Starting
14:27:01 TestInitSystemSystemdRwIfupdown          Building
14:28:35 TestInitSystemSystemdRwIfupdown          Building done
14:29:03 TestInitSystemSystemdRwIfupdown          Cleaning up
.14:29:03 TestInitSystemSystemdRwFull             Starting
14:29:04 TestInitSystemSystemdRwFull              Building
14:44:35 TestInitSystemSystemdRwFull              Building done
14:45:18 TestInitSystemSystemdRwFull              Cleaning up
.14:45:18 TestInitSystemSystemdRoNetworkd         Starting
14:45:19 TestInitSystemSystemdRoNetworkd          Building
14:55:59 TestInitSystemSystemdRoNetworkd          Building done
14:56:23 TestInitSystemSystemdRoNetworkd          Cleaning up
.14:56:23 TestInitSystemSystemdRoIfupdown         Starting
14:56:24 TestInitSystemSystemdRoIfupdown          Building
15:06:42 TestInitSystemSystemdRoIfupdown          Building done
15:07:09 TestInitSystemSystemdRoIfupdown          Cleaning up
.15:07:09 TestInitSystemSystemdRoFull             Starting
15:07:10 TestInitSystemSystemdRoFull              Building
15:21:17 TestInitSystemSystemdRoFull              Building done
15:21:46 TestInitSystemSystemdRoFull              Cleaning up
.
----------------------------------------------------------------------
Ran 6 tests in 3806.472s

OK

Signed-off-by: Adam Duskett <Aduskett@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-03-14 22:04:42 +01:00
Xavier Ruppen 940e7deab0 package/systemd: fix "Timed out waiting for device /dev/console."
Buildroot built with systemd fails to open a login prompt on the
serial port when /dev/console is specified as BR2_TARGET_GENERIC_GETTY_PORT
(which is its default value):

systemd[1]: dev-console.device: Job dev-console.device/start timed out.
systemd[1]: Timed out waiting for device /dev/console.
systemd[1]: Dependency failed for Serial Getty on console.
systemd[1]: serial-getty@console.service: Job serial-getty@console.service/start failed with result 'dependency'.
systemd[1]: dev-console.device: Job dev-console.device/start failed with result 'timeout'.
systemd[1]: Reached target Login Prompts.
systemd[1]: Reached target Multi-User System.

According to this issue on Github [1], serial-getty@.service should
not be instantiated on /dev/console, console-getty@.service should
be used instead. This stems from the fact that there should be no
dependency on /dev/console.

[1] https://github.com/systemd/systemd/issues/10914

Signed-off-by: Xavier Ruppen <xruppen@gmail.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
[Peter: drop SERVICE variable as suggested by Yann]
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2019-03-04 22:33:02 +01:00
Baruch Siach c12b32ba46 package/systemd: add upstream security fixes
CVE-2019-6454: systemd (PID1) crash with specially crafted D-Bus message
from unprivileged user

Cc: Maxime Hadjinlian <maxime.hadjinlian@gmail.com>
Cc: Yann E. MORIN <yann.morin.1998@free.fr>
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2019-02-26 19:41:17 +01:00
Fabrice Fontaine ff50cc8b05 package/systemd: fix build with older kernels
These 4 patches have been sent upstream and merged in version 241:
https://github.com/systemd/systemd/pull/11641

Fixes:
 - http://autobuild.buildroot.org/results/970b09e1d49b53dff12a07ca4ad424ef9dd29a69
 - http://autobuild.buildroot.org/results/0a671b08d5e74ff0b04024e729c498c4444e3e92

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-02-24 21:14:06 +01:00
Gervais, Francois 77c057939d systemd: Remove instance name usage in a non-template unit file
console-getty.service is not a template unit file (it doesn't have the
@ specifier), so %I doesn't get properly expanded in it. Thus, getty
startup will fail due to invalid options and no getty prompt is launched
on the console.

Fixes:
No getty prompt on boot

Signed-off-by: Francois Gervais <fgervais@distech-controls.com>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
2019-02-20 22:58:16 +01:00
Fabrice Fontaine 84dfe5d9b5 package/systemd: add optional bash-completion dependency
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-02-10 14:07:32 +01:00
Fabrice Fontaine b96a4d0909 package/systemd: add optional cryptsetup dependency
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-02-10 14:07:27 +01:00
Fabrice Fontaine e0f3138f81 package/systemd: add optional valgrind dependency
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-02-10 14:07:22 +01:00
David J. Fogle fc0787e76e package/systemd: set vconsole support option to default y
Without support for vconsole, systemd will abruptly kill anything
spawned on the console, thus preventing users from loging in from
the console, effectively locking them out if the target does not
have another mean of logging in (no sshd, no serial line...)

We fix that by making support for vconsole default to y, since
logging in from the console if more frequent than not. Users can
still de-activate it when they know they don't need it.

Note that logging from a serial line is not impacted, and still
works whether vconsole is enabled or not.

Signed-off-by: David Fogle <david.j.fogle@gmail.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-02-06 14:14:15 +01:00
Fabrice Fontaine 097089012a package/systemd: fix build on mips32
Fixes:
 - http://autobuild.buildroot.org/results/e484bc976266633029b26c8e21959ae4e9137da3

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Reviewed-by: Titouan Christophe <titouan.christophe@railnova.eu>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-02-04 14:54:51 +01:00
Fabrice Fontaine 9fe205c59b package/systemd: add optional iptables dependency
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-02-04 11:25:26 +01:00
James Hilliard f4d3d62b10 package/systemd: add upstream fix for CVE-2018-16865
Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2019-01-16 13:57:08 +01:00
James Hilliard 1d7031b31e package/systemd: add upstream fix for CVE-2018-16864
Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2019-01-16 13:56:45 +01:00
Fabrice Fontaine d62425599e package/systemd: fix build with older kernels
Fixes:
 - http://autobuild.buildroot.org/results/699c078aa078240c6741da4dbd0871450ceeca92

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-01-12 18:39:49 +01:00
James Hilliard 5ae9157af6 package/systemd: fix build on toolchain without C++
This is a backport from upstream.

Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2018-12-30 15:30:41 +01:00
Adam Duskett 0b213d5a38 package/systemd: bump to v240
In addition:

 - Remove unused option -Dkill-path.
  (See commit 9a85778412fa3e3f8d4561064131ba69f3259b28)

 - Change option -Dmyhostname to -Dnss-myhostname.

 - Remove patches from upstream.

 - Update hash of README file. The changes are unrelated to licensing.

Signed-off-by: Adam Duskett <Aduskett@gmail.com>
Tested-by: Jérémy Rosen <jeremy.rosen@smile.fr>
[Thomas: update the hash of the README file.]
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2018-12-26 21:53:13 +01:00
Fabrice Fontaine 76cf905c7b systemd: fix build with gcc <= 4.7
Pass -Werror=shadow in args of cc.compiles in meson.build otherwise test
will always succeed, causing -Werror=shadow to be passed, even on older gcc versions.

GCC 4.8 changed the behaviour of -Werror=shadow to no longer complain about
local variable declariations shadowing functions, which systemd has.  From
the changelog:

  The option -Wshadow no longer warns if a declaration shadows a function
  declaration, unless the former declares a function or pointer to function,
  because this is a common and valid case in real-world code.

https://www.gnu.org/software/gcc/gcc-4.8/changes.html

Fixes:
 - http://autobuild.buildroot.org/results/ffd71c473d3b29618c18cd2e04705370266696f2

[Peter: extend commit message, add gcc 4.8 link]
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2018-11-29 21:14:10 +01:00
Yann E. MORIN 0d61846b5f package/systemd: needs glibc
Since version v239, systemd-nspawn unconditioanlly uses prlimit(2),
which is not implemented in uClibc-ng. systemd-nspawn can not be
disabled.

This makes systemd glibc-only again.

After a bit of discussion with upstream (om IRC), it looks very
improbable that they accept a patch making systemd-nspawn optional.
They would probably consider a patch that provides that syscall wrapper
if it is missing, though, but that's less trivial...

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Waldemar Brodkorb <wbx@openadk.org>
Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Cc: Peter Korsgaard <peter@korsgaard.com>
Reviewed-by: Matt Weber <matthew.weber@rockwellcollins.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2018-11-22 17:15:33 +01:00
Alexander Sverdlin e9b70f96e8 package/systemd: explicitly configure split-usr=false and split-bin=true
meson-based build of systemd runs a couple of checks on the structure
of the *host* system which will incorrectly configure systemd if build
host configuration doesn't match Buildroot target.

One can also find the following in the NEWS file:

* A new -Dsplit-bin= build configuration switch may be used to specify
  whether bin and sbin directories are merged, or if they should be
  included separately in $PATH and various listings of executable
  directories. The build configuration scripts will try to autodetect
  the proper values of -Dsplit-usr= and -Dsplit-bin= based on build
  system, but distributions are encouraged to configure this
  explicitly.

Signed-off-by: Alexander Sverdlin <alexander.sverdlin@gmail.com>
Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2018-11-11 21:55:10 +01:00
Bernd Kuhls bc6ecbbeef package/systemd: Add upstream patch to fix CVE-2018-15688
Systemd-networkd is vulnerable to an out out-of-bounds heap write in the
DHCPv6 client when handling options sent by network adjacent DHCP servers.
A attacker could exploit this via malicious DHCP server to corrupt heap
memory on client machines, resulting in a denial of service or potential
code execution.

Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
[Peter: add description]
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2018-10-30 21:07:36 +01:00
Peter Korsgaard 721e4cbb52 Merge branch 'next'
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2018-09-07 13:13:17 +02:00