120 lines
2.9 KiB
RPMSpec
120 lines
2.9 KiB
RPMSpec
%ifarch %{ix86} x86_64 ppc ppc64 s390x %{arm}
|
|
%global with_valgrind 1
|
|
%endif
|
|
|
|
Name: libccd
|
|
Version: 1.4
|
|
Release: 3%{?dist}
|
|
Summary: Library for collision detection between convex shapes
|
|
|
|
License: BSD
|
|
URL: http://libccd.danfis.cz
|
|
Source0: http://libccd.danfis.cz/files/%{name}-%{version}.tar.gz
|
|
# This patch integrates all of the test programs that are present in
|
|
# the testsuites folder into CMake, via CTest. Not yet submitted
|
|
# upstream
|
|
Patch0: %{name}-1.3-ctest.patch
|
|
# This patch changes the ccd.pc file to point to the correct include
|
|
# directory. Not yet submitted upstream
|
|
Patch1: %{name}-1.3-fixpkgconfig.patch
|
|
|
|
%if 0%{?rhel}
|
|
BuildRequires: cmake28
|
|
%else
|
|
BuildRequires: cmake
|
|
%endif
|
|
# These are required for executing the test suite
|
|
BuildRequires: python
|
|
%if 0%{?with_valgrind}
|
|
BuildRequires: valgrind
|
|
%endif
|
|
|
|
%description
|
|
libccd implements variation on Gilbert-Johnson-Keerthi (GJK) algorithm +
|
|
Expand Polytope Algorithm (EPA). It also implements Minkowski Portal
|
|
Refinement (MPR, a.k.a. XenoCollide) algorithm as published in Game
|
|
Programming Gems 7.
|
|
|
|
|
|
%package devel
|
|
Summary: Development files for %{name}
|
|
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
|
|
%patch0 -p1
|
|
%patch1 -p0
|
|
|
|
%build
|
|
mkdir build
|
|
pushd build
|
|
%if 0%{?rhel}
|
|
%cmake28 \
|
|
%else
|
|
%cmake \
|
|
%endif
|
|
-DBUILD_TESTS=ON \
|
|
-DCMAKE_BUILD_TYPE=None \
|
|
..
|
|
popd
|
|
make -C build %{?_smp_mflags}
|
|
|
|
%install
|
|
rm -rf $RPM_BUILD_ROOT
|
|
make -C build install DESTDIR=$RPM_BUILD_ROOT
|
|
find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';'
|
|
rm -f $RPM_BUILD_ROOT%{_libdir}/*.a
|
|
|
|
%check
|
|
%if 0%{?with_valgrind}
|
|
make -C build test
|
|
%endif
|
|
|
|
%post -p /sbin/ldconfig
|
|
|
|
%postun -p /sbin/ldconfig
|
|
|
|
|
|
%files
|
|
%doc BSD-LICENSE README
|
|
%{_libdir}/*.so.*
|
|
|
|
%files devel
|
|
%doc doc/jgt98convex.pdf
|
|
%{_includedir}/*
|
|
%{_libdir}/*.so
|
|
%{_libdir}/pkgconfig/*.pc
|
|
|
|
%changelog
|
|
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.4-3
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
|
|
|
|
* Wed Jan 09 2013 Dan Horák <dan[at]danny.cz> - 1.4-2
|
|
- build on platforms without valgrind
|
|
|
|
* Mon Oct 22 2012 Rich Mattes <richmattes@gmail.com> - 1.4-1
|
|
- Update to release 1.4
|
|
|
|
* Tue May 29 2012 Rich Mattes <richmattes@gmail.com> - 1.3-3
|
|
- Fixed pkgconfig file to point to correct include dir
|
|
|
|
* Sat May 26 2012 Rich Mattes <richmattes@gmail.com> - 1.3-2
|
|
- Convert test suite to CTest
|
|
|
|
* Fri May 25 2012 Rich Mattes <richmattes@gmail.com> - 1.3-1
|
|
- Update to release 1.3
|
|
- Remove upstreamed soname patch
|
|
|
|
* Sun May 06 2012 Rich Mattes <richmattes@gmail.com> - 1.2-3
|
|
- Removed -static subpackage.
|
|
|
|
* Mon Apr 30 2012 Rich Mattes <richmattes@gmail.com> - 1.2-2
|
|
- Update soname patch to match upstream implementation
|
|
|
|
* Fri Apr 27 2012 Rich Mattes <richmattes@gmail.com> - 1.2-1
|
|
- Initial package
|