/[ascend]/trunk/ascend.spec
ViewVC logotype

Contents of /trunk/ascend.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1443 - (show annotations) (download)
Sat May 26 09:00:53 2007 UTC (17 years, 4 months ago) by jpye
File size: 7007 byte(s)
Fixed problems with installation of documentation on FC6
1 %define pyver %(python -c 'import sys ; print sys.version[:3]')
2 %{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
3 %{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
4
5 Name: ascend
6 Summary: ASCEND modelling environment
7 Version: 0.9.5.110
8
9 # Use release 0.* so that other users can do patch releases with a higher number
10 # and still have the update occur automatically.
11 Release: 0%{?dist}
12
13 License: GPL
14 Group: Applications/Engineering
15 Source: ascend-0.9.5.110.tar.bz2
16 URL: http://ascend.cheme.cmu.edu/
17
18 Prefix: %{_prefix}
19 Packager: John Pye
20 Vendor: Carnegie Mellon University
21
22 Buildroot: /var/tmp/%{name}-buildroot
23
24 %description
25 ASCEND IV is both a large-scale object-oriented mathematical
26 modeling environment and a strongly typed mathematical modeling
27 language. Although ASCEND has primarily been developed by Chemical
28 Engineers, great care has been exercised to assure that it is
29 domain independent. ASCEND can support modeling activities in
30 fields from Architecture to (computational) Zoology.
31
32 #----------build dependencies------------
33
34 # ...general
35 BuildRequires: scons >= 0.96.92
36 BuildRequires: bison >= 2.0
37 BuildRequires: flex >= 2.5.4
38 BuildRequires: swig >= 1.3.24
39 BuildRequires: gcc-gfortran
40 BuildRequires: libgfortran
41 BuildRequires: blas-devel
42 BuildRequires: sundials >= 2.2.0
43 BuildRequires: conopt >= 3.14
44
45 # ...pygtk
46 BuildRequires: python-devel >= 2.4
47
48 # ... tcl/tk
49 BuildRequires: tk-devel >= 8.3, tcl-devel >= 8.3
50 BuildRequires: tktable < 2.10, tktable >= 2.8
51
52 # ... GNOME
53 BuildRequires: desktop-file-utils
54
55 # ... documentation
56 # There are no dependencies for documentation as the tarball
57 # will always contain documentation in compiled form. Only
58 # when building from subversion are targets formats of the
59 # documentation files not available.
60
61 #-----------runtime dependencies-----------
62
63 # ...general
64 Requires: gtksourceview
65 Requires: blas
66 # sundials will be statically linked
67
68 # ...pygtk
69 Requires: python >= 2.4
70 Requires: pygtk2 >= 2.6
71 Requires: pygtk2-libglade
72 Requires: python-matplotlib
73 Requires: numpy
74 Requires: ipython
75
76 # ...tcl/tk
77 Requires: xgraph >= 11
78 Requires: tcl >= 8.3
79 Requires: tk >= 8.3
80 Requires: tktable < 2.10, tktable >= 2.8
81
82 #------------------------------------------
83
84 Provides: ascend-gui
85
86 # for the moment we'll just make one big super-package, to keep things
87 # simple for end-users.
88
89 #%package -n ascend-python
90 #Version: 0.9.5.110
91 #Summary: PyGTK user interface for ASCEND
92 #Group: Applications/Engineering
93 #
94 #%description -n ascend-python
95 #PyGTK user interface for ASCEND. This is a new interface that follows GNOME
96 #human interface guidelines as closely as possible. It does not as yet provide
97 #access to all of the ASCEND functionality provided by the Tcl/Tk interface.
98 #
99 #%package -n ascend-tcltk
100 #Version: 0.9.5.110
101 #Summary: Tcl/Tk user interface for ASCEND
102 #Group: Applications/Engineering
103 #
104 #%description -n ascend-tcltk
105 #Tcl/Tk user interface for ASCEND. This is the original ASCEND IV interface
106 #and is a more complete and mature interface than the alternative PyGTK
107 #interface. Use this interface if you need to use ASCEND *.a4s files or other
108 #functionality not provided by the PyGTK interface.
109
110 %prep
111 %setup -q -n ascend-0.9.5.110
112
113 %build
114 scons %{_smp_mflags} DEFAULT_ASCENDLIBRARY=%{_datadir}/ascend/models \
115 INSTALL_ROOT=%{buildroot} \
116 INSTALL_PREFIX=%{_prefix} \
117 INSTALL_SHARE=%{_datadir} \
118 INSTALL_BIN=%{_bindir} \
119 INSTALL_INCLUDE=%{_includedir} \
120 WITH_SOLVERS=QRSLV,LSOD,CMSLV,IDA,LRSLV,CONOPT \
121 INSTALL_DOC=%{_docdir}/%{name}-%{version} \
122 WITH_DOC_BUILD=0 \
123 WITH_DOC_INSTALL=0 \
124 ABSOLUTE_PATHS=1 \
125 CC="%{?ccache} gcc" \
126 CXX="%{?ccache} g++" \
127 pygtk tcltk
128
129 %install
130 rm -rf %{buildroot}
131 scons %{_smp_mflags} install
132
133 # Install menu entry for PyGTK interface, gtksourceview syntax highlighting, and MIME definition
134 pushd pygtk/gnome
135 install -m 644 -D ascend.desktop %{buildroot}/%{_datadir}/applications/ascend.desktop
136 install -m 644 -D ascend.png %{buildroot}/%{_datadir}/icons/ascend-app.png
137 install -m 644 -D ascend.png %{buildroot}/%{_datadir}/icons/hicolor/64x64/ascend.png
138 install -m 644 -D ascend.xml %{buildroot}/%{_datadir}/mime/packages/ascend.xml
139 popd
140 pushd tools/gedit
141 install -m 644 -D ascend.lang %{buildroot}/%{_datadir}/gtksourceview-1.0/language-specs/ascend.lang
142 popd
143
144 # TODO...
145 #%__python -c 'from compileall import *; compile_dir("'$RPM_BUILD_ROOT'/%{python_sitelib}",10,"%{python_sitelib}")'
146 #%__python -O -c 'from compileall import *; compile_dir("'$RPM_BUILD_ROOT'/%{python_sitelib}",10,"%{python_sitelib}")'
147
148 # Install menu entry for Tcl/Tk interface
149 pushd tcltk/gnome
150 install -m 644 -D ascend4.desktop %{buildroot}/%{_datadir}/applications/ascend4.desktop
151 install -m 644 -D ascend4.png %{buildroot}/%{_datadir}/icons/ascend4-app.png
152 install -m 644 -D ascend4.png %{buildroot}/%{_datadir}/icons/hicolor/64x64/ascend4.png
153 popd
154
155 %clean
156 rm -rf %{buildroot}
157
158 %post
159 update-desktop-database
160 update-mime-database /usr/share/mime
161
162 %postun
163 update-desktop-database
164 update-mime-database /usr/share/mime
165
166 %files
167 %defattr(-, root, root)
168 %doc INSTALL.txt LICENSE.txt
169 %doc doc/book.pdf
170
171 %{_bindir}/ascend-config
172 %{_datadir}/ascend/models
173 %{_libdir}/libascend.so
174 %{_datadir}/mime/packages/ascend.xml
175 %{_datadir}/gtksourceview-1.0/language-specs/ascend.lang
176
177 # %package -n ascend-python
178 %{_bindir}/ascend
179 %{_datadir}/ascend/*.py
180 %{_datadir}/ascend/*.pyc
181 %{_datadir}/ascend/*.pyo
182 %{_datadir}/ascend/glade
183 %{_datadir}/ascend/_ascpy.so
184 %{_datadir}/applications/ascend.desktop
185 %{_datadir}/icons/ascend-app.png
186 %{_datadir}/icons/hicolor/64x64/ascend.png
187
188 # %package -n ascend-tcltk
189 %{_bindir}/ascend4
190 %{_datadir}/ascend/tcltk
191 %{_libdir}/libascendtcl.so
192 %{_datadir}/applications/ascend4.desktop
193 %{_datadir}/icons/ascend4-app.png
194 %{_datadir}/icons/hicolor/64x64/ascend4.png
195
196 # %package -b ascend-devel
197 %{_includedir}/compiler
198 %{_includedir}/general
199 %{_includedir}/utilities
200 %{_includedir}/solver
201 %{_includedir}/linear
202 %{_includedir}/integrator
203 %{_includedir}/system
204
205 %changelog
206 * Mon Apr 23 2007 John Pye <john.pye@student.unsw.edu.au> 0.9.5.108
207 - File ascend.lang has moved.
208 - book.pdf is included in package.
209 - some header files have been moved.
210
211 * Fri Jul 28 2006 John Pye <john.pye@student.unsw.edu.au>
212 - Added CONOPT support
213
214 * Wed Jul 12 2006 John Pye <john.pye@student.unsw.edu.au>
215 - Fixed fortran linking
216 - Removed ccache dependency
217 - Added xgraph dependency
218 - Added 'include' files plus 'ascend-config' script
219
220 * Thu Jun 01 2006 John Pye <john.pye@student.unsw.edu.au>
221 - Add Tcl/Tk interface to GNOME menu
222
223 * Tue May 02 2006 John Pye <john.pye@student.unsw.edu.au>
224 - Break out ascend-core, ascend-python and ascend-tcltk packages.
225
226 * Mon Apr 24 2006 John Pye <john.pye@student.unsw.edu.au>
227 - Modified for removed dir in pygtk source hierachy
228
229 * Thu Apr 04 2006 John Pye <john.pye@student.unsw.edu.au>
230 - First RPM package for new SCons build

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22