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