]>
Commit | Line | Data |
---|---|---|
ab499437 | 1 | # |
ab499437 TP |
2 | # All modifications and additions to the file contributed by third parties |
3 | # remain the property of their copyright owners, unless otherwise agreed | |
4 | # upon. The license for this file, and modifications and additions to the | |
5 | # file, is the same license as for the pristine package itself (unless the | |
6 | # license for the pristine package is not an Open Source License, in which | |
7 | # case the license is the MIT License). An "Open Source License" is a | |
8 | # license that conforms to the Open Source Definition (Version 1.9) | |
9 | # published by the Open Source Initiative. | |
10 | ||
211fd830 | 11 | Summary: OpenCASCADE CAE platform |
9d815b70 | 12 | Name: OpenCASCADE |
211fd830 TP |
13 | # The 6.3.1 is a maintenance release, only available for OCC customers |
14 | Version: 6.3.0 | |
ab499437 | 15 | Release: 40.3 |
211fd830 | 16 | License: LGPL-like, see http://www.opencascade.org/occ/license/ |
b22968e0 | 17 | Group: Applications/Engineering |
211fd830 TP |
18 | Source0: http://files.opencascade.com/OCC_6.3_release/%{name}_src.tgz |
19 | # Source0-md5: 52778127974cb3141c2827f9d40d1f11 | |
9d815b70 TP |
20 | Patch0: %{name}6.3.0-obs-check.patch |
21 | Patch1: %{name}6.3.0-strcmp.patch | |
ab499437 | 22 | Patch2: OpenCASCADE6.3.0-occ6.3.0.patch |
49bdbc8a | 23 | Patch3: %{name}6.3.0-casroot.patch |
ab499437 TP |
24 | Patch5: OpenCASCADE6.3.0-tkernel-ld.patch |
25 | Patch6: OpenCASCADE6.3.0-mft-disable-mmap.patch | |
26 | Patch7: OpenCASCADE6.3.0-no-bitmaps-icon.patch | |
61b2b43f | 27 | Patch8: %{name}6.3.0-DESTDIR.patch |
ab499437 TP |
28 | Patch9: OpenCASCADE6.3.0-maint-mode.patch |
29 | Patch10: OpenCASCADE6.3.0-dep-libs.patch | |
30 | Patch11: OpenCASCADE6.3.0-move-vrml-vis.patch | |
ab499437 TP |
31 | Patch14: OpenCASCADE6.3.0-wok-install.patch |
32 | Patch15: OpenCASCADE6.3.0-udlist.patch | |
33 | Patch16: OpenCASCADE6.3.0-WOKUnix_FDescr.patch | |
211fd830 | 34 | URL: http://www.opencascade.org/ |
61b2b43f TP |
35 | BuildRequires: autoconf |
36 | BuildRequires: automake | |
b22968e0 TP |
37 | BuildRequires: bison |
38 | BuildRequires: flex | |
869e1a31 | 39 | BuildRequires: java-sun-jdk-base |
61b2b43f TP |
40 | BuildRequires: libstdc++-devel |
41 | BuildRequires: libtool | |
42 | BuildRequires: Mesa-libGLU-devel | |
869e1a31 | 43 | BuildRequires: tk-devel |
61b2b43f TP |
44 | BuildRequires: xorg-lib-libX11-devel |
45 | BuildRequires: xorg-lib-libXmu-devel | |
46 | BuildRequires: xorg-proto-xproto-devel | |
9d815b70 | 47 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
ab499437 TP |
48 | |
49 | %description | |
50 | OpenCASCADE is a suite for 3D surface and solid modeling, visualization, data | |
51 | exchange and rapid application development. It is an excellent platform for | |
52 | development of numerical simulation software including CAD/CAM/CAE, AEC and | |
53 | GIS, as well as PDM applications. | |
54 | ||
b22968e0 TP |
55 | %package libs |
56 | Summary: OpenCASCADE shared libraries | |
57 | Group: Libraries | |
58 | ||
59 | %description libs | |
60 | OpenCASCADE shared libraries. | |
61 | ||
ab499437 | 62 | %package devel |
b22968e0 TP |
63 | Summary: OpenCASCADE development files |
64 | Group: Development/Libraries | |
65 | Requires: %{name}-libs = %{version}-%{release} | |
ab499437 TP |
66 | |
67 | %description devel | |
b22968e0 TP |
68 | OpenCASCADE development files. |
69 | ||
70 | %package doc | |
71 | Summary: OpenCASCADE documentation | |
72 | Group: Documentation | |
73 | ||
74 | %description doc | |
75 | OpenCASCADE help and html documentation. | |
76 | ||
fce55032 TP |
77 | %package samples |
78 | Summary: OpenCASCADE samples | |
79 | Group: Documentation | |
80 | ||
81 | %description samples | |
82 | OpenCASCADE samples. | |
83 | ||
ab499437 TP |
84 | %prep |
85 | %setup -q -n %{name}%{version} | |
ab499437 TP |
86 | %patch0 -p1 |
87 | %patch1 -p1 | |
88 | %patch2 -p1 | |
89 | %patch3 -p1 | |
ab499437 TP |
90 | %patch5 -p1 |
91 | %patch6 -p1 | |
92 | %patch7 -p1 | |
93 | %patch8 -p1 | |
94 | %patch9 -p1 | |
95 | %patch10 -p1 | |
96 | %patch11 -p1 | |
ab499437 TP |
97 | %patch14 -p1 |
98 | %patch15 -p1 | |
99 | %patch16 -p1 | |
b22968e0 TP |
100 | cd ros/src/ExprIntrp |
101 | bison -d -p ExprIntrp -o ExprIntrp.tab.c ExprIntrp.yacc | |
102 | flex -L -8 -Cf -Cr -P ExprIntrp -o lex.ExprIntrp.c ExprIntrp.lex | |
103 | mv ExprIntrp.tab.h ../../inc/ | |
104 | cp ExprIntrp.tab.c lex.ExprIntrp.c ../../drv/ExprIntrp/ | |
ab499437 TP |
105 | |
106 | %build | |
9d815b70 TP |
107 | cd ros |
108 | %{__libtoolize} | |
5e4cb3c9 | 109 | %{__aclocal} |
9d815b70 TP |
110 | %{__autoconf} |
111 | %{__autoheader} | |
112 | %{__automake} | |
113 | ||
ab499437 | 114 | %ifarch x86_64 ppc64 |
b22968e0 TP |
115 | export CFLAGS="%{rpmcflags} -D_OCC64 -fno-strict-aliasing" |
116 | export CXXFLAGS="%{rpmcflags} -D_OCC64 -fno-strict-aliasing" | |
ab499437 | 117 | %else |
b22968e0 TP |
118 | export CFLAGS="%{rpmcflags} -fno-strict-aliasing" |
119 | export CXXFLAGS="%{rpmcflags} -fno-strict-aliasing" | |
ab499437 | 120 | %endif |
ab499437 | 121 | LDFLAGS=-lpthread %configure \ |
0ad19400 TP |
122 | %{?debug:--disable-production --enable-debug} \ |
123 | %{!?debug:--enable-production --disable-debug} \ | |
b22968e0 | 124 | --with-java-include="%{java_home}"/include |
ab499437 | 125 | |
cdf0b2d4 | 126 | %{__make} |
ab499437 TP |
127 | |
128 | %install | |
cdf0b2d4 | 129 | rm -rf $RPM_BUILD_ROOT |
fce55032 | 130 | install -d $RPM_BUILD_ROOT{%{_datadir},%{_includedir},%{_usrsrc}} |
61b2b43f | 131 | |
ab499437 | 132 | cd ros |
61b2b43f TP |
133 | %{__make} install \ |
134 | DESTDIR=$RPM_BUILD_ROOT | |
ab499437 | 135 | cd .. |
b22968e0 TP |
136 | |
137 | cp -a data $RPM_BUILD_ROOT%{_datadir}/%{name} | |
49bdbc8a | 138 | mv $RPM_BUILD_ROOT{%{_prefix}/src,%{_datadir}/%{name}} |
3c55ead9 TP |
139 | mv $RPM_BUILD_ROOT{%{_prefix}/inc,%{_includedir}/%{name}} |
140 | rm -r $RPM_BUILD_ROOT%{_prefix}/{Linux,lin} | |
141 | ||
fce55032 TP |
142 | for i in doc samples; do |
143 | mkdir -p $i-i | |
144 | [ -d $i ] && mv $i $i-i/%{name}-%{version} || : | |
145 | done | |
146 | ln -s %{_builddir}/%{name}%{version}/doc-i $RPM_BUILD_ROOT%{_defaultdocdir} | |
147 | ln -s %{_builddir}/%{name}%{version}/samples-i $RPM_BUILD_ROOT%{_examplesdir} | |
148 | ||
cdf0b2d4 | 149 | %post -p /sbin/ldconfig |
ab499437 TP |
150 | %postun -p /sbin/ldconfig |
151 | ||
152 | %clean | |
cdf0b2d4 | 153 | rm -rf $RPM_BUILD_ROOT |
ab499437 TP |
154 | |
155 | %files | |
cdf0b2d4 | 156 | %defattr(644,root,root,755) |
3c55ead9 TP |
157 | %attr(755,root,root) %{_bindir}/DRAWEXE |
158 | %attr(755,root,root) %{_bindir}/wok* | |
49bdbc8a | 159 | %{_datadir}/%{name} |
3c55ead9 TP |
160 | |
161 | %files libs | |
162 | %defattr(644,root,root,755) | |
163 | %attr(755,root,root) %{_libdir}/*.so.*.*.* | |
164 | %attr(755,root,root) %ghost %{_libdir}/*.so.0 | |
165 | ||
ab499437 TP |
166 | %dir %{_prefix}/wok |
167 | %dir %{_prefix}/wok/lib/ | |
168 | %dir %{_prefix}/wok/site/ | |
169 | %dir %{_prefix}/data | |
ab499437 | 170 | %{_prefix}/data/* |
ab499437 TP |
171 | %{_prefix}/wok/lib/* |
172 | %{_prefix}/wok/site/* | |
173 | %{_prefix}/config.h | |
174 | %{_prefix}/env_DRAW.sh | |
ab499437 TP |
175 | %dir %{_prefix}/src/UnitsAPI |
176 | %dir %{_prefix}/src | |
177 | %{_prefix}/src/UnitsAPI/*.dat | |
178 | ||
179 | %files devel | |
cdf0b2d4 | 180 | %defattr(644,root,root,755) |
3c55ead9 | 181 | %{_includedir}/%{name} |
ab499437 | 182 | %{_libdir}/*.la |
3c55ead9 TP |
183 | %attr(755,root,root) %{_libdir}/*.so |
184 | ||
ab499437 TP |
185 | %dir %{_prefix}/src/ |
186 | %{_prefix}/src/* | |
ab499437 | 187 | %exclude %{_prefix}/src/UnitsAPI/*.dat |
fce55032 TP |
188 | |
189 | %files doc | |
190 | %{_docdir}/%{name}-%{version} | |
191 | ||
192 | %files samples | |
193 | %{_examplesdir}/%{name}-%{version} |