Allow to install default configuration into /usr/share/factory#17501
Allow to install default configuration into /usr/share/factory#17501Mic92 wants to merge 1 commit intosystemd:masterfrom
Conversation
c7a51c3 to
dd2fc25
Compare
With this meson option it allows distributions to install systemd in a stateless way as described in http://0pointer.net/blog/projects/stateless.html For backwards compatibility the build would still install all configuration files to /etc/systemd and /etc unless specified otherwise. We use this option in NixOS.
dd2fc25 to
92c4575
Compare
|
Not sure I grok this. These config files are redundant, we install them as commentary only, they generally contain not a single uncommented line. They exist only to help admins a bit when they want to edit them. On a stateless system you really shouldn't bother with them. Copying them in has no benefit really. They are NOPs |
We do something like |
|
hmm, what? Your build system doesn't use $DESTDIR? that's super strange. |
|
Let's say we don't need DESTDIR in the normal case if packages stick to directories given by configure flags. Our package manager computes a unique installation directory per package based on the build plan and all dependencies ( |
|
Not getting what that has to do with the configuration stuff and the factory dir though? |
My intention was that distributions that want to provide these templates in etc would use systemd-tmpfiles to populate |
It would be welcome. In particular, when developing on a "live" machine, installing any configuration files is problematic and I think many developers would find it useful to disable. |
|
Ok. I am going to make a new PR for this. |
This is useful for development where overwriting files out side the configured prefix will affect the host as well as stateless systems such as NixOS that don't let packages install to /etc but handle configuration on their own. Alternative to systemd#17501 tested with: $ mkdir inst build && cd build $ meson \ -Dcreate-log-dirs=false \ -Dsysvrcnd-path=$(realpath ../inst)/etc/rc.d \ -Dsysvinit-path=$(realpath ../inst)/etc/init.d \ -Drootprefix=$(realpath ../inst) \ -Dinstall-sysconfdir=false \ --prefix=$(realpath ../inst) .. $ ninja install
|
Follow up: #17580 |
This is useful for development where overwriting files out side the configured prefix will affect the host as well as stateless systems such as NixOS that don't let packages install to /etc but handle configuration on their own. Alternative to #17501 tested with: $ mkdir inst build && cd build $ meson \ -Dcreate-log-dirs=false \ -Dsysvrcnd-path=$(realpath ../inst)/etc/rc.d \ -Dsysvinit-path=$(realpath ../inst)/etc/init.d \ -Drootprefix=$(realpath ../inst) \ -Dinstall-sysconfdir=false \ --prefix=$(realpath ../inst) .. $ ninja install
This is useful for development where overwriting files out side the configured prefix will affect the host as well as stateless systems such as NixOS that don't let packages install to /etc but handle configuration on their own. Alternative to systemd/systemd#17501 tested with: $ mkdir inst build && cd build $ meson \ -Dcreate-log-dirs=false \ -Dsysvrcnd-path=$(realpath ../inst)/etc/rc.d \ -Dsysvinit-path=$(realpath ../inst)/etc/init.d \ -Drootprefix=$(realpath ../inst) \ -Dinstall-sysconfdir=false \ --prefix=$(realpath ../inst) .. $ ninja install (cherry picked from commit d7aa78c) [fbui: adjust context]
This is useful for development where overwriting files out side the configured prefix will affect the host as well as stateless systems such as NixOS that don't let packages install to /etc but handle configuration on their own. Alternative to systemd/systemd#17501 tested with: $ mkdir inst build && cd build $ meson \ -Dcreate-log-dirs=false \ -Dsysvrcnd-path=$(realpath ../inst)/etc/rc.d \ -Dsysvinit-path=$(realpath ../inst)/etc/init.d \ -Drootprefix=$(realpath ../inst) \ -Dinstall-sysconfdir=false \ --prefix=$(realpath ../inst) .. $ ninja install
With this meson option it allows distributions to install systemd in a
stateless way as described in http://0pointer.net/blog/projects/stateless.html
For backwards compatibility the build would still install all
configuration files to /etc/systemd and /etc unless specified otherwise.
We use this option in NixOS.