Commit graph

1030 commits

Author SHA1 Message Date
Zbigniew Jędrzejewski-Szmek 1a13e31d27 build-sys,man: use XML entities to substite strings
This makes it easier to add substitutions to man pages,
avoiding the separate transformation step.

mkdir -p's are removed from the rule, because xsltproc will
will create directories on it's own.

All in all, two or three forks per man page are avoided,
which should make things marginally faster.

Unfortunately python parsers must too be tweaked to handle
entities. This isn't particularly easy: with lxml a custom
Resolver can be used, but the stdlib etree doesn't support
external entities *at all*. So when running without lxml,
the entities are just removed. Right now it doesn't matter,
since the entities are not indexed anyway. But I intend to
add indexing of filenames in the near future, and then the
index generated without lxml might be missing a few lines.
Oh well.
2013-03-29 20:30:21 -04:00
Zbigniew Jędrzejewski-Szmek 4e7b3c20e0 build-sys: generate sed substitution from a list
I want to use the substitutions in different form for
xml entities.
2013-03-29 20:30:21 -04:00
Zbigniew Jędrzejewski-Szmek aa0bb9c2c4 Revert "build-sys: substitute strings in systemd.unit(5)"
This reverts commits c78ab91132
and 185c3be03c.

It is simpler to just use includes...
2013-03-29 20:30:21 -04:00
Zbigniew Jędrzejewski-Szmek 76877b46b6 tests: add some silly tests for path-util.c 2013-03-28 23:45:59 -04:00
Zbigniew Jędrzejewski-Szmek 844ec79b3c catalog: open up catalog internals
In order to write tests for the catalog functions, they
are made non-static and start taking a 'database' parameter,
which is the name of a file with the preprocessed catalog
entries.

This makes it possible to make test-catalog part of the
normal test suite, since it now only operates on files
in /tmp.

Some more tests are added.
2013-03-28 23:45:59 -04:00
Zbigniew Jędrzejewski-Szmek c8c9c69f39 build-sys: remove papersize option from sphinx
We don't use it currently for anything (no latex output),
but it was messing up stuff if /etc/papersize had comments.
2013-03-28 22:55:52 -04:00
Lennart Poettering 9ca3c17f20 build-sys: prepare release 200 2013-03-29 03:07:17 +01:00
Lennart Poettering 0c17fbce55 unit: replace remote-fs-setup.target by network-online.target
https://bugzilla.redhat.com/show_bug.cgi?id=787314
2013-03-29 03:07:17 +01:00
Auke Kok b0640287f7 readahead: cleanups
- check for OOM
- no need to use floats and round()
2013-03-26 11:35:27 -07:00
Auke Kok 94243ef299 readahead: chunk on spinning media
Readahead has all sorts of bad side effects depending on your
storage media. On rotating disks, it may be degrading startup
performance if enough requests are queued spanning linearly
over all blocks early at boot, and mount, blkid and friends
want to insert reads to the start of these block devices after.

The end result is that on spinning disks with ext3/4 that udev
and mounts take a very long time, and nothing really happens until
readahead is completely finished.

This has the net effect that the CPU is almost entirely idle
for the entire period that readahead is working. We could have
finished starting up quite a lot of services in this time if
we were smarter at how we do readahead.

This patch sorts all requests into 2 second "chunks" and sub-sorts
each chunk by block. This adds a single cross-drive seek per "chunk"
but has the benefit that we will have a lot of the blocks we need
early on in the boot sequence loaded into memory faster.

For a comparison of how before/after bootcharts look (ext4 on a
mobile 5400rpm 250GB drive) please look at:

    http://foo-projects.org/~sofar/blocked-tests/

There are bootcharts in the "before" and "after" folders where you
should be able to see that many low-level services finish 5-7
seconds earlier with the patch applied (after).
2013-03-26 10:32:32 -07:00
Lennart Poettering 03e1151676 build-sys: bump version and .so revisions 2013-03-26 15:43:43 +01:00
Lennart Poettering 810bc2e3d5 build-sys: ship missing unit file 2013-03-26 02:49:11 +01:00
Kay Sievers 06f4289808 build-sys: create kernel/install.d directories 2013-03-26 01:00:14 +01:00
Lennart Poettering e06e62f4a1 man: properly document the system targets that are also available for the user instance 2013-03-25 22:33:08 +01:00
Lennart Poettering e3d84721dc units: introduce new timers.target and paths.target to hook timer/path units into for boot 2013-03-25 21:28:30 +01:00
Kay Sievers 5ec6b15b65 build-sys: add missing sed substitution for DEBUGTTY 2013-03-25 19:28:00 +01:00
Lennart Poettering a7e3212d89 bus: split socket related code into bus-socket.[ch], to prepare for kdbus backend 2013-03-25 03:43:19 +01:00
Kay Sievers 1d09582ab9 hwdb: ID_PRODUCT_FROM_DATABASE --> ID_MODEL_FROM_DATABASE
With the conversion from pci-db + usb-db to hwdb, the property
got accitentially renamed.

Move the name back to the long established identifier *MODEL*
instead of *PRODUCT*.

  $ git grep -l ID_MODEL_FROM_DATABASE
  hwdb/20-pci-vendor-model.hwdb
  hwdb/20-usb-vendor-model.hwdb
  hwdb/ids-update.pl
  man/systemd.device.xml
  rules/78-sound-card.rules
  src/core/device.c
  src/cryptsetup/cryptsetup.c
2013-03-23 16:38:21 +01:00
Zbigniew Jędrzejewski-Szmek 478c82693c build-sys: move acl searching code into libsystemd-acl
This loop over acls is a bit too much to keep inside
of another loop.
2013-03-22 15:31:45 -04:00
Lennart Poettering e3017af973 bus: implement full method call timeout logic 2013-03-21 22:53:29 +01:00
Kay Sievers f5944e0fd6 MAkefile.am: whitespace cleanup 2013-03-21 22:16:55 +01:00
Michael Biebl b588b3c456 build-sys: include missing header in dist tarball 2013-03-21 11:05:43 +01:00
Lennart Poettering 30bdd69525 shared: add simple priority queue implementation 2013-03-21 02:54:47 +01:00
Lennart Poettering 89ffcd2ad5 bus: hook up client with socket communication 2013-03-20 23:00:10 +01:00
Lennart Poettering de1c301ed1 bus: add basic implementation of a native bus client library 2013-03-20 23:00:09 +01:00
Tom Gundersen a3bd8447be udev: make firmware loading optional and disable by default
Distros that whish to support old kernels should set
  --with-firmware-dirs="/usr/lib/firmware/updates:/usr/lib/firmware"
to retain the old behaviour.
2013-03-18 15:19:51 +01:00
Zbigniew Jędrzejewski-Szmek b04c8c83e8 systemd-python: add systemd.daemon wrapping sd-daemon
Please see the documentation (e.g. pydoc3 systemd.daemon) for full
description. As usual, systemd._daemon wraps the raw interface, while
systemd.daemon provides the more pythonic API. sd_listen_fds,
sd_booted, sd_is_fifo, sd_is_socket, sd_is_socket_unix,
sd_is_socket_inet, sd_is_mq, and SD_LISTEN_FDS_START are currently
wrapped.
2013-03-15 22:55:24 -04:00
Kay Sievers 8f27a2212e sysctl: add 50-default.conf 2013-03-15 16:37:58 +01:00
Kay Sievers 94c525f076 sysctl: coredump.conf -> 50-coredump.conf 2013-03-15 15:59:21 +01:00
Harald Hoyer 9e5f0f9291 Make initrd.target the default target in the initrd
First, rename root-fs.target to initrd-root-fs.target to clarify its usage.

Mount units with "x-initrd-rootfs.mount" are now ordered before
initrd-root-fs.target. As we sometimes construct /sysroot mounts in
/etc/fstab in the initrd, we want these to be mounted before the
initrd-root-fs.target is active.

initrd.target can be the default target in the initrd.

                             (normal startup)
                                    :
                                    :
                                    v
                              basic.target
                                    |
             ______________________/|
            /                       |
            |                  sysroot.mount
            |                       |
            |                       v
            |             initrd-root-fs.target
            |                       |
            |                       v
            |            initrd-parse-etc.service
(custom initrd services)            |
            |                       v
            |            (sysroot-usr.mount and
            |             various mounts marked
            |               with fstab option
            |                x-initrd.mount)
            |                       |
            |                       v
            |                initrd-fs.target
            |                       |
            \______________________ |
                                   \|
                                    v
                               initrd.target
                                    |
                                    v
                          initrd-cleanup.service
                               isolates to
                         initrd-switch-root.target
                                    |
                                    v
             ______________________/|
            /                       |
            |        initrd-udevadm-cleanup-db.service
            |                       |
(custom initrd services)            |
            |                       |
            \______________________ |
                                   \|
                                    v
                        initrd-switch-root.target
                                    |
                                    v
                        initrd-switch-root.service
                                    |
                                    v
                               switch-root
2013-03-15 00:49:37 +01:00
Zbigniew Jędrzejewski-Szmek d29dd03302 build-sys: link libsystemd-login also against libsystemd-daemon-internal
https://bugs.freedesktop.org/show_bug.cgi?id=62085

/usr/lib/gcc/x86_64-pc-linux-gnu/4.6.3/../../../../lib64/libsystemd-login.so:
undefined reference to `sd_listen_fds'

In ee465038ce 'build-sys: break dependency loop between
libsystemd-id128.la and -shared.la', a partial fix was applied, and
the use of functions from libsystemd-id128 was removed from
libsystemd-shared. Nevertheless, fdset.c was still using sd_listen_fds,
so libsystemd-login should be linked against libysystemd-daemon
or libsystemd-daemon-internal.

Tested-by: Elias Probst <mail@eliasprobst.eu>
2013-03-13 22:20:51 -04:00
Zbigniew Jędrzejewski-Szmek 4afb5c73a2 build-sys: add two new files to EXTRA_DIST
Also move custom-*.xsl EXTRA_DIST additions closer to where
they are used.
2013-03-13 13:24:14 -04:00
Hannes Reinecke 946f182575 libudev: implement udev_device_set_attribute_value() 2013-03-13 17:44:45 +01:00
Harald Hoyer 700e07ffd5 add initrd-fs.target and root-fs.target
Instead of using local-fs*.target in the initrd, use root-fs.target for
sysroot.mount and initrd-fs.target for /sysroot/usr and friends.

Using local-fs.target would mean to carry over the activated
local-fs.target to the isolated initrd-switch-root.target and thus in
the real root. Having local-fs.target already active after
deserialization causes ordering problems with the real root services and
targets.

We better isolate to targets for initrd-switch-root.target, which are
only available in the initrd.
2013-03-13 08:11:17 +01:00
Zbigniew Jędrzejewski-Szmek 783162123d build-sys: use -f with ln -s
Parallel builds would sometimes try to recreate the link,
and fail since 'ln -s' would refuse to overwrite.
2013-03-13 00:55:45 -04:00
Zbigniew Jędrzejewski-Szmek 702f64b93c man,html: say 'systemd 198' in the header
This should help readers of the man or HTML pages know if the documentation
is out of date. An alternative to use a date generated from 'git log' was
considered, but since we try to keep user visible documentation up to date,
showing the project version should be enough.
2013-03-12 23:57:46 -04:00
Zbigniew Jędrzejewski-Szmek a0b8045be2 man: strip the comments in man page headers
They contained the date, which creates a problem with multiarch
packages, since the generated file would be different each time.
2013-03-12 23:57:46 -04:00
Zbigniew Jędrzejewski-Szmek ee465038ce build-sys: break dependency loop between libsystemd-id128.la and -shared.la
The loop was added in d848b9cbfa 'Move generic specifier functions to shared'.
2013-03-12 23:05:53 -04:00
Lennart Poettering 6d031c0b60 bootchart: various superficial cleanups
Let's update bootchar to share the coding style a bit more with the rest
of the package.

- Some tabs/spaces fixes

- add #pragma to header

- split up header so that we have a 1:1 relation between .c and .h files
  like everywhere else

- Prefix user command line arguments/configuration settings with "arg_".

- other coding style fixes
2013-03-11 22:47:58 +01:00
Lennart Poettering e75dcf5737 bootchart: rename log.c to store.c to aovid confusion with src/shared/log.c 2013-03-11 19:18:53 +01:00
Michael Biebl f432bb9144 Move udevadm to rootbindir
The udevadm utility is needed during early boot, so move it to
rootbindir to support split-/usr configurations.
2013-03-11 07:18:33 +01:00
Zbigniew Jędrzejewski-Szmek 082cca735b python/docs: use the same links on top as in man pages
I forgot to commit the layout file, because it was gitignored.
Fixed now.
2013-03-09 09:56:19 -05:00
Zbigniew Jędrzejewski-Szmek 9f06e912f6 systemd-python: provide version info to sphinx 2013-03-09 08:47:50 -05:00
Zbigniew Jędrzejewski-Szmek 87cfe600c7 build-sys: generate links for html alias pages 2013-03-09 08:47:50 -05:00
Zbigniew Jędrzejewski-Szmek 9b2810721d build-sys: assemble HTML in docs/html
The goal is to be able to preview how the documenation
will look when uploaded. Just point your browser at
   docs/html/man/index.html.
2013-03-09 08:47:50 -05:00
Zbigniew Jędrzejewski-Szmek 86b4547712 build-sys: clean up make clean 2013-03-09 08:47:50 -05:00
Zbigniew Jędrzejewski-Szmek f6354e8c11 build-sys: fix distcheck 2013-03-09 08:47:50 -05:00
Michael Biebl 7b40ce553f build-sys: don't hard-code binary paths in initrd-*.service
Instead use @bindir@ for udevadm and @rootbindir@ for systemctl.
2013-03-09 10:05:01 +01:00
Lennart Poettering 01ec23582d build-sys: bump release and sonames 2013-03-07 21:53:53 +01:00
Zbigniew Jędrzejewski-Szmek e91fb201c7 build-sys: move sphinx output to docs/python-systemd
And on fd.o it goes into a dir parallel to man/.
2013-03-07 15:35:49 -05:00