mirror of
https://github.com/vyos/vyos-build.git
synced 2025-10-01 20:28:40 +02:00
T6758: Add build package xen-guest-agent
The 'xen-guest-agent' could be used for XCP-NG images
This commit is contained in:
parent
2b9303d0bd
commit
1d69d490ca
@ -76,6 +76,8 @@ jobs:
|
||||
- 'scripts/package-build/waagent/**'
|
||||
wide-dhcpv6:
|
||||
- 'scripts/package-build/wide-dhcpv6/**'
|
||||
xen-guest-agent:
|
||||
- 'scripts/package-build/xen-guest-agent/**'
|
||||
|
||||
- name: Trigger builds for changed packages
|
||||
run: |
|
||||
@ -196,3 +198,7 @@ jobs:
|
||||
if [ "${{ steps.changes.outputs.wide-dhcpv6 }}" == "true" ]; then
|
||||
trigger_build "ethtool"
|
||||
fi
|
||||
|
||||
if [ "${{ steps.changes.outputs.xen-guest-agent }}" == "true" ]; then
|
||||
trigger_build "xen-guest-agent"
|
||||
fi
|
||||
|
||||
7
scripts/package-build/xen-guest-agent/.gitignore
vendored
Normal file
7
scripts/package-build/xen-guest-agent/.gitignore
vendored
Normal file
@ -0,0 +1,7 @@
|
||||
xen-guest-agent/
|
||||
*.buildinfo
|
||||
*.build
|
||||
*.changes
|
||||
*.deb
|
||||
*.dsc
|
||||
|
||||
1
scripts/package-build/xen-guest-agent/build.py
Symbolic link
1
scripts/package-build/xen-guest-agent/build.py
Symbolic link
@ -0,0 +1 @@
|
||||
../build.py
|
||||
34
scripts/package-build/xen-guest-agent/package.toml
Normal file
34
scripts/package-build/xen-guest-agent/package.toml
Normal file
@ -0,0 +1,34 @@
|
||||
[[packages]]
|
||||
name = "xen-guest-agent"
|
||||
commit_id = "0.4.0"
|
||||
scm_url = "https://gitlab.com/xen-project/xen-guest-agent"
|
||||
|
||||
|
||||
build_cmd = """
|
||||
# changelog
|
||||
cat <<EOF > debian/changelog
|
||||
xen-guest-agent (0.4.0) UNRELEASED; urgency=medium
|
||||
|
||||
* Upstream package
|
||||
|
||||
-- VyOS Maintainers <maintainers@vyos.io> Thu, 26 Sep 2024 12:35:47 +0000
|
||||
|
||||
EOF
|
||||
|
||||
# Apply the patch to modify the debian/rules file
|
||||
sed -i 's|../xen-guest-agent-$(UPSTREAM_VERSION)-linux-$(DEB_TARGET_GNU_CPU)|target/release/xen-guest-agent|' debian/rules
|
||||
|
||||
sudo apt-get -y install --no-install-recommends libclang-dev libxen-dev
|
||||
# Install rust
|
||||
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | bash -s -- -y --default-toolchain stable --profile default --no-modify-path
|
||||
|
||||
# Set PATH for Cargo
|
||||
export PATH="$HOME/.cargo/bin:$PATH"
|
||||
rustup update
|
||||
cd xen-guest-agent
|
||||
cargo update
|
||||
|
||||
# Build deb
|
||||
cargo build -F static --profile release
|
||||
dpkg-buildpackage -b -us -uc
|
||||
"""
|
||||
Loading…
x
Reference in New Issue
Block a user