Where is netcdf.h?
Colin Law
clanlaw at googlemail.com
Fri Nov 11 17:35:46 UTC 2011
On 11 November 2011 16:46, Peng Yu <pengyu.ut at gmail.com> wrote:
> On Fri, Nov 11, 2011 at 9:27 AM, Nils Kassube <kassube at gmx.net> wrote:
>> Peng Yu wrote:
>>> I use apt-cache search to look for netcdf.h. But I find nothing. Is
>>> there a package that has this file?
>>
>> Use apt-file instead:
>>
>> ~/ > apt-file search netcdf.h
>> libgdal-doc: /usr/share/doc/libgdal-doc/gdal/frmt_netcdf.html
>> libhdf4-alt-dev: /usr/include/hdf/hdf2netcdf.h
>> libhdf4-alt-dev: /usr/include/hdf/hdf4_netcdf.h
>> libhdf4-dev: /usr/include/hdf/hdf2netcdf.h
>> libhdf4-dev: /usr/include/hdf/netcdf.h
>> libnetcdf-dev: /usr/include/netcdf.h
>> libnetcdf-dev: /usr/include/netcdf.hh
>> libvtk5-dev: /usr/include/vtk-5.2/vtknetcdf/netcdf.h
>> netcdf-doc: /usr/share/doc/netcdf-doc/netcdf.html
>>
>> That was on a 10.04 machine - and it reveals the packages "libhdf4-dev",
>> "libnetcdf-dev" and "libvtk5-dev" but I have no idea which one is more
>> suitable for you.
>
> The following is from the man page of the two commands. What is APT
> cache, where the cache is? Does apt-file search for all the APT
> packages available on line for the given version of OS? Does it search
> for newer OS versions as well?
>
> apt-cache - query the APT cache
> apt-file - APT package searching utility -- command-line interface
I believe that apt-cache search only searches package names and
descriptions, it does not know about files within packages. It will
find packages that that are in the repositories defined in the sources
whether they have been downloaded or not. apt-file tells you which
packages a file is contained in.
Colin
More information about the ubuntu-users
mailing list