390d704
# Development has moved to github, but no releases have been made yet.
34ae653
%global commit      a66628fa2805feb47f8cc7a229f3b6fe6f6e63e8
390d704
%global shortcommit %(c=%{commit}; echo ${c:0:7})
390d704
8082e63
Name:           carat
34ae653
Version:        2.1b1.2020.06.04
34ae653
Release:        1%{?dist}
8082e63
Summary:        Crystallographic AlgoRithms And Tables
8082e63
8082e63
License:        GPLv3+
390d704
URL:            https://github.com/lbfm-rwth/%{name}
390d704
Source0:        %{url}/archive/%{commit}/%{name}-%{shortcommit}.tar.gz
8082e63
Source1:        %{name}.module.in
8082e63
713fadc
BuildRequires:  environment(modules)
0325365
BuildRequires:  gcc
8082e63
BuildRequires:  gmp-devel
713fadc
BuildRequires:  libtool
3227b8f
BuildRequires:  make
8082e63
BuildRequires:  tex(latex)
8082e63
BuildRequires:  tex(epic.sty)
8082e63
8082e63
Requires:       %{name}-tables = %{version}-%{release}
Orion Poplawski e4969d3
Requires:       environment(modules)
8082e63
8082e63
%description
8082e63
CARAT is a computer package which handles enumeration, construction,
8082e63
recognition, and comparison problems for crystallographic groups up to
8082e63
dimension 6.  The name CARAT itself is an acronym for Crystallographic
8082e63
AlgoRithms And Tables.
8082e63
8082e63
Due to its specialized nature and some generically named binaries, this
Orion Poplawski e4969d3
package uses environment modules to access its binaries.
8082e63
8082e63
%package tables
8082e63
Summary:        Tables for CARAT binaries
8082e63
BuildArch:      noarch
8082e63
8082e63
%description tables
8082e63
Tables for CARAT binaries to consume.
8082e63
8082e63
%package doc
8082e63
Summary:        Documentation and examples for CARAT
8082e63
BuildArch:      noarch
8082e63
8082e63
%description doc
8082e63
Documentation and examples for CARAT.
8082e63
8082e63
%prep
390d704
%autosetup -p1 -n %{name}-%{commit}
8082e63
8082e63
# Don't ship XV thumbnails with the examples
8082e63
rm -fr tex/examples/.xvpics
8082e63
713fadc
# Generate configure
713fadc
./autogen.sh
3bba030
8082e63
%build
713fadc
%configure
713fadc
%make_build
8082e63
8082e63
# Build the documentation
8082e63
cd tex
8082e63
pdflatex manual
390d704
cd -
8082e63
8082e63
%install
8082e63
# Install the binaries
23439c6
mkdir -p %{buildroot}%{_libexecdir}/%{name}
713fadc
cp -dp bin/* %{buildroot}%{_libexecdir}/%{name}
8082e63
8082e63
# Install the environment-modules file
713fadc
mkdir -p %{buildroot}%{_modulesdir}
23439c6
sed 's#@LIBDIR@#'%{_libexecdir}/%{name}'#g;' < %{SOURCE1} \
713fadc
  > %{buildroot}%{_modulesdir}/%{name}-%{_arch}
713fadc
touch -r %{SOURCE1} %{buildroot}%{_modulesdir}/%{name}-%{_arch}
8082e63
8082e63
# Install the tables
8082e63
mkdir -p %{buildroot}%{_datadir}/%{name}
8082e63
cp -a tables %{buildroot}%{_datadir}/%{name}
8082e63
rm -f %{buildroot}%{_datadir}/%{name}/tables/*.tar.gz
8082e63
rm -f %{buildroot}%{_datadir}/%{name}/tables/lattices/{README.lattice,*.sh}
8082e63
rm -f %{buildroot}%{_datadir}/%{name}/tables/qcatalog/*.sh
8082e63
rm -f %{buildroot}%{_datadir}/%{name}/tables/symbol/{Makefile,README}
8082e63
713fadc
%check
713fadc
cd tst
713fadc
./run_all.sh
713fadc
cd -
713fadc
8082e63
%files
713fadc
%doc CHANGES.md README.md tex/README.short tex/manual.pdf
713fadc
%{_modulesdir}/%{name}-%{_arch}
23439c6
%{_libexecdir}/%{name}/
8082e63
8082e63
%files tables
8082e63
%doc tables/lattices/README.lattice
713fadc
%license LICENSE
8082e63
%{_datadir}/%{name}
8082e63
8082e63
%files doc
8082e63
%doc tex/Graph tex/*.html tex/examples tex/progs
713fadc
%license LICENSE
8082e63
8082e63
%changelog
34ae653
* Thu Jul  1 2021 Jerry James <loganjerry@gmail.com> - 2.1b1.2020.06.04-1
34ae653
- Update to latest git snapshot
34ae653
b2437f9
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 2.1b1.2019.12.16-4
b2437f9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
b2437f9
51f5762
* Mon Jul 27 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2.1b1.2019.12.16-3
51f5762
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
51f5762
1ae58aa
* Tue Jan 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2.1b1.2019.12.16-2
1ae58aa
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
1ae58aa
713fadc
* Thu Jan 23 2020 Jerry James <loganjerry@gmail.com> - 2.1b1.2019.12.16-1
713fadc
- Update to latest git snapshot
713fadc
- Change upstream's version scheme to one friendly to RPM
713fadc
- The license file is now on github
713fadc
- All patches have been upstreamed; drop them
713fadc
- Add %%check script
713fadc
390d704
* Thu Oct 31 2019 Jerry James <loganjerry@gmail.com> - 2.1b1.23.05.2019-1
390d704
- New upstream version
390d704
- New github URLs
390d704
- COPYING is not on github (https://github.com/lbfm-rwth/carat/issues/33)
713fadc
- Add patches 0001 through 0006
390d704
05739c8
* Wed Jul 24 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.1b1.19.07.2008-13
05739c8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
05739c8
bc86625
* Thu Jan 31 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.1b1.19.07.2008-12
bc86625
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
bc86625
23439c6
* Tue Oct 30 2018 Jerry James <loganjerry@gmail.com> - 2.1b1.19.07.2008-11
23439c6
- Move binaries to libexecdir so gap-pkg-carat can be noarch
23439c6
c7c4236
* Thu Jul 12 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.1b1.19.07.2008-10
c7c4236
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
c7c4236
6d60533
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.1b1.19.07.2008-9
6d60533
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
6d60533
cd2a3bc
* Wed Aug 02 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.1b1.19.07.2008-8
cd2a3bc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
cd2a3bc
425dbb4
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.1b1.19.07.2008-7
425dbb4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
425dbb4
d4b227a
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.1b1.19.07.2008-6
d4b227a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
d4b227a
3f86602
* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 2.1b1.19.07.2008-5
3f86602
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
3f86602
Orion Poplawski e4969d3
* Wed Jan 6 2016 Orion Poplawski <orion@cora.nwra.com> - 2.1b1.19.07.2008-4
Orion Poplawski e4969d3
- Require environment(modules), install into generic modulefiles location
Orion Poplawski e4969d3
3bba030
* Sun Sep 13 2015 Peter Robinson <pbrobinson@fedoraproject.org> 2.1b1.19.07.2008-3
3bba030
- Update config.guess to fix FTBFS on new arches
3bba030
8082e63
* Sat Jun 13 2015 Jerry James <loganjerry@gmail.com> - 2.1b1.19.07.2008-2
8082e63
- Add COPYING as a license file
8082e63
8082e63
* Thu May 28 2015 Jerry James <loganjerry@gmail.com> - 2.1b1.19.07.2008-1
8082e63
- Initial RPM