[packages/gecode] new, version 4.2.1

glen glen at pld-linux.org
Fri Jul 11 21:06:53 CEST 2014


commit 87d0643065c1d03afc3501ee419db5f8fd314590
Author: Elan Ruusamäe <glen at delfi.ee>
Date:   Fri Jul 11 22:06:18 2014 +0300

    new, version 4.2.1
    
    based on fedora package
    1f2c2321be84b3a8b5e40f1b40e525379437cdfb

 gecode.spec       | 164 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
 no_examples.patch |  12 ++++
 2 files changed, 176 insertions(+)
---
diff --git a/gecode.spec b/gecode.spec
new file mode 100644
index 0000000..ea19312
--- /dev/null
+++ b/gecode.spec
@@ -0,0 +1,164 @@
+# TODO
+# - html docs seems not to be built
+
+# Conditional build:
+%bcond_with	doc		# build doc
+
+Summary:	Generic constraint development environment
+Name:		gecode
+Version:	4.2.1
+Release:	1
+License:	MIT
+Group:		Libraries
+Source0:	http://www.gecode.org/download/%{name}-%{version}.7z
+# Source0-md5:	5a37a56647b1c593640ebd085bf4c066
+Patch0:		no_examples.patch
+URL:		http://www.gecode.org/
+BuildRequires:	automake
+BuildRequires:	bison
+BuildRequires:	boost-devel
+BuildRequires:	flex >= 2.5.33
+BuildRequires:	graphviz
+BuildRequires:	p7zip-standalone
+BuildRequires:	qt4-build
+%if %{with doc}
+BuildRequires:	doxygen
+BuildRequires:	tex(dvips)
+BuildRequires:	tex(latex)
+%endif
+BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+Gecode is a toolkit for developing constraint-based systems and
+applications. Gecode provides a constraint solver with
+state-of-the-art performance while being modular and extensible.
+
+%package devel
+Summary:	Development files for %{name}
+Group:		Development/Libraries
+Requires:	%{name} = %{version}-%{release}
+
+%description devel
+The %{name}-devel package contains libraries and header files for
+developing applications that use %{name}.
+
+%package doc
+Summary:	Documentation for %{name}
+Group:		Documentation
+Requires:	%{name} = %{version}-%{release}
+%if "%{_rpmversion}" >= "5"
+BuildArch:	noarch
+%endif
+
+%description doc
+The %{name}-doc package contains documentation files for %{name}.
+
+%package examples
+Summary:	Example code for %{name}
+Group:		Documentation
+Requires:	%{name} = %{version}-%{release}
+%if "%{_rpmversion}" >= "5"
+BuildArch:	noarch
+%endif
+
+%description examples
+The %{name}-examples package contains example code for %{name}.
+
+%prep
+%setup -q
+%patch0 -p1
+
+# Fix permissions
+find . -name '*.hh' -exec chmod 0644 '{}' \;
+find . -name '*.hpp' -exec chmod 0644 '{}' \;
+find . -name '*.cpp' -exec chmod 0644 '{}' \;
+chmod 0644 LICENSE misc/doxygen/*.png
+
+# Fix encoding
+cd examples
+for file in bin-packing.cpp black-hole.cpp dominating-queens.cpp scowl.hpp word-square.cpp; do
+	iconv -f ISO-8859-1 -t UTF-8 -o $file.new $file && \
+	touch -r $file $file.new && \
+	mv $file.new $file
+done
+
+%build
+%{__aclocal}
+%{__autoconf}
+%configure \
+	--disable-examples \
+	--enable-float-vars \
+	--enable-leak-debug \
+	--with-boost-include=%{_includedir}/boost
+
+%{__make}
+%{__make} doc
+%{__make} ChangeLog
+
+iconv --from=ISO-8859-1 --to=UTF-8 -o ChangeLog.new ChangeLog
+mv ChangeLog.new ChangeLog
+
+%install
+rm -rf $RPM_BUILD_ROOT
+%{__make} install \
+	DESTDIR=$RPM_BUILD_ROOT
+
+install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
+cp -a examples/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%post	-p /sbin/ldconfig
+%postun	-p /sbin/ldconfig
+
+%files
+%defattr(644,root,root,755)
+%doc ChangeLog LICENSE
+%attr(755,root,root) %{_libdir}/libgecodedriver.so.*.*
+%ghost %{_libdir}/libgecodedriver.so.36
+%attr(755,root,root) %{_libdir}/libgecodeflatzinc.so.*.*
+%ghost %{_libdir}/libgecodeflatzinc.so.36
+%attr(755,root,root) %{_libdir}/libgecodefloat.so.*.*
+%ghost %{_libdir}/libgecodefloat.so.36
+%attr(755,root,root) %{_libdir}/libgecodegist.so.*.*
+%ghost %{_libdir}/libgecodegist.so.36
+%attr(755,root,root) %{_libdir}/libgecodeint.so.*.*
+%ghost %{_libdir}/libgecodeint.so.36
+%attr(755,root,root) %{_libdir}/libgecodekernel.so.*.*
+%ghost %{_libdir}/libgecodekernel.so.36
+%attr(755,root,root) %{_libdir}/libgecodeminimodel.so.*.*
+%ghost %{_libdir}/libgecodeminimodel.so.36
+%attr(755,root,root) %{_libdir}/libgecodesearch.so.*.*
+%ghost %{_libdir}/libgecodesearch.so.36
+%attr(755,root,root) %{_libdir}/libgecodeset.so.*.*
+%ghost %{_libdir}/libgecodeset.so.36
+%attr(755,root,root) %{_libdir}/libgecodesupport.so.*.*
+%ghost %{_libdir}/libgecodesupport.so.36
+
+%files devel
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_bindir}/fzn-gecode
+%attr(755,root,root) %{_bindir}/mzn-gecode
+%{_datadir}/%{name}
+%{_includedir}/%{name}
+%{_libdir}/libgecodedriver.so
+%{_libdir}/libgecodeflatzinc.so
+%{_libdir}/libgecodefloat.so
+%{_libdir}/libgecodegist.so
+%{_libdir}/libgecodeint.so
+%{_libdir}/libgecodekernel.so
+%{_libdir}/libgecodeminimodel.so
+%{_libdir}/libgecodesearch.so
+%{_libdir}/libgecodeset.so
+%{_libdir}/libgecodesupport.so
+
+%if %{with doc}
+%files doc
+%defattr(644,root,root,755)
+%doc doc/*
+%endif
+
+%files examples
+%defattr(644,root,root,755)
+%{_examplesdir}/%{name}-%{version}
diff --git a/no_examples.patch b/no_examples.patch
new file mode 100644
index 0000000..32aa374
--- /dev/null
+++ b/no_examples.patch
@@ -0,0 +1,12 @@
+--- gecode-4.0.0/Makefile.in.orig	2013-06-15 17:52:32.996108131 -0400
++++ gecode-4.0.0/Makefile.in	2013-06-15 17:53:04.100637606 -0400
+@@ -953,8 +953,7 @@
+ ALLGECODEHDR = \
+ 	$(SUPPORTHDR) $(KERNELHDR) $(SEARCHHDR) \
+         $(INTHDR) $(FLOATHDR) $(SETHDR) $(MMHDR) \
+-	$(DRIVERHDR) $(ITERHDR) $(GISTHDR) $(FLATZINCHDR) \
+-	$(INTEXAMPLEHDR)
++	$(DRIVERHDR) $(ITERHDR) $(GISTHDR) $(FLATZINCHDR)
+ ALLHDR = \
+ 	$(ALLGECODEHDR) $(THIRDHDR)
+ ALLOBJ0 = $(ALLSRC:%.cpp=%$(OBJSUFFIX)) \
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/gecode.git/commitdiff/87d0643065c1d03afc3501ee419db5f8fd314590



More information about the pld-cvs-commit mailing list