File zeromq.spec of Package zeromq
#
# spec file for package zeromq
#
# Copyright (c) 2016 SUSE LINUX 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/
#
Name:           zeromq
Version:        4.0.5
Release:        1%{?dist}
Summary:        Software library for fast, message-based applications
License:        LGPL-3.0+
Group:          System Environment/Libraries
Url:            http://www.zeromq.org
Source0:        http://download.zeromq.org/zeromq-%{version}.tar.gz
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildRequires:  gcc-c++
BuildRequires:  glib2-devel
BuildRequires:  python-devel
%if ! (0%{?rhel} > 5)
BuildRequires:  e2fsprogs-devel
%else
BuildRequires:  libuuid-devel
%endif
# utils subpackage was removed in F-16
# -> can be deleted in F-19
Obsoletes:      zeromq-utils < 2.1.3-1
# Removes ZMQ3 library if built using the SRPM on the ZeroMQ website
Obsoletes:      libzmq3
# Upgrade from zeromq3 package in EL6
Obsoletes:      zeromq3
%description
The 0MQ lightweight messaging kernel is a library which extends the
standard socket interfaces with features traditionally provided by
specialized messaging middle-ware products. 0MQ sockets provide an
abstraction of asynchronous message queues, multiple messaging
patterns, message filtering (subscriptions), seamless access to
multiple transport protocols and more.
This package contains the ZeroMQ shared library.
%package devel
Summary:        Development files for %{name}
Group:          Development/Libraries
Requires:       %{name}%{?_isa} = %{version}-%{release}
%description devel
The %{name}-devel package contains libraries and header files for 
developing applications that use %{name}.
%prep
%setup -q
# Don't turn warnings into errors
sed -i "s/libzmq_werror=\"yes\"/libzmq_werror=\"no\"/g" \
    configure
%build
%configure \
  --with-pgm \
  --disable-static \
  --with-pic
make %{?_smp_mflags}
%install
rm -rf %{buildroot}
make install DESTDIR=%{buildroot} INSTALL="install -p"
# remove *.la
find %{buildroot} -name \*.la -print0 | xargs -r0 rm -v
%clean
%{__rm} -rf %{buildroot}
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files
%defattr(-,root,root,-)
%doc AUTHORS ChangeLog COPYING COPYING.LESSER NEWS
%{_bindir}/curve_keygen
%{_libdir}/libzmq.so.*
%files devel
%defattr(-,root,root,-)
%{_libdir}/libzmq.so
%{_libdir}/pkgconfig/libzmq.pc
%{_includedir}/zmq*
%{_mandir}/man3/zmq*
%{_mandir}/man7/zmq*
%changelog