From 8001152d1a5d060e5411719536abf36339bd4404dba459585faff6a07c5574b3 Mon Sep 17 00:00:00 2001 From: Corot Sebastien Date: Wed, 21 Mar 2012 22:43:06 +0000 Subject: [PATCH] Accepting request 110513 from home:scorot Calculix is a finite elements calculation software OBS-URL: https://build.opensuse.org/request/show/110513 OBS-URL: https://build.opensuse.org/package/show/science/ccx?expand=0&rev=1 --- .gitattributes | 23 +++ ccx.changes | 18 +++ ccx.spec | 294 ++++++++++++++++++++++++++++++++++++++ ccx_2.4.doc.tar.bz2 | 3 + ccx_2.4.src.tar.bz2 | 3 + ccx_2.4.test.tar.bz2 | 3 + patch-ccx-beamread | 18 +++ patch-ccx-bufferoverrun | 14 ++ patch-ccx-build | 25 ++++ patch-ccx-doc-Makefile | 27 ++++ patch-ccx-no-local | 11 ++ patch-ccx-spooles-dynamic | 33 +++++ 12 files changed, 472 insertions(+) create mode 100644 .gitattributes create mode 100644 ccx.changes create mode 100644 ccx.spec create mode 100644 ccx_2.4.doc.tar.bz2 create mode 100644 ccx_2.4.src.tar.bz2 create mode 100644 ccx_2.4.test.tar.bz2 create mode 100644 patch-ccx-beamread create mode 100644 patch-ccx-bufferoverrun create mode 100644 patch-ccx-build create mode 100644 patch-ccx-doc-Makefile create mode 100644 patch-ccx-no-local create mode 100644 patch-ccx-spooles-dynamic diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/ccx.changes b/ccx.changes new file mode 100644 index 0000000..c524130 --- /dev/null +++ b/ccx.changes @@ -0,0 +1,18 @@ +------------------------------------------------------------------- +Wed Mar 21 21:50:49 UTC 2012 - scorot@free.fr + +- version 2.4 +- fix documentation build on recent texlive +- change package group +- doc package is noarch for 11.3 and higher + +------------------------------------------------------------------- +Fri Mar 16 22:20:23 UTC 2012 - scorot@free.fr + +- update patch0 to use openblas + +------------------------------------------------------------------- +Mon Mar 12 21:24:57 UTC 2012 - scorot@free.fr + +- use arpack-ng instead of arpack + diff --git a/ccx.spec b/ccx.spec new file mode 100644 index 0000000..ff4259d --- /dev/null +++ b/ccx.spec @@ -0,0 +1,294 @@ +# +# spec file for package ccx (Version 2.4) +# +# +# Copyright (c) 2010 SUSE LINUX Products 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: ccx +Version: 2.4 +Release: 1 +Summary: An open source finite element package +License: GPLv2 and BSD and Public Domain +URL: http://www.calculix.de/ +Group: Productivity/Scientific/Other +Source0: http://www.dhondt.de/ccx_%{version}.src.tar.bz2 +Source1: http://www.dhondt.de/ccx_%{version}.doc.tar.bz2 +Source2: http://www.dhondt.de/ccx_%{version}.test.tar.bz2 +Patch0: patch-ccx-build +Patch1: patch-ccx-doc-Makefile +Patch2: patch-ccx-beamread +Patch3: patch-ccx-bufferoverrun +Patch4: patch-ccx-no-local +Patch5: patch-ccx-spooles-dynamic +BuildRoot: %{_tmppath}/%{name}-%{version}-build +BuildRequires: gcc-fortran +BuildRequires: latex2html sed +BuildRequires: arpack-ng-devel openblas-devel spooles-devel +BuildRequires: fdupes + +%description +CalculiX is a package designed to solve field problems. +The method used is the finite element method. So far only +structural problems can be solved but it is planned to +extend the capabilities. + +%package doc +Summary: Example problems and documentation for CalculiX +Group: Productivity/Scientific/Other +%if 0%{?suse_version} > 1130 +Buildarch: noarch +%endif + +%description doc +CalculiX is a package designed to solve field problems. +The method used is the finite element method. %{name}-examples +contains examples problems, together with reference data +to check your installation. + +%prep +%setup -c -q +%setup -D -T -a 1 -q +%setup -D -T -a 2 -q + +# fixup dirs: very deep directory structure, not suitable for patching +cd ${RPM_BUILD_DIR}/%{name}-%{version} +mv CalculiX/ccx_%{version}/doc . +mv CalculiX/ccx_%{version}/src . +mv CalculiX/ccx_%{version}/test . +rmdir CalculiX/ccx_%{version} +rmdir CalculiX + + +cd ${RPM_BUILD_DIR}/%{name}-%{version} +%patch0 -p1 +%patch1 -p1 +%patch2 -p1 +%patch3 -p1 +%patch4 -p1 +%patch5 -p1 + +%build +cd ${RPM_BUILD_DIR}/%{name}-%{version} +# use rpm's proposal for CFLAGS +export GLOBAL_OFLAGS="$RPM_OPT_FLAGS -pthread" + +# and now build calculix +cd src +make %{?_smp_mflags} + +# build the documentation: +cd ../doc +# This hack fixes the documentation build which fails on recent +# texlive +ln -s %{_datadir}/texmf/fonts/enc/dvips/tex-gyre/q-texnansi.enc ./texnansi.enc +make %{?_smp_mflags} + +# copy central descriptions to topmost folder, for %doc directive +cd ${RPM_BUILD_DIR}/%{name}-%{version} +cp src/{BUGS,LOGBOOK,README.INSTALL,TODO} . +cp doc/*.pdf . +chmod 644 {BUGS,LOGBOOK,README.INSTALL,TODO} *.pdf + +%install +cd ${RPM_BUILD_DIR}/%{name}-%{version} +rm -rf $RPM_BUILD_ROOT/* +mkdir -p $RPM_BUILD_ROOT/%{_bindir} +cp src/ccx_%{version} $RPM_BUILD_ROOT/%{_bindir} +chmod 755 $RPM_BUILD_ROOT/%{_bindir}/ccx_%{version} + +mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name}-examples-%{version} +cp test/* $RPM_BUILD_ROOT/%{_datadir}/%{name}-examples-%{version} +chmod 644 $RPM_BUILD_ROOT/%{_datadir}/%{name}-examples-%{version}/* +chmod 755 $RPM_BUILD_ROOT/%{_datadir}/%{name}-examples-%{version}/compare +chmod 755 $RPM_BUILD_ROOT/%{_datadir}/%{name}-examples-%{version}/datcheck.pl +chmod 755 $RPM_BUILD_ROOT/%{_datadir}/%{name}-examples-%{version}/frdcheck.pl + +# Pass rpm filelist check +rm $RPM_BUILD_ROOT/%{_datadir}/%{name}-examples-%{version}/compare.orig + +%if %suse_version >= 1030 +%fdupes $RPM_BUILD_ROOT/%{_datadir}/%{name}-examples-%{version} +%endif + +%clean +rm -Rf $RPM_BUILD_ROOT + +%files +%defattr(-,root,root) +%{_bindir}/ccx_%{version} +%doc BUGS +%doc LOGBOOK +%doc README.INSTALL +%doc TODO + +%files doc +%defattr(-,root,root) +%doc *.pdf +%{_datadir}/%{name}-examples-%{version} + +%changelog +* Thu Sep 15 2011 scorot@gtt.fr +- version 2.3 + +* Thu Dec 16 2010 scorot@gtt.fr +- version 2.2 + +* Thu Sep 07 2010 Sebastien Corot - 2.1-5 +- rename package example to doc +- move pdf documentation files to package doc +- Changed package group to Productivity/Scientific/Engineering + +* Tue Feb 16 2010 Manfred Spraul: +- Switch to debian compatible spooles library layout +- 2.0-5 + +* Thu Feb 11 2010 Manfred Spraul: +- use spooles from separate package +- 2.0-4 + +* Sat Nov 26 2009 Manfred Spraul: +- merge I2Ohash fix from debian + +* Sat Nov 26 2009 Manfred Spraul: +- merge thermmodel bugfix from upstream +- 2.0-3 + +* Fri Nov 06 2009 Manfred Spraul: +- merge frequency bugfix from upstream +- 2.0-2 + +* Sun Aug 16 2009 Manfred Spraul: +- 2.0-1 +- merge upstream +- remove seperate .doc package + +* Sun Jul 05 2009 Manfred Spraul: +- 1.8-5 +- enable SMP for spooles + +* Sun Jul 05 2009 Manfred Spraul: +- 1.8-4 +- mark examples and doc as noarch +- move README, COPYING into main package + +* Sat Jul 04 2009 Manfred Spraul: +- switch to dynamically linked ARPACK +- remove perfarch + +* Mon Jun 29 2009 Manfred Spraul: +- update to ccx 1.8 +- remove sse2 arch +- ccx moved to /usr/bin + +* Sun Mar 4 2007 Manfred Spraul: +- update to ccx 1.6 + +* Sun Sep 4 2005 Manfred Spraul: +- further buffer overrun fixes + +* Sun Aug 14 2005 Manfred Spraul: +- update to ccx 1.4 + +* Mon Aug 01 2005 Manfred Spraul +- updates for gfortran support: no -mtune for gfortran + +* Mon Mar 01 2005 Manfred Spraul +- update 1.3 tarball: Apply fix from Guido + +* Sat Feb 26 2005 Manfred Spraul +- update to final 1.3 + +* Thu Feb 24 2005 Manfred Spraul +- 1.3 test suite added + +* Mon Feb 21 2005 Manfred Spraul +- initial drop of 1.3 + +* Mon Aug 09 2004 Manfred Spraul +- bugfix for calinput.f merged. +- support for special sse2 build added + +* Sun Jul 25 2004 Manfred Spraul +- support for special sse2 build added + +* Sun Jul 25 2004 Manfred Spraul +- Final 1.2 merged, tagged as ccx-1.2-1 + +* Mon Jul 19 2004 Manfred Spraul +- Beta of next release merged + +* Fri Jun 18 2004 Manfred Spraul +- Beta of next release merged +- taucs removed for now - needs license cleanup +- helper function for 'SOLVER=' parsing disabled. + +* Tue Sep 23 2003 Manfred Spraul +- MODAL DYNAMIC fix with body forces from Guido merged. + +* Sat Aug 30 2003 Manfred Spraul +- taucs 2.0 sources added. It depends on other packages. +- helper function for parsing 'SOLVER=' line added. + +* Sat Aug 09 2003 Manfred Spraul +- arpack & arpackbu converted to parallel spooles +- bugfix: cpus array is 11 entries long, not 10 entries. + +* Thu Aug 07 2003 Manfred Spraul +- upgraded to ccx-1.1. + +* Tue May 06 2003 Manfred Spraul +- switched to dynamic linking. With dynamic linking enabled, + the linker detects at runtime the supported threading + library and uses the best one. +- doc package added + +* Sat May 03 2003 Manfred Spraul +- switched to nptl: locking overheat without NPTL is + nearly 20% + +* Wed Mar 23 2003 Manfred Spraul +- new glibc version +- debug symbols enabled + +-* Wed Mar 05 2003 Manfred Spraul +- prototype cleanup reenabled +- fix boundary violation +- initialize neq + +* Sun Mar 01 2003 Manfred Spraul +- Forward ported to ccx-1.0 + +* Sat Feb 15 2003 Manfred Spraul +- prototype cleanup for Fortran to C interface +- ARPACK fixes that permit -ffortran-boundary-checks + +* Sat Feb 08 2003 Manfred Spraul +- parallel spooles, dynamic linking disabled. + +* Fri Feb 07 2003 Manfred Spraul +- cleanup of the spooles interface, first step towards + using parallel spooles. + +* Sun Nov 24 2002 Manfred Spraul +- add missing initialization for maxrmeminset into + allocation.f + +* Wed Sep 06 2002 Manfred Spraul +- sources & examples added into source set. +- second binary rpm for examples added +- support for cpu optimized builds + +* Wed Sep 04 2002 Manfred Spraul +- initial test version diff --git a/ccx_2.4.doc.tar.bz2 b/ccx_2.4.doc.tar.bz2 new file mode 100644 index 0000000..4360901 --- /dev/null +++ b/ccx_2.4.doc.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9f5c2fb6689c8d8e71a3a0c4776992da20803f5307085086337aa2b834ad598c +size 3282853 diff --git a/ccx_2.4.src.tar.bz2 b/ccx_2.4.src.tar.bz2 new file mode 100644 index 0000000..1e3a67f --- /dev/null +++ b/ccx_2.4.src.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cadcd0d71bb54c6d61c83ce3aaa7a3fb8c8517d40db3909778797fd05e25e7a4 +size 830747 diff --git a/ccx_2.4.test.tar.bz2 b/ccx_2.4.test.tar.bz2 new file mode 100644 index 0000000..cc9e291 --- /dev/null +++ b/ccx_2.4.test.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5eca6a56cd2a9a500317fe45579e92d70222f68681dbb76a58eef5b58bd83c05 +size 6589894 diff --git a/patch-ccx-beamread b/patch-ccx-beamread new file mode 100644 index 0000000..8b13a81 --- /dev/null +++ b/patch-ccx-beamread @@ -0,0 +1,18 @@ +--- ccx-2.2/test/compare.orig 2010-08-01 18:27:39.000000000 +0200 ++++ ccx-2.2/test/compare 2010-11-07 11:46:41.000000000 +0100 +@@ -19,6 +19,15 @@ + rm -f ${i%.inp}.frd + + # ++# beamread test? This one is special ++# ++ if [ "$i" == "beamread.inp" ]; then ++ rm -f beamread.rin ++ rm -f beamwrite.rout ++ /usr/bin/ccx_2.4 -i beamwrite ++ mv beamwrite.rout beamread.rin ++ fi ++# + # executing CalculiX and generating the .dat and + # the .frd file + # diff --git a/patch-ccx-bufferoverrun b/patch-ccx-bufferoverrun new file mode 100644 index 0000000..31fe689 --- /dev/null +++ b/patch-ccx-bufferoverrun @@ -0,0 +1,14 @@ +--- ccx-orig/src/ccx_2.4.c 2005-08-12 22:39:08.000000000 +0200 ++++ ccx-1.4/src/ccx_2.4.c 2005-09-04 08:26:27.000000000 +0200 +@@ -103,7 +103,10 @@ else{ + + for(i=1;i $@ ++ ++%.ps: %.dvi ++ dvips -o $@ $< ++ ++# Run latex three times: first to generate the aux & toc files ++# at the end of the 2nd run latex complains about incorrect ++# references, and after the 3rd run it's happy. ++%.dvi: %.tex ++ latex $< ++ echo "XXXX 2nd run XXXX" ++ latex $< ++ echo "XXXX 3nd run XXXX" ++ latex $< ++ ++clean: ++ rm -f ccx.{pdf,dvi,ps} diff --git a/patch-ccx-no-local b/patch-ccx-no-local new file mode 100644 index 0000000..eead13d --- /dev/null +++ b/patch-ccx-no-local @@ -0,0 +1,11 @@ +--- ccx-1.8/test/compare.orig 2009-06-29 22:50:57.000000000 +0200 ++++ ccx-1.8/test/compare 2009-06-29 22:51:06.000000000 +0200 +@@ -30,7 +30,7 @@ + # the .frd file + # + +- /usr/local/bin/ccx_2.4 ${i%.inp} >> $tempfile 2>&1 ++ /usr/bin/ccx_2.4 ${i%.inp} >> $tempfile 2>&1 + + # + # check whether the .dat and .dat.ref files exist diff --git a/patch-ccx-spooles-dynamic b/patch-ccx-spooles-dynamic new file mode 100644 index 0000000..df2ac9a --- /dev/null +++ b/patch-ccx-spooles-dynamic @@ -0,0 +1,33 @@ +--- ccx-2.0/src/cascade.c 2009-08-12 21:54:16.000000000 +0200 ++++ sav/src/cascade.c 2010-02-11 20:02:25.000000000 +0100 +@@ -21,9 +21,9 @@ + #include + + #ifdef SPOOLES +-#include +-#include +-#include ++#include ++#include ++#include + #endif + + #include "CalculiX.h" +--- ccx-2.0/src/spooles.h 2009-08-12 21:54:17.000000000 +0200 ++++ sav/src/spooles.h 2010-02-11 20:01:18.000000000 +0100 +@@ -21,11 +21,11 @@ + * seperated from CalculiX.h: otherwise everyone would have to include + * the spooles header files + */ +-#include +-#include +-#include ++#include ++#include ++#include + #if USE_MT +-#include ++#include + #endif + + /* increase this for debugging */