1
0
mirror of https://github.com/systemd/systemd.git synced 2025-01-25 10:04:04 +03:00
Zbigniew Jędrzejewski-Szmek 725e646854 meson: generate proper version tag when git fails on permission errors
When building with mkosi I would get the following:

    [1/477] Generating version.h with a custom command
    fatal: detected dubious ownership in repository at '/work/src'
    To add an exception for this directory, call:

            git config --global --add safe.directory /work/src

and then the tag would be generated as 'v254-'. This is obviously some problem
with the setup, but we should handle this gracefully. Let's fall back to 'v254'
instead.

In the case where we have a repo but no tags, use --dirty=^ too, as in the case
with tags.

I tested four cases:
- normal checkout
- checkout with .git removed
- checkout with .git chowned to root
- checkout wiht all tags removed
2023-10-19 17:52:44 +02:00
..
2023-08-16 13:01:07 +02:00
2023-03-10 11:41:08 +01:00
2023-08-10 18:13:29 +02:00
2023-09-29 17:05:11 +02:00
2023-08-23 14:57:49 +02:00
2023-08-10 18:13:29 +02:00