From 577be1c75fdcbe12339f82c3d25b64e475ccec6f Mon Sep 17 00:00:00 2001 From: "dylan.araps@gmail.com" Date: Sun, 12 Jan 2020 17:55:11 +0000 Subject: kiss: pkg_find() only gen glob onc. FossilOrigin-Name: 095e9f3d769f160196cae975cc111d101228330726a8f7df134cc96340dee910 --- kiss | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/kiss b/kiss index 66ae289..28fdb11 100755 --- 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. -- cgit v1.2.3