]> git.pld-linux.org Git - packages/OpenCASCADE.git/blob - OpenCASCADE.spec
- avoid copying 50+k doc files for packaging
[packages/OpenCASCADE.git] / OpenCASCADE.spec
1 #
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
11 Summary:        OpenCASCADE CAE platform
12 Name:           OpenCASCADE
13 # The 6.3.1 is a maintenance release, only available for OCC customers
14 Version:        6.3.0
15 Release:         40.3
16 License:        LGPL-like, see http://www.opencascade.org/occ/license/
17 Group:          Applications/Engineering
18 Source0:        http://files.opencascade.com/OCC_6.3_release/%{name}_src.tgz
19 # Source0-md5:  52778127974cb3141c2827f9d40d1f11
20 Patch0:         %{name}6.3.0-obs-check.patch
21 Patch1:         %{name}6.3.0-strcmp.patch
22 Patch2:          OpenCASCADE6.3.0-occ6.3.0.patch
23 Patch3:         %{name}6.3.0-casroot.patch
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
27 Patch8:         %{name}6.3.0-DESTDIR.patch
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
31 Patch14:         OpenCASCADE6.3.0-wok-install.patch
32 Patch15:         OpenCASCADE6.3.0-udlist.patch
33 Patch16:         OpenCASCADE6.3.0-WOKUnix_FDescr.patch
34 URL:            http://www.opencascade.org/
35 BuildRequires:  autoconf
36 BuildRequires:  automake
37 BuildRequires:  bison
38 BuildRequires:  flex
39 BuildRequires:  java-sun-jdk-base
40 BuildRequires:  libstdc++-devel
41 BuildRequires:  libtool
42 BuildRequires:  Mesa-libGLU-devel
43 BuildRequires:  tk-devel
44 BuildRequires:  xorg-lib-libX11-devel
45 BuildRequires:  xorg-lib-libXmu-devel
46 BuildRequires:  xorg-proto-xproto-devel
47 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
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
55 %package libs
56 Summary:        OpenCASCADE shared libraries
57 Group:          Libraries
58
59 %description libs
60 OpenCASCADE shared libraries.
61
62 %package devel
63 Summary:        OpenCASCADE development files
64 Group:          Development/Libraries
65 Requires:       %{name}-libs = %{version}-%{release}
66
67 %description devel
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
77 %prep
78 %setup -q -n %{name}%{version}
79 %patch0 -p1
80 %patch1 -p1
81 %patch2 -p1
82 %patch3 -p1
83 %patch5 -p1
84 %patch6 -p1
85 %patch7 -p1
86 %patch8 -p1
87 %patch9 -p1
88 %patch10 -p1
89 %patch11 -p1
90 %patch14 -p1
91 %patch15 -p1
92 %patch16 -p1
93 cd ros/src/ExprIntrp
94 bison -d -p ExprIntrp -o ExprIntrp.tab.c ExprIntrp.yacc
95 flex -L -8 -Cf -Cr -P ExprIntrp -o lex.ExprIntrp.c ExprIntrp.lex
96 mv ExprIntrp.tab.h ../../inc/
97 cp ExprIntrp.tab.c lex.ExprIntrp.c ../../drv/ExprIntrp/
98
99 %build
100 cd ros
101 %{__libtoolize}
102 %{__aclocal}
103 %{__autoconf}
104 %{__autoheader}
105 %{__automake}
106
107 %ifarch x86_64 ppc64
108 export CFLAGS="%{rpmcflags} -D_OCC64 -fno-strict-aliasing"
109 export CXXFLAGS="%{rpmcflags} -D_OCC64 -fno-strict-aliasing"
110 %else
111 export CFLAGS="%{rpmcflags} -fno-strict-aliasing"
112 export CXXFLAGS="%{rpmcflags} -fno-strict-aliasing"
113 %endif
114 LDFLAGS=-lpthread %configure \
115         %{?debug:--disable-production  --enable-debug} \
116         %{!?debug:--enable-production --disable-debug} \
117         --with-java-include="%{java_home}"/include
118
119 %{__make}
120
121 %install
122 rm -rf $RPM_BUILD_ROOT
123 install -d $RPM_BUILD_ROOT{%{_datadir},%{_includedir}}
124
125 cd ros
126 %{__make} install \
127         DESTDIR=$RPM_BUILD_ROOT
128 cd ..
129
130 cp -a data $RPM_BUILD_ROOT%{_datadir}/%{name}
131 mkdir -p doc-i
132 [ -d doc ] && mv doc doc-i/%{name}-%{version}
133 ln -s %{_builddir}/%{name}%{version}/doc-i $RPM_BUILD_ROOT%{_defaultdocdir}
134 cp -a samples %{buildroot}%{_prefix}/
135
136 mv $RPM_BUILD_ROOT{%{_prefix}/src,%{_datadir}/%{name}}
137 mv $RPM_BUILD_ROOT{%{_prefix}/inc,%{_includedir}/%{name}}
138 rm -r $RPM_BUILD_ROOT%{_prefix}/{Linux,lin}
139
140 %post   -p /sbin/ldconfig
141 %postun -p /sbin/ldconfig
142
143 %clean
144 rm -rf $RPM_BUILD_ROOT
145
146 %files
147 %defattr(644,root,root,755)
148 %attr(755,root,root) %{_bindir}/DRAWEXE
149 %attr(755,root,root) %{_bindir}/wok*
150 %{_datadir}/%{name}
151
152 %files libs
153 %defattr(644,root,root,755)
154 %attr(755,root,root) %{_libdir}/*.so.*.*.*
155 %attr(755,root,root) %ghost %{_libdir}/*.so.0
156
157 %dir %{_prefix}/wok
158 %dir %{_prefix}/wok/lib/
159 %dir %{_prefix}/wok/site/
160 %dir %{_prefix}/data
161 %dir %{_prefix}/doc
162 %{_prefix}/data/*
163 %{_prefix}/doc/*
164 %{_prefix}/wok/lib/*
165 %{_prefix}/wok/site/*
166 %{_prefix}/config.h
167 %{_prefix}/env_DRAW.sh
168 %dir %{_prefix}/src/UnitsAPI
169 %dir %{_prefix}/src
170 %{_prefix}/src/UnitsAPI/*.dat
171
172 %files devel
173 %defattr(644,root,root,755)
174 %{_includedir}/%{name}
175 %{_libdir}/*.la
176 %attr(755,root,root) %{_libdir}/*.so
177
178 %files doc
179 %{_docdir}/%{name}-%{version}
180
181 %dir %{_prefix}/src/
182 %{_prefix}/src/*
183 %dir %{_prefix}/samples
184 %{_prefix}/samples/*
185 %exclude %{_prefix}/src/UnitsAPI/*.dat
This page took 0.076527 seconds and 4 git commands to generate.