1
0
mirror of https://codeberg.org/kiss-community/kiss synced 2024-12-25 00:20:05 -07:00

kiss: Use fakeroot to build and tar packages.

This commit is contained in:
Dylan Araps 2019-07-16 10:12:48 +03:00
parent 875d2fd903
commit 4244f37081

12
kiss
View File

@ -337,9 +337,11 @@ pkg_tar() {
# Read the version information to name the package. # Read the version information to name the package.
read -r version release < "$repo_dir/version" read -r version release < "$repo_dir/version"
# Create a tar-ball from the contents of the built package. # Create a tar-ball from the contents of the built package. `fakeroot`
tar zpcf "$bin_dir/$1#$version-$release.tar.gz" -C "$pkg_dir/$1" . || # is used here to correct issues with file ownership.
die "[$1]: Failed to create tar-ball." fakeroot \
tar zpcf "$bin_dir/$1#$version-$release.tar.gz" -C "$pkg_dir/$1" . ||
die "[$1]: Failed to create tar-ball."
log "[$1]: Successfully created tar-ball." log "[$1]: Successfully created tar-ball."
} }
@ -487,7 +489,7 @@ pkg_build() {
mkdir -p "$pkg_dir/$pkg/var/db/kiss" mkdir -p "$pkg_dir/$pkg/var/db/kiss"
# Move to the build directory and call the build script. # Move to the build directory and call the build script.
(cd "$mak_dir/$pkg"; "$repo_dir/build" "$pkg_dir/$pkg") || (cd "$mak_dir/$pkg"; fakeroot "$repo_dir/build" "$pkg_dir/$pkg") ||
die "[$pkg]: Build failed." die "[$pkg]: Build failed."
# Copy the repository files to the package directory. # Copy the repository files to the package directory.
@ -950,7 +952,7 @@ args() {
# Print version and exit. # Print version and exit.
v*) v*)
log "$kiss 0.3.1" log "$kiss 0.3.2"
;; ;;
# Catch all invalid arguments as well as # Catch all invalid arguments as well as