3fd52cf
%define debug_package %{nil}
cc0ec24
# rpmbuild doesn't get useful debuginfo from .a libs, apparently
3fd52cf
3fd52cf
Name:           cddlib
3fd52cf
Version:        094f
c0d2d0e
Release:        9%{?dist}
3fd52cf
Summary:        A library for generating all vertices in convex polyhedrons
3fd52cf
Group:          Applications/Engineering
3fd52cf
License:        GPLv2+
3fd52cf
URL:            http://www.ifor.math.ethz.ch/~fukuda/cdd_home/
3fd52cf
#Source0:        ftp://ftp.ifor.math.ethz.ch/pub/fukuda/cdd/%{name}-094f.tar.gz
3fd52cf
#tar -xzf cddlib-094f.tar.gz
3fd52cf
#rm cddlib-094f/examples-ml/Combinatorica5.m
3fd52cf
#tar -czf cddlib-094-free.tar.gz cddlib-094f/
3fd52cf
Source0:        %{name}-094f-free.tar.bz2
3fd52cf
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
3fd52cf
BuildRequires:  gmp-devel
c58279d
BuildRequires:  texlive-latex
3fd52cf
3fd52cf
3fd52cf
%description
3fd52cf
The C-library cddlib is a C implementation of the Double Description 
3fd52cf
Method of Motzkin et al. for generating all vertices (i.e. extreme points)
3fd52cf
and extreme rays of a general convex polyhedron in R^d given by a system 
3fd52cf
of linear inequalities:
3fd52cf
3fd52cf
   P = { x=(x1, ..., xd)^T :  b - A  x  >= 0 }
3fd52cf
3fd52cf
where A is a given m x d real matrix, b is a given m-vector 
3fd52cf
and 0 is the m-vector of all zeros.
3fd52cf
3fd52cf
The program can be used for the reverse operation (i.e. convex hull
3fd52cf
computation). This means that one can move back and forth between 
3fd52cf
an inequality representation and a generator (i.e. vertex and ray) 
3fd52cf
representation of a polyhedron with cdd. Also, cdd can solve a linear
3fd52cf
programming problem, i.e. a problem of maximizing and minimizing 
3fd52cf
a linear function over P.
3fd52cf
3fd52cf
3fd52cf
%package devel
3fd52cf
Summary: Header and static libraries for cddlib
3fd52cf
Group: Development/Libraries
3fd52cf
Requires: gmp-devel
3fd52cf
Provides: %{name}-static = %{version}-%{release}
3fd52cf
3fd52cf
%description devel
3fd52cf
Include files and static libraries for cddlib.
3fd52cf
3fd52cf
3fd52cf
%prep
3fd52cf
%setup -q
3fd52cf
# Don't build/install the example programs
3fd52cf
echo -e 'all:\ninstall:' > src/Makefile.in
3fd52cf
echo -e 'all:\ninstall:' > src-gmp/Makefile.in
3fd52cf
# Clean up the examples
3fd52cf
rm -rf src/~
3fd52cf
rm -rf src*/.DS_Store* src*/.gdb_history examples*/.DS_Store*
3fd52cf
rm -rf src-gmp/~
3fd52cf
chmod -x -R examples*/* src*/*
c58279d
rm doc/cddlibman.pdf
3fd52cf
3fd52cf
3fd52cf
%build
3fd52cf
%configure
3fd52cf
make %{?_smp_mflags}
c58279d
cd doc
c58279d
  pdflatex cddlibman.tex
3fd52cf
3fd52cf
3fd52cf
%install
3fd52cf
rm -rf $RPM_BUILD_ROOT
cc0ec24
make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p"
c58279d
mkdir $RPM_BUILD_ROOT%{_includedir}/cddlib
c58279d
mv $RPM_BUILD_ROOT%{_includedir}/{cdd,cdd_f,cddmp,cddmp_f,cddtypes,cddtypes_f,setoper}.h \
c58279d
  $RPM_BUILD_ROOT%{_includedir}/cddlib/
3fd52cf
3fd52cf
3fd52cf
%clean
3fd52cf
rm -rf $RPM_BUILD_ROOT
3fd52cf
3fd52cf
3fd52cf
%files devel
3fd52cf
%defattr(-,root,root,-)
3fd52cf
%doc doc/cddlibman.pdf
3fd52cf
%doc examples* src*
c58279d
%{_includedir}/cddlib
3fd52cf
%{_libdir}/libcdd.a
3fd52cf
%{_libdir}/libcddgmp.a
3fd52cf
3fd52cf
3fd52cf
%changelog
c0d2d0e
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 094f-9
c0d2d0e
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
c0d2d0e
40345a5
* Mon Feb 23 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 094f-8
40345a5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
40345a5
cc0ec24
* Fri Nov 28 2008 Conrad Meyer <konrad@tylerc.org> - 094f-7
cc0ec24
- Install headers with install -p to save timestamps.
c58279d
- Install headers to namespaced directory.
c58279d
- Generate pdf from latex source.
cc0ec24
3fd52cf
* Fri Oct 31 2008 Conrad Meyer <konrad@tylerc.org> - 094f-6
3fd52cf
- Describe vividly the process whereby the non-free file is
3fd52cf
  stripped from the source tarball.
3fd52cf
3fd52cf
* Thu Oct 30 2008 Conrad Meyer <konrad@tylerc.org> - 094f-5
3fd52cf
- Tarball scrubbed of content we are unable to ship.
3fd52cf
3fd52cf
* Tue Oct 28 2008 Conrad Meyer <konrad@tylerc.org> - 094f-4
3fd52cf
- Remove modules that do not meet licensing guidelines.
3fd52cf
- Don't generate debuginfo.
3fd52cf
3fd52cf
* Tue Oct 28 2008 Conrad Meyer <konrad@tylerc.org> - 094f-3
3fd52cf
- Fix permissions on documentation.
3fd52cf
3fd52cf
* Mon Oct 27 2008 Conrad Meyer <konrad@tylerc.org> - 094f-2
3fd52cf
- Incorporate several suggestions from review.
3fd52cf
3fd52cf
* Thu Sep 25 2008 Conrad Meyer <konrad@tylerc.org> - 094f-1
3fd52cf
- Initial package.