'cygcheck -f' pattern syntax.

Oleksandr Gavenko gavenko@bifit.com.ua
Thu Sep 22 14:58:00 GMT 2011

   $ time cygcheck -f 'stdio.h'
real	0m1.016s
user	0m0.031s
sys	0m0.015s
   $ time cygcheck -f '*stdio.h'
   $ time cygcheck -f '*stdio.h'
   $ time cygcheck -f '*stdio.h'
   $ time cygcheck -f  /usr/include/stdio.h

real	0m0.907s
user	0m0.015s
sys	0m0.031s

So 'cygcheck -f' does not allow 'glob' and 'regex'.

I write simple script that allow use regex:


   regex=$(echo "$1" | sed -e 's|\\|&&|g' -e 's|=|\\=|g')

   for file in /etc/setup/*.lst.gz; do
     gzip -d -c $file | sed -n "\=$regex={s=^=$name: /=;p;}"

But this script is extremely slow:

   $ time ./cygsearch.sh 'bin/emacs'
emacs: /usr/bin/emacs-nox.exe
emacs: /usr/bin/emacs.ico
emacs: /usr/bin/emacsclient.exe
emacs-X11: /usr/bin/emacs-X11.exe

real	0m38.797s
user	0m44.620s
sys	0m25.574s

Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

More information about the Cygwin mailing list