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.
11 %define _prefix /opt/OpenCASCADE
13 Summary: OpenCASCADE CAE platform
15 Group: Productivity/Other
16 # The 6.3.1 is a maintenance release, only available for OCC customers
19 License: LGPL-like, see http://www.opencascade.org/occ/license/
20 Packager: Andrea Florio <andrea@opensuse.org>
21 Source0: http://files.opencascade.com/OCC_6.3_release/%{name}_src.tgz
22 # Source0-md5: 52778127974cb3141c2827f9d40d1f11
24 Source2: OpenCASCADE-rpmlintrc
25 Patch0: %{name}6.3.0-obs-check.patch
26 Patch1: %{name}6.3.0-strcmp.patch
27 Patch2: OpenCASCADE6.3.0-occ6.3.0.patch
28 Patch3: OpenCASCADE6.3.0-casroot.patch
29 Patch4: OpenCASCADE6.3.0-lib-release.patch
30 Patch5: OpenCASCADE6.3.0-tkernel-ld.patch
31 Patch6: OpenCASCADE6.3.0-mft-disable-mmap.patch
32 Patch7: OpenCASCADE6.3.0-no-bitmaps-icon.patch
33 Patch8: OpenCASCADE6.3.0-DESTDIR.patch
34 Patch9: OpenCASCADE6.3.0-maint-mode.patch
35 Patch10: OpenCASCADE6.3.0-dep-libs.patch
36 Patch11: OpenCASCADE6.3.0-move-vrml-vis.patch
37 Patch12: OpenCASCADE6.3.0-make-wok-libs-private.patch
38 Patch13: OpenCASCADE6.3.0-make-draw-libs-private.patch
39 Patch14: OpenCASCADE6.3.0-wok-install.patch
40 Patch15: OpenCASCADE6.3.0-udlist.patch
41 Patch16: OpenCASCADE6.3.0-WOKUnix_FDescr.patch
42 URL: http://www.opencascade.org/
44 BuildRequires: Mesa-devel autoconf automake bison gcc-c++ xorg-x11-devel
45 BuildRequires: flex libtool tcl-devel tk-devel xorg-x11-libXmu-devel fdupes
49 BuildRequires: compat-32bit
51 BuildRequires: java-1_5_0-gcj-compat-devel
53 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
56 OpenCASCADE is a suite for 3D surface and solid modeling, visualization, data
57 exchange and rapid application development. It is an excellent platform for
58 development of numerical simulation software including CAD/CAM/CAE, AEC and
59 GIS, as well as PDM applications.
62 Group: Development/Libraries/C and C++
63 Summary: Devel package for %{name}
64 Requires: %{name} = %{version}
67 OpenCASCADE is a suite for 3D surface and solid modeling, visualization, data
68 exchange and rapid application development. It is an excellent platform for
69 development of numerical simulation software including CAD/CAM/CAE, AEC and
70 GIS, as well as PDM applications.
73 %setup -q -n %{name}%{version}
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/
107 export CFLAGS="$RPM_OPT_FLAGS -D_OCC64 -fno-strict-aliasing"
108 export CXXFLAGS="$RPM_OPT_FLAGS -D_OCC64 -fno-strict-aliasing"
110 export CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing"
111 export CXXFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing"
113 LDFLAGS=-lpthread %configure \
114 --with-gl-include=/usr/include \
115 --with-gl-library=/usr/%{_lib} \
116 --with-xmu-include=/usr/include/X11 \
117 --with-xmu-library=/usr/%{_lib} \
118 --with-tcl=/usr/%{_lib} \
119 --with-tk=/usr/%{_lib} \
122 --enable-production \
130 rm -rf $RPM_BUILD_ROOT
135 cp -a data %{buildroot}%{_prefix}/
136 cp -a doc %{buildroot}%{_prefix}/
137 cp -a samples %{buildroot}%{_prefix}/
140 %__ln_s %{_libdir} %{buildroot}/%{_prefix}/Linux/lib
141 %__ln_s %{_libdir} %{buildroot}/%{_prefix}/lin/lib
144 # add symlinks for compatibility resons
145 %__mkdir -p %{buildroot}/usr/share/opencascade/
146 %__mkdir -p %{buildroot}/usr/include/
147 %__mkdir -p %{buildroot}/usr/share/doc/packages/
148 %__mkdir -p %{buildroot}/usr/%{_lib}
150 %__ln_s %{_prefix} %{buildroot}/usr/share/opencascade/%{version}
151 %__ln_s %{_prefix}/inc %{buildroot}/usr/include/opencascade
152 %__ln_s %{_prefix}/doc %{buildroot}/usr/share/doc/packages/opencascade
153 `for i in $(ls %{buildroot}/%{_libdir}); do %__ln_s %{_libdir}/$i %{buildroot}/usr/%{_lib}/$i; done`
155 %__mkdir -p %buildroot/etc/ld.so.conf.d/
156 %__cp %SOURCE1 %buildroot/etc/ld.so.conf.d/
158 %post -p /sbin/ldconfig
159 %postun -p /sbin/ldconfig
162 rm -rf $RPM_BUILD_ROOT
165 %defattr(644,root,root,755)
169 %dir %{_prefix}/Linux
171 %dir %{_prefix}/wok/lib/
172 %dir %{_prefix}/wok/site/
176 %dir %{_libdir}/opencas/
177 %dir /usr/share/opencascade/
179 %{_bindir}/wokprocess
188 %{_prefix}/wok/site/*
190 %{_prefix}/env_DRAW.sh
192 %{_libdir}/opencas/*.so
194 /usr/share/opencascade/%{version}
195 /usr/share/doc/packages/opencascade
196 %config /etc/ld.so.conf.d/%name.conf
197 %dir %{_prefix}/src/UnitsAPI
199 %{_prefix}/src/UnitsAPI/*.dat
202 %defattr(644,root,root,755)
203 %dir /usr/include/opencascade/
205 %{_libdir}/opencas/*.la
210 %dir %{_prefix}/samples
212 %exclude %{_prefix}/src/UnitsAPI/*.dat