File netcdf-cxx4.spec of Package netcdf-cxx4

#
# spec file for package netcdf-cxx4
#
# Copyright (c) 2016 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#


%define sover 1

Name:           netcdf-cxx4
Version:        4.3.0
Release:        0
Summary:        C++ library for the Unidata network Common Data Form version 4
License:        NetCDF
Group:          Productivity/Scientific/Other
Url:            http://www.unidata.ucar.edu/software/netcdf/
Source0:        http://www.unidata.ucar.edu/downloads/netcdf/ftp/netcdf-cxx4-%{version}.tar.gz
BuildRequires:  gcc-c++
BuildRequires:  pkgconfig(netcdf)
BuildRequires:  pkg-config

%description
NetCDF4 (network Common Data Form) is a set of software libraries and
machine-independent data formats that support the creation, access, and sharing
of array-oriented scientific data.

This package provides the C++ API.

%package tools
Summary:        Tools for working with the netcdf4 C++ library
Group:          Productivity/Scientific/Other
BuildArch:      noarch

%description tools
NetCDF4 (network Common Data Form) is a set of software libraries and
machine-independent data formats that support the creation, access, and sharing
of array-oriented scientific data.

This package provides tools for working with the C++ API.


%package -n libnetcdf_c++4-%{sover}
Summary:        C++ library for the Unidata network Common Data Form version 4
Group:          System/Libraries
Provides:       libnetcdf%{sover}:%{_libdir}/libnetcdf_c++.so.%{sover}

%description -n libnetcdf_c++4-%{sover}
NetCDF4 (network Common Data Form) is a set of software libraries and
machine-independent data formats that support the creation, access, and sharing
of array-oriented scientific data.

This package provides the C++ API.

%package -n libnetcdf_c++4-devel
Summary:        Development files for netcdf_c++
Group:          Development/Libraries/C and C++
Requires:       libnetcdf_c++4-%{sover} = %{version}
Provides:       libnetcdf-devel:%{_libdir}/libnetcdf_c++.so

%description -n libnetcdf_c++4-devel
This package contains the netcdf_c++4 header files and shared devel libs.

%prep
%setup -q -n netcdf-cxx4-%{version}

%build
%configure --disable-static
make %{?_smp_mflags}

%install
%make_install
rm %{buildroot}%{_libdir}/libnetcdf_c++4.la

%check
make check

%post -n libnetcdf_c++4-%{sover} -p /sbin/ldconfig

%postun -n libnetcdf_c++4-%{sover} -p /sbin/ldconfig

%files tools
%defattr(-,root,root)
%doc COPYRIGHT
%{_bindir}/ncxx4-config

%files -n libnetcdf_c++4-%{sover}
%defattr(-,root,root)
%doc COPYRIGHT
%{_libdir}/libnetcdf_c++4.so.%{sover}
%{_libdir}/libnetcdf_c++4.so.%{sover}.*

%files -n libnetcdf_c++4-devel
%defattr(-,root,root)
%doc COPYRIGHT
%{_includedir}/*
%{_libdir}/pkgconfig/netcdf-cxx4.pc
%{_libdir}/libnetcdf_c++4.so


%changelog
openSUSE Build Service is sponsored by