diff options
author | Yaakov Selkowitz <yselkowi@redhat.com> | 2022-01-09 16:19:48 -0500 |
---|---|---|
committer | Yaakov Selkowitz <yselkowi@redhat.com> | 2022-01-09 20:32:44 -0500 |
commit | bd9b4b5a2c4176ef4e116a5973095eb493a779c1 (patch) | |
tree | de0317f3b542b92ca570665b6ea272e47365d394 /cygwin.prov | |
parent | e3e59650141c5f8b5b825fa30b06459eac9e4401 (diff) | |
download | cygwin-filesystem-bd9b4b5a2c4176ef4e116a5973095eb493a779c1.tar.gz cygwin-filesystem-bd9b4b5a2c4176ef4e116a5973095eb493a779c1.tar.xz cygwin-filesystem-bd9b4b5a2c4176ef4e116a5973095eb493a779c1.zip |
Sync with mingw-filesystem 128
Diffstat (limited to 'cygwin.prov')
-rwxr-xr-x | cygwin.prov | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/cygwin.prov b/cygwin.prov new file mode 100755 index 0000000..006047c --- /dev/null +++ b/cygwin.prov @@ -0,0 +1,24 @@ +#!/bin/bash + +# This script reads filenames from STDIN and outputs any relevant provides +# information that needs to be included in the package. + +targets=$@ +if [ -z "$targets" ] ; then + echo "Usage: $0 [ cygwin32 ] [ cygwin64 ]" + exit 1 +fi + +filelist=`sed "s/['\"]/\\\&/g"` + +dlls=$(echo $filelist | tr '[:blank:]' '\n' | grep '\.dll$') + +for f in $dlls; do + basename=`basename $f | tr '[:upper:]' '[:lower:]'` + for target in $targets; do + host_triplet=`rpm --eval "%{${target}_target}"` + [[ $f =~ .*$host_triplet.* ]] && echo "$target($basename)" + done +done + +exit 0 |