1
0
mirror of https://github.com/systemd/systemd.git synced 2025-03-06 00:58:29 +03:00

Merge pull request #31985 from DaanDeMeyer/mkosi

mkosi: Copy built packages to output directory
This commit is contained in:
Yu Watanabe 2024-03-28 10:21:34 +09:00 committed by GitHub
commit 5e4aad5e96
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 16 additions and 5 deletions

View File

@ -74,7 +74,7 @@ jobs:
steps:
- uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633
- uses: systemd/mkosi@82108567f23cb29ecbea0a495833a18498eaafb9
- uses: systemd/mkosi@31af101620fc2996517d87e86da310f7ba553d58
# Freeing up disk space with rm -rf can take multiple minutes. Since we don't need the extra free space
# immediately, we remove the files in the background. However, we first move them to a different location

View File

@ -0,0 +1,4 @@
#!/bin/bash
set -e
rm -f "$OUTPUTDIR"/*.{rpm,deb,pkg.tar}

View File

@ -50,6 +50,8 @@ env --chdir="pkg/$PKG_SUBDIR" \
_systemd_UPSTREAM=1 \
_systemd_QUIET=1 \
BUILDDIR="$PWD/pkg/$PKG_SUBDIR" \
PKGDEST="$PACKAGEDIR" \
PKGDEST="$OUTPUTDIR" \
PKGEXT=".pkg.tar" \
MESON_EXTRA_CONFIGURE_OPTIONS="-D mode=developer -D b_sanitize=${SANITIZERS:-none}"
cp "$OUTPUTDIR"/*.pkg.tar "$PACKAGEDIR"

View File

@ -24,7 +24,7 @@ rpmbuild \
$( ((WITH_DOCS)) || echo "--without docs") \
--define "_topdir /var/tmp" \
--define "_sourcedir pkg/$PKG_SUBDIR" \
--define "_rpmdir $PACKAGEDIR" \
--define "_rpmdir $OUTPUTDIR" \
${BUILDDIR:+--define} \
${BUILDDIR:+"_vpath_builddir $BUILDDIR"} \
--define "_build_name_fmt %%{NAME}-%%{VERSION}-%%{RELEASE}.%%{ARCH}.rpm" \
@ -46,3 +46,5 @@ rpmbuild \
--define "__script_requires %{nil}" \
--undefine _lto_cflags \
"pkg/$PKG_SUBDIR/systemd.spec"
cp "$OUTPUTDIR"/*.rpm "$PACKAGEDIR"

View File

@ -86,4 +86,5 @@ if ! build; then
build
fi
mv ../*.deb "$PACKAGEDIR"
cp ../*.deb "$PACKAGEDIR"
cp ../*.deb "$OUTPUTDIR"

View File

@ -29,7 +29,7 @@ build() {
$( ((WITH_TESTS)) || echo --nocheck) \
--define "_topdir /var/tmp" \
--define "_sourcedir pkg/$PKG_SUBDIR" \
--define "_rpmdir $PACKAGEDIR" \
--define "_rpmdir $OUTPUTDIR" \
${BUILDDIR:+--define} \
${BUILDDIR:+"_vpath_builddir $BUILDDIR"} \
--define "_build_name_fmt %%{NAME}-%%{VERSION}-%%{RELEASE}.%%{ARCH}.rpm" \
@ -61,3 +61,5 @@ if ! build; then
cat /tmp/unpackaged-files >>"pkg/$PKG_SUBDIR/files.systemd"
build --noprep --nocheck
fi
cp "$OUTPUTDIR"/*.rpm "$PACKAGEDIR"