-
Notifications
You must be signed in to change notification settings - Fork 40
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This is to ensure the software continues to build on (somewhat old) "Ubuntu Focal"-based distros. At the moment, package "libfsverity-dev" is not available on that distro, so make its installation optional. Signed-off-by: Rogerio Guerra Borin <[email protected]>
- Loading branch information
Showing
2 changed files
with
54 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,40 @@ | ||
#!/bin/bash | ||
set -xeuo pipefail | ||
export DEBIAN_FRONTEND=noninteractive | ||
apt-get install -y automake libtool autoconf autotools-dev git make gcc libssl-dev libfsverity-dev pkg-config libfuse3-dev python3 libcap2-bin | ||
|
||
PACKAGES=" \ | ||
automake \ | ||
libtool \ | ||
autoconf \ | ||
autotools-dev \ | ||
git \ | ||
make \ | ||
gcc \ | ||
libssl-dev \ | ||
libfsverity-dev \ | ||
pkg-config \ | ||
libfuse3-dev \ | ||
python3 \ | ||
libcap2-bin \ | ||
" | ||
|
||
# Split required and optional packages based on input variable ALLOW_MISSING: | ||
PACKAGES_REQUIRED="" | ||
PACKAGES_OPTIONAL="" | ||
|
||
for pkg in $PACKAGES; do | ||
if [[ " ${ALLOW_MISSING:-} " == *" ${pkg} "* ]]; then | ||
PACKAGES_OPTIONAL+=" ${pkg}" | ||
else | ||
PACKAGES_REQUIRED+=" ${pkg}" | ||
fi | ||
done | ||
|
||
# Install packages: | ||
if [ -n "${PACKAGES_REQUIRED}" ]; then | ||
apt-get install -y $PACKAGES_REQUIRED | ||
fi | ||
|
||
if [ -n "${PACKAGES_OPTIONAL}" ]; then | ||
apt-get install -y --ignore-missing $PACKAGES_OPTIONAL || true | ||
fi |