2012-03-21 23:43:06 +01:00
|
|
|
#
|
2012-05-06 22:54:16 +02:00
|
|
|
# spec file for package ccx
|
2012-03-21 23:43:06 +01:00
|
|
|
#
|
2012-05-06 22:54:16 +02:00
|
|
|
# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
2012-03-21 23:43:06 +01:00
|
|
|
#
|
|
|
|
# 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/
|
|
|
|
#
|
|
|
|
|
2012-05-06 22:54:16 +02:00
|
|
|
|
|
|
|
Name: ccx
|
2012-10-10 19:16:28 +02:00
|
|
|
Version: 2.5
|
2012-05-06 22:54:16 +02:00
|
|
|
Release: 0
|
|
|
|
Summary: An open source finite element package
|
|
|
|
License: GPL-2.0 and BSD-3-Clause and SUSE-Public-Domain
|
|
|
|
Group: Productivity/Scientific/Other
|
|
|
|
Url: http://www.calculix.de/
|
|
|
|
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
|
2012-10-10 19:16:28 +02:00
|
|
|
Patch0: ccx-2.5-build.patch
|
|
|
|
Patch1: ccx-1.2-doc-Makefile.patch
|
|
|
|
Patch2: ccx-2.5-no-local-compare.patch
|
|
|
|
Patch3: ccx-2.0-spooles-dynamic.patch
|
|
|
|
Patch4: ccx-2.5-abaqus-shell-heat-transfer-elements-read.patch
|
2012-05-06 22:54:16 +02:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
BuildRequires: arpack-ng-devel
|
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: gcc-fortran
|
2012-10-10 19:16:28 +02:00
|
|
|
BuildRequires: lapack-devel
|
2012-05-06 22:54:16 +02:00
|
|
|
BuildRequires: latex2html
|
|
|
|
BuildRequires: sed
|
|
|
|
BuildRequires: spooles-devel
|
2013-03-19 22:02:40 +01:00
|
|
|
%if 0%{?suse_version} > 1220
|
|
|
|
BuildRequires: texlive-pstricks
|
|
|
|
BuildRequires: texlive-dvips
|
|
|
|
%endif
|
2012-03-21 23:43:06 +01:00
|
|
|
|
|
|
|
%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
|
2012-05-06 22:54:16 +02:00
|
|
|
Summary: Example problems and documentation for CalculiX
|
|
|
|
Group: Productivity/Scientific/Other
|
2012-03-21 23:43:06 +01:00
|
|
|
%if 0%{?suse_version} > 1130
|
2012-05-06 22:54:16 +02:00
|
|
|
BuildArch: noarch
|
2012-03-21 23:43:06 +01:00
|
|
|
%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
|
|
|
|
|
|
|
|
%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}
|
|
|
|
|
2012-07-03 22:10:02 +02:00
|
|
|
# copy central descriptions to topmost folder, for %%doc directive
|
2012-03-21 23:43:06 +01:00
|
|
|
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
|
|
|
|
|
|
|
|
%fdupes $RPM_BUILD_ROOT/%{_datadir}/%{name}-examples-%{version}
|
|
|
|
|
|
|
|
%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
|