Querying for package summaries

Querying for the summary of a package is useful when you do not know which product the package belongs to. For instance, it might be useful if you moved or copied packages from the COBOL for Linux® on x86 DVD or E-Image layout. The package summary includes a short description of the queried file.

On RHEL or SLES

To query for the summary of an RPM package that is not installed, issue the following command:
rpm --qf="%{summary}\n" -qp rpm_file_name
For instance, to query for the summary of the cobol.cmp.1.2.0-1.2.0.0-$B.x86-64.rpm RPM file that has not yet been installed, issue the following command:
rpm --qf="%{summary}\n" -qp cobol.cmp.1.2.0-1.2.0.0-$B.x86-64.rpm
The resulting output depends on the specific file queried. A typical example is shown below:
COBOL for Linux on x86 1.2 (5737-L11) -compiler package (RHEL)

On Ubuntu

To query for the summary of a dpkg package that is not installed, issue this command:
dpkg -f pkg_file_name
where pkg_file_name is the full file name of the dpkg package that you want to query for a summary.
For instance, to query for the summary of the cobol.cmp.1.2.0_1.2.0.0-$B_x86-64.deb file that has not yet been installed, issue the following command:
dpkg -f cobol.cmp.1.2.0-1.2.0.0-$B_x86_64.deb

The resulting output depends on the specific file queried. A typical example is shown below:

Package: cobol.cmp.1.2.0
Version: 1.2.0.0-$B
Section: devel
Priority: extra
Architecture: x86-64
Maintainer: For issues in COBOL for Linux on x86 compilers, open a Case (https://www.ibm.com/mysupport/s). 
For issues in COBOL for Linux on x86 evaluation version, visit the COBOL for Linux on x86 compiler community 
(https://www.ibm.com/community/z/languages/cobol/).
Depends: gcc (>= 8.5.0), libv6 (>= 2.28), 
libgcc1 (>= 8.5.0), libstdc++6 (>= 8.5.0)
Provides: cobol
Description:  COBOL for Linux on x86 1.2 (5737-L11) - compiler
Licensed Materials - Property of IBM.
COBOL for Linux on x86 1.2 (5737-L11)
Copyright IBM Corp. 2021.
IBM is a registered trademark of IBM Corp. in the U.S.,
other countries or both.
US Government Users Restricted Rights -
Use, duplication or disclosure restricted by
GSA ADP Schedule Contract with IBM Corp.
Note: $B is the build number of the package that is installed on your system.