File mingw32-liquid-dsp.spec of Package mingw32-liquid-dsp

#
# spec file for package mingw32-liquid-dsp
#
# Copyright (c) 2015, Martin Hauke <mardnh@gmx.de>
#
# 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 realname liquid-dsp
%define use_build_checks 0
%define soname  0
%define libname libliquid
Name:           mingw32-%{realname}
Version:        0.0.0.git1424212179.a4d7c80
Release:        0
Summary:        Digital signal processing library for software-defined radios
License:        GPL-3.0
Group:          System/Libraries
Url:            http://liquidsdr.org
Source:         %{realname}-%{version}.tar.xz
Patch0:         liquid-dsp-mingw-fix.diff
Patch1:         liquid-dsp-mingw-fix2.diff
Patch2:         liquid-dsp-fix-destdir.diff
BuildRequires:  autoconf
BuildRequires:  automake
#BuildRequires:  pkgconfig(fec3)
BuildRequires:  mingw32-cross-binutils
BuildRequires:  mingw32-cross-gcc
BuildRequires:  mingw32-cross-pkg-config
BuildRequires:  mingw32-filesystem
BuildRequires:  mingw32-fftw3-devel
BuildRequires:  mingw32-fec-devel
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
#BuildArch:      noarch
%{_mingw32_package_header_debug}

%description
liquid-dsp is an open-source signal processing library for software-defined
radios written in C. Its purpose is to provide a set of extensible DSP modules
that do no rely on external dependencies or cumbersome frameworks.

%package -n mingw32-%{libname}%{soname}
Summary:        Digital signal processing library for software-defined radios
Group:          System/Libraries

%description -n mingw32-%{libname}%{soname}
liquid-dsp is an open-source signal processing library for software-defined
radios written in C. Its purpose is to provide a set of extensible DSP modules
that do no rely on external dependencies or cumbersome frameworks.

%package -n mingw32-%{libname}-devel
Summary:        Development files for the liquid-dsp library
Group:          Development/Libraries/C and C++
Requires:       mingw32-%{libname}%{soname} = %{version}

%description -n mingw32-%{libname}-devel
liquid-dsp is an open-source signal processing library for software-defined
radios written in C. Its purpose is to provide a set of extensible DSP modules
that do no rely on external dependencies or cumbersome frameworks.

This subpackage contains libraries and header files for developing
applications that want to make use of libliquid.

%prep
%setup -q -n %{realname}-%{version}
%patch0 -p1
%patch1 -p1
%patch2 -p1
autoreconf -fiv

%build
export ac_cv_func_realloc_0_nonnull=yes
export ac_cv_func_malloc_0_nonnull=yes
%{_mingw32_configure}
make %{?_smp_mflags}

%install
make DESTDIR=%{buildroot} install

%check
%if 0%{?use_build_checks}
make %{?_smp_mflags} check
%endif

#%files -n libliquid%{soname}
#%defattr(-,root,root)
#%doc COPYING HISTORY README.md TROUBLESHOOTING

%files -n mingw32-%{libname}-devel
%defattr(-,root,root)
%doc COPYING HISTORY README.md TROUBLESHOOTING
%{_mingw32_includedir}/liquid/liquid.h
%dir %{_mingw32_includedir}/liquid
%{_mingw32_libdir}/libliquid.so
%{_mingw32_libdir}/libliquid.a


%changelog
openSUSE Build Service is sponsored by