cpt

[ARCHIVED] Carbs Packaging Tools
git clone git://git.ckyln.com/~cem/cpt.git
Log | Files | Refs | README | LICENSE

commit 0eddd6f61281bb5aecc8ca39ad16fdff8f6bc563
parent 527dd10adc0dfbcf262118462532fa9b95e22829
Author: Dylan Araps <dylan.araps@gmail.com>
Date:   Sun, 12 Jan 2020 19:55:12 +0200

kiss: pkg_find() only gen glob onc.

Diffstat:
Mkiss | 14++++++++++----
1 file changed, 10 insertions(+), 4 deletions(-)

diff --git a/kiss b/kiss @@ -262,10 +262,17 @@ pkg_fixdeps() { # reference to 'diff' against. [ -f depends ] && cp -f depends depends-copy + # Generate a list of all installed manifests. + pkg_name=$1 + set +f + set -f -- "$sys_db/"*/manifest + # Get a list of binaries and libraries, false files # will be found, however it's faster to get 'ldd' to check # them anyway than to filter them out. - find "$pkg_dir/$1" -type f 2>/dev/null | while read -r file; do + find "$pkg_dir/$pkg_name" -type f 2>/dev/null | + + while read -r file; do # Run 'ldd' on the file and parse each line. The code # then checks to see which packages own the linked # libraries and it prints the result. @@ -278,7 +285,7 @@ pkg_fixdeps() { dep=${dep% *} # Figure out which package owns the file. - dep=$(set +f; grep -lFx "${dep##$KISS_ROOT}" "$sys_db/"*/manifest) + dep=$(grep -lFx "${dep##$KISS_ROOT}" "$@") # Extract package name from 'grep' match. dep=${dep%/*} @@ -492,8 +499,7 @@ pkg_build() { log "$pkg" "Starting build" # Call the build script. - "$repo_dir/build" "$pkg_dir/$pkg" >>"${KISS_BFD:=/dev/fd/0}" 2>&1 || - die "$pkg" "Build failed" + "$repo_dir/build" "$pkg_dir/$pkg" || die "$pkg" "Build failed" # Copy the repository files to the package directory. # This acts as the database entry.