]>
Commit | Line | Data |
---|---|---|
638a5511 AM |
1 | Summary: An advanced molecular editor for chemical purposes |
2 | Name: avogadro | |
43ce3cb8 | 3 | Version: 1.2.0 |
47616750 | 4 | Release: 6 |
638a5511 AM |
5 | License: GPL v2 |
6 | Group: Applications/Editors | |
43ce3cb8 JR |
7 | Source0: http://downloads.sourceforge.net/avogadro/%{name}-%{version}.tar.gz |
8 | # Source0-md5: 3206068fc27bd3b717c568ee72f1e5ec | |
47cd8f4e JR |
9 | Patch0: %{name}-linguist.patch |
10 | Patch1: %{name}-cmake.patch | |
29338955 | 11 | Patch2: %{name}-moc-boost.patch |
43ce3cb8 | 12 | Patch3: gcc6.patch |
da0ef5d8 | 13 | Patch4: python-install.patch |
4d9dc8e3 | 14 | URL: http://avogadro.openmolecules.net/ |
1abd04fb KK |
15 | BuildRequires: QtNetwork-devel |
16 | BuildRequires: QtOpenGL-devel | |
638a5511 | 17 | BuildRequires: boost-devel >= 1.35 |
aa7b58b0 | 18 | BuildRequires: boost-python-devel |
4d9dc8e3 | 19 | BuildRequires: cmake >= 2.8.0 |
638a5511 AM |
20 | BuildRequires: desktop-file-utils |
21 | BuildRequires: docbook-utils | |
4d9dc8e3 | 22 | BuildRequires: eigen >= 1:2.0.12 |
638a5511 | 23 | BuildRequires: glew-devel >= 1.5.0 |
638a5511 | 24 | BuildRequires: openbabel-devel >= 2.2.2 |
cc593d4e | 25 | BuildRequires: pkgconfig |
fdf58bb8 KK |
26 | BuildRequires: python-numpy-devel |
27 | BuildRequires: python-sip-devel | |
47cd8f4e | 28 | BuildRequires: qt4-build >= 4.8.2-5 |
cc593d4e | 29 | BuildRequires: qt4-linguist |
47cd8f4e | 30 | BuildRequires: qt4-qmake >= 4.8.2-5 |
4d9dc8e3 | 31 | BuildRequires: sip |
47616750 | 32 | BuildConflicts: eigen3 |
638a5511 AM |
33 | Requires: %{name}-libs = %{version}-%{release} |
34 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
35 | ||
36 | %description | |
37 | An advanced molecular editor designed for cross-platform use in | |
38 | computational chemistry, molecular modeling, bioinformatics, materials | |
39 | science, and related areas, which offers flexible rendering and a | |
40 | powerful plugin architecture. | |
41 | ||
638a5511 AM |
42 | %package libs |
43 | Summary: Shared libraries for Avogadro | |
44 | Group: Libraries | |
45 | ||
46 | %description libs | |
47 | This package contains the shared libraries for the molecular editor | |
48 | Avogadro. | |
49 | ||
50 | %package devel | |
51 | Summary: Development files for Avogadro | |
52 | Group: Development/Libraries | |
53 | Requires: %{name}-libs = %{version}-%{release} | |
50c97514 | 54 | Requires: glew-devel |
638a5511 AM |
55 | |
56 | %description devel | |
57 | This package contains files to develop applications using Avogadros | |
58 | libraries. | |
59 | ||
60 | %prep | |
61 | %setup -q | |
0bfdc0c5 | 62 | %patch0 -p0 |
47cd8f4e | 63 | %patch1 -p1 |
29338955 | 64 | %patch2 -p1 |
c7f1d607 | 65 | %patch3 -p1 |
da0ef5d8 | 66 | %patch4 -p1 |
638a5511 | 67 | |
638a5511 AM |
68 | %build |
69 | install -d build | |
70 | cd build | |
4d9dc8e3 | 71 | %cmake \ |
638a5511 AM |
72 | -DENABLE_GLSL=ON \ |
73 | -DENABLE_PYTHON=ON \ | |
74 | -DENABLE_UPDATE_CHECKER=OFF \ | |
75 | -DCMAKE_BUILD_TYPE=Release \ | |
638a5511 | 76 | .. |
5654b505 | 77 | |
43ce3cb8 | 78 | %{__make} -j1 |
638a5511 | 79 | |
638a5511 AM |
80 | %install |
81 | rm -rf $RPM_BUILD_ROOT | |
47cd8f4e JR |
82 | install -d $RPM_BUILD_ROOT%{_datadir}/qt4/mkspecs/features |
83 | ||
5654b505 | 84 | %{__make} -C build install \ |
85 | DESTDIR=$RPM_BUILD_ROOT | |
638a5511 | 86 | |
1b4a3b9d | 87 | %if "%{_lib}" != "lib" |
0d9da5e1 | 88 | %{__mv} $RPM_BUILD_ROOT{%{_prefix}/lib,%{_libdir}}/libmsym.so |
1b4a3b9d | 89 | %endif |
0d9da5e1 | 90 | |
638a5511 | 91 | %post libs -p /sbin/ldconfig |
638a5511 AM |
92 | %postun libs -p /sbin/ldconfig |
93 | ||
638a5511 AM |
94 | %clean |
95 | rm -rf $RPM_BUILD_ROOT | |
96 | ||
638a5511 AM |
97 | %files |
98 | %defattr(644,root,root,755) | |
43ce3cb8 | 99 | %doc AUTHORS COPYING |
638a5511 | 100 | %attr(755,root,root) %{_bindir}/%{name} |
47cd8f4e | 101 | %attr(755,root,root) %{_bindir}/avopkg |
43ce3cb8 | 102 | %attr(755,root,root) %{_bindir}/qube |
8678fa6a | 103 | %attr(755,root,root) %{_libdir}/libmsym.so |
638a5511 AM |
104 | %{_datadir}/%{name} |
105 | %{_pixmapsdir}/%{name}-icon.png | |
106 | %{_desktopdir}/%{name}.desktop | |
47cd8f4e JR |
107 | %{_mandir}/man1/avogadro.1* |
108 | %{_mandir}/man1/avopkg.1* | |
638a5511 | 109 | |
638a5511 AM |
110 | %files devel |
111 | %defattr(644,root,root,755) | |
112 | %{_datadir}/lib%{name} | |
113 | %{_includedir}/%{name} | |
8678fa6a JR |
114 | %attr(755,root,root) %{_libdir}/libavogadro.so |
115 | %attr(755,root,root) %{_libdir}/libavogadro_OpenQube.so | |
47cd8f4e | 116 | %{_datadir}/qt4/mkspecs/features/avogadro.prf |
43ce3cb8 | 117 | %{_pkgconfigdir}/avogadro.pc |
638a5511 | 118 | |
638a5511 AM |
119 | %files libs |
120 | %defattr(644,root,root,755) | |
8678fa6a | 121 | %attr(755,root,root) %{py_sitedir}/Avogadro.so |
638a5511 AM |
122 | %{_libdir}/%{name} |
123 | %attr(755,root,root) %{_libdir}/*.so.* |