Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

Being new to Fedora, I just installed a rpm using the following command

yum localinstall ./FoxitReader-1.1-0.fc9.i386.rpm 

Now this did the trick and I could launch the app using

FoxitReader &

Now my question is what if FoxitReader failed to launch the app and the name was something else. How could I find out what the name of launcher file could be that just got installed?

share|improve this question

4 Answers 4

up vote 13 down vote accepted

I usually list out the contents of the RPM and filter it using /bin/. The files in that directory are executable.

$ rpm -ql ImageMagick | grep /bin/
/usr/bin/animate
/usr/bin/compare
/usr/bin/composite
/usr/bin/conjure
/usr/bin/convert
/usr/bin/display
/usr/bin/identify
/usr/bin/import
/usr/bin/mogrify
/usr/bin/montage
/usr/bin/stream
share|improve this answer
    
I am getting package FoxitReader-1.1-0.fc9.i386.rpm is not installed Is that because I used yum localinstall to do the install ? –  Rajeshwar 19 hours ago
1  
rpm -ql FoxitReader | grep bin/ - don't use the full filename of the RPM. –  garethTheRed 19 hours ago
    
Thanks could you tell me why we did'nt use the full name of the rpm file ? –  Rajeshwar 19 hours ago
1  
Because different options to the rpm command have different semantics. Some expect the name of an installed package, others that of a physical file. –  tripleee 16 hours ago
    
You can use rpm -qlp FoxitReader-1.1-0.fc9.i386.rpm to list the files in an RPM, rpm -qlf /usr/share/misc/magic to find the other files from an installed package, rpm -qla for all installed files, etc. –  deltab 3 hours ago

The same for Debian; for an installed package,

dpkg -L <packagename> | grep -F /bin/

dpkg -L lists out the package's contents (basically prints /var/lib/dpkg/info/<packagename>.list) and the grep picks out any file paths containing /bin/.

For a deb file which you have not yet installed,

dpkg-deb -c path/to/filename.deb | grep -F /bin/
share|improve this answer
2  
dpkg -S searches packages containing that name. It just happens that packages usually contain a file matching its name. You really want dpkg -L –  Ángel 13 hours ago
    
My bad; thanks for the correction. –  tripleee 12 hours ago

As several others already have stated, look for "/bin" in the packages file list.

Here's Gentoo

$ equery f firefox | grep bin

equery is part of the package gentoolkit.

share|improve this answer

With:

rpm -qlp package.rpm

command you can list files inside a rpm file. Executables probably will be in some bin folder. So:

rpm -qlp package.rpm | grep bin 

can work too.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.