Blob Blame History Raw
Name:           avogadro2
Version:        1.90.0
Release:        1%{?dist}
Summary:        Advanced molecular editor

License:        BSD

BuildRequires:  cmake, chrpath, desktop-file-utils
BuildRequires:  avogadro2-libs-devel, molequeue-devel, spglib-devel
BuildRequires:  gcc-c++, doxygen
BuildRequires:  eigen3-devel, hdf5-devel, glew-devel
BuildRequires:  qt5-qtbase-devel, qt5-qttools-devel

Requires: python3

Avogadro is an advanced molecular editor designed for cross-platform use in
computational chemistry, molecular modeling, bioinformatics, materials science,
and related areas. It offers flexible rendering and a powerful plugin
architecture. The code in this repository is a rewrite of Avogadro with source
code split across a libraries repository and an application repository. Core
features and goals of the Avogadro project:

* Open source distributed under the liberal 3-clause BSD license
* Cross platform with nightly builds on Linux, Mac OS X and Windows
* Intuitive interface designed to be useful to whole community
* Fast and efficient embracing the latest technologies
* Extensible, making extensive use of a plugin architecture
* Flexible supporting a range of chemical data formats and packages

%setup -q -n avogadroapp-%{version}

mkdir build && pushd build
export LDFLAGS="%{__global_ldflags} -Wl,--as-needed"
export CFLAGS="%{optflags} -I%{_includedir}/%{name}"
export CXXFLAGS="%{optflags} -I%{_includedir}/%{name}"
 -Wno-dev \
 -DAvogadroLibs_DIR:PATH=%{_libdir} \


%make_install -C build
rm -rf %{buildroot}%{_datadir}/doc

chrpath -d %{buildroot}%{_bindir}/%{name}

desktop-file-edit --set-key=Exec --set-value='env LD_LIBRARY_PATH=%{_libdir}/%{name} %{name} %f' \
 --set-key=Icon --set-value=%{_datadir}/icons/%{name}/avogadro2_128.png \

mkdir -p %{buildroot}%{_datadir}/icons/%{name}
cp -a avogadro/icons/* %{buildroot}%{_datadir}/icons/%{name}/

/bin/touch --no-create %{_datadir}/icons/%{name} &>/dev/null || :

if [ $1 -eq 0 ] ; then
    /bin/touch --no-create %{_datadir}/icons/%{name} &>/dev/null
    /usr/bin/gtk-update-icon-cache %{_datadir}/icons/%{name} &>/dev/null || :

/usr/bin/gtk-update-icon-cache %{_datadir}/icons/%{name} &>/dev/null || :

pushd build
#ctest -V

%license COPYING

* Sat Mar 11 2017 Antonio Trande <> - 1.90.0-1
- Initial package