#16 cygcheck equivalent

1.0
closed
Alexx83
None
2014-08-21
2014-02-02
No

Cygwin has the tool "cygcheck -p", which will find packages that contain a certain file, example

$ cygcheck -p usr/bin/grep.exe
Found 2 matches for usr/bin/grep.exe
x86_64/grep/grep-2.15-1
x86_64/grep/grep-2.16-1

It looks like the equivalent for MSYS would be "pkgfile", but I did not find that package

$ pacman -S pkgfile
error: target not found: pkgfile

Discussion

  • Ray Donnelly

    Ray Donnelly - 2014-02-02

    AFAIUI, pkgfile is a global query for packages both installed and not installed. We should probably add it, but if all you need is to know which package an installed file came from you can use:

    $ pacman -Qo /usr/bin/grep.exe
    /usr/bin/grep.exe is owned by grep 2.16-1

    Reference: https://wiki.archlinux.org/index.php/pacman

     
  • Steven Penny

    Steven Penny - 2014-02-02

    @Ray thanks for the reply. I need it to work with not installed files as well, which cygcheck and pkgfile both do.

     
  • Alexx83

    Alexx83 - 2014-02-03
    • assigned_to: Alexx83
     
  • Alexx83

    Alexx83 - 2014-02-03

    Now you can install pkgfile from repo.

     
  • Alexx83

    Alexx83 - 2014-02-03
    • status: open --> closed
     
  • Steven Penny

    Steven Penny - 2014-02-03

    @Alexx83 thanks! This worked!

    $ pacman -S -y
    
    $ pacman -S pkgfile
    
    $ pkgfile grep.exe
    msys/grep
    
     
  • Steven Penny

    Steven Penny - 2014-02-07

    It seems pkgfile is now broken on new update 20140205. It appears to hang forever, I Ctrl+C after one minute.

    $ time pkgfile --update
    :: Updating 3 repos...
    
    real    1m2.179s
    user    0m0.000s
    sys     0m0.046s
    
     
  • Alexx83

    Alexx83 - 2014-02-07

    You need wait more. Pkgfile has issue with downloading files from ftp. That's why it take so long. After failing download from ftp it download from sf.net.
    I don't know how to fix ftp downloading for pkgfile right now. Will add it in TODO list.

     
  • Steven Penny

    Steven Penny - 2014-02-07

    @Alexx83 no this problem was introduced with new version. 20131208 version works
    fine.

    $ pacman -S -y
    
    $ pacman -S pkgfile
    
    $ time pkgfile --update
    :: Updating 3 repos...
      download complete: msys               [   455.8 KiB   148K/s  2 remaining]
      download complete: mingw64            [   531.1 KiB   128K/s  1 remaining]
      download complete: mingw32            [   526.8 KiB  80.1K/s  0 remaining]
    :: download complete in 6.60s           <  1513.7 KiB   229K/s  3 files    >
    :: waiting for 1 process to finish repacking repos...
    
    real    0m6.786s
    user    0m0.418s
    sys     0m0.154s
    
     
  • Alexx83

    Alexx83 - 2014-02-07

    What do you mean on 20131208? What package is the issue?

     
  • Steven Penny

    Steven Penny - 2014-02-07

    msys2-base-x86_64-20131208.tar.xz
    works

    msys2-base-x86_64-20140205.tar.xz
    does not work

     
  • Alexx83

    Alexx83 - 2014-02-07

    Try rearrange in /etc/pacman.d/mirrorlist.{msys,mingw32,mingw64} files server records on non-working msys.
    Place sourceforge.net at first place. Then run pkgfile again

     
  • Steven Penny

    Steven Penny - 2014-02-07

    @Alexx83 yes that fixes it

    $ uname -a
    MSYS_NT-6.1 Steven-PC 2.0.0(0.271/5/3) 2014-02-05 11:55 x86_64 Msys
    
    $ pkgfile --update
    :: Updating 3 repos...
      download complete: msys               [   455.8 KiB  97.2K/s  2 remaining]
      download complete: mingw64            [   531.1 KiB   110K/s  1 remaining]
      download complete: mingw32            [   526.8 KiB  68.7K/s  0 remaining]
    :: download complete in 7.68s           <  1513.7 KiB   197K/s  3 files    >
    :: waiting for 1 process to finish repacking repos...
    
     
  • Alexx83

    Alexx83 - 2014-02-07

    Seems pkgfile doesn't properly work with ftp mirrors

     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks