c6a872b7fce2a56599230bbc36a62faea04fc87e
[packages/blender.git] / blender.spec
1 # TODO:
2 # - enable internalization support (BR libftgl)
3 # - libsolid/libqhull/libode BR ?
4 Summary:        3D modeling, rendering, animation and game creation package
5 Summary(pl.UTF-8):      Pakiet do tworzenia animacji 3D oraz gier
6 Name:           blender
7 Version:        2.82a
8 Release:        1
9 License:        GPL
10 Group:          X11/Applications/Graphics
11 Source0:        http://download.blender.org/source/%{name}-%{version}.tar.xz
12 # Source0-md5:  3e9d669185b83d5d2cb1b38dcf64d5ec
13 Patch0:         %{name}-2.76-droid.patch
14 Patch1:         format-security.patch
15 Patch3:         struct-alignment.patch
16 URL:            http://www.blender.org/
17 BuildRequires:  OpenAL-devel
18 BuildRequires:  OpenColorIO-devel
19 BuildRequires:  OpenEXR-devel
20 BuildRequires:  OpenGL-devel
21 BuildRequires:  OpenGL-GLU-devel
22 BuildRequires:  OpenImageIO-devel
23 BuildRequires:  SDL2-devel
24 BuildRequires:  boost-devel
25 BuildRequires:  cmake
26 BuildRequires:  ffmpeg-devel >= 0.4.9-4.20080930.1
27 BuildRequires:  fftw3-devel
28 BuildRequires:  freealut-devel
29 BuildRequires:  freetype-devel
30 BuildRequires:  ftgl-devel
31 BuildRequires:  gcc >= 5:3.4.0
32 BuildRequires:  gettext-tools
33 BuildRequires:  glew-devel
34 BuildRequires:  jack-audio-connection-kit-devel
35 BuildRequires:  jemalloc-devel
36 BuildRequires:  libjpeg-devel
37 BuildRequires:  libpng-devel
38 BuildRequires:  libsndfile-devel
39 BuildRequires:  libspnav-devel
40 BuildRequires:  libstdc++-devel
41 BuildRequires:  libtiff-devel
42 BuildRequires:  libtool
43 BuildRequires:  libvorbis-devel
44 BuildRequires:  openjpeg2-devel
45 BuildRequires:  openssl-devel >= 0.9.7d
46 BuildRequires:  pugixml-devel
47 BuildRequires:  python3
48 BuildRequires:  python3-devel
49 BuildRequires:  python3-numpy-devel
50 BuildRequires:  rpm-pythonprov
51 BuildRequires:  rpmbuild(macros) >= 1.385
52 BuildRequires:  sed >= 4.0
53 BuildRequires:  xorg-lib-libXi-devel
54 BuildRequires:  zlib-devel
55 Requires(post,postun):  desktop-file-utils
56 Requires:       OpenGL
57 Requires:       freetype
58 Requires:       python3-modules
59 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
60
61 %define         _noautoreqdep   libGL.so.1 libGLU.so.1
62
63 %description
64 Blender is a free and fully functional 3D modeling, rendering,
65 animation and game creation package for Unix, Windows and BeOS
66 systems.
67
68 %description -l pl.UTF-8
69 Blender to darmowy i w pełni funkcjonalny pakiet do tworzenia animacji
70 3D oraz gier, dostępny dla systemów Unix, Windows i BeOS.
71
72 %prep
73 %setup -q
74 %patch0 -p1
75 %patch1 -p1
76 %ifarch x32
77 %patch3 -p1
78 %endif
79
80 %{__sed} -E -i -e '1s,#!\s*/usr/bin/env\s+python(\s|$),#!%{__python3}\1,' -e '1s,#!\s*/usr/bin/env\s+python3(\s|$),#!%{__python3}\1,' \
81       release/bin/blender-thumbnailer.py \
82       release/scripts/addons/io_curve_svg/svg_util_test.py \
83       release/scripts/addons/io_scene_fbx/fbx2json.py \
84       release/scripts/addons/io_scene_fbx/json2fbx.py \
85       release/scripts/addons/sun_position/geo.py \
86       release/scripts/modules/bl_i18n_utils/merge_po.py \
87       release/scripts/modules/bl_i18n_utils/utils_rtl.py \
88       release/scripts/modules/blend_render_info.py
89
90 %build
91 install -d build
92 cd build
93 %cmake \
94         -DCMAKE_SKIP_RPATH:BOOL=ON \
95         -DBUILD_SHARED_LIBS:BOOL=OFF \
96         -DWITH_FFTW3:BOOL=ON \
97         -DWITH_JACK:BOOL=ON \
98         -DWITH_JACK_DYNLOAD:BOOL=ON \
99         -DWITH_CODEC_SNDFILE:BOOL=ON \
100         -DWITH_IMAGE_OPENJPEG:BOOL=ON \
101         -DWITH_OPENCOLLADA:BOOL=ON \
102         -DWITH_OPENCOLORIO:BOOL=ON \
103         -DWITH_CYCLES:BOOL=ON \
104         -DWITH_FFTW3:BOOL=ON \
105         -DWITH_MOD_OCEANSIM:BOOL=ON \
106         -DOPENCOLLADA=%{_includedir} \
107         -DWITH_PYTHON:BOOL=ON \
108         -DPYTHON_VERSION:STRING=%{py3_ver} \
109         -DWITH_PYTHON_INSTALL:BOOL=OFF \
110         -DWITH_CODEC_FFMPEG:BOOL=ON \
111         -DWITH_GAMEENGINE:BOOL=ON \
112         -DWITH_CXX_GUARDEDALLOC:BOOL=OFF \
113         -DWITH_INSTALL_PORTABLE:BOOL=OFF \
114         -DWITH_PYTHON_SAFETY:BOOL=ON \
115         -DWITH_PLAYER:BOOL=ON \
116         -DWITH_MEM_JEMALLOC:BOOL=ON \
117         -DWITH_SYSTEM_GLEW:BOOL=ON \
118         -DBOOST_ROOT=%{_prefix} \
119         -DWITH_INPUT_NDOF:BOOL=ON \
120         -DWITH_SDL:BOOL=ON \
121         -DWITH_SDL_DYNLOAD:BOOL=ON \
122         ..
123
124 %{__make} V=1
125
126 %install
127 rm -rf $RPM_BUILD_ROOT
128
129 install -d $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir},%{_mandir}/man1}
130
131 %{__make} -C build install \
132         DESTDIR=$RPM_BUILD_ROOT
133
134 ./doc/manpage/blender.1.py $RPM_BUILD_ROOT%{_bindir}/blender $RPM_BUILD_ROOT%{_mandir}/man1/blender.1
135
136 #%find_lang %{name}
137
138 %clean
139 rm -rf $RPM_BUILD_ROOT
140
141 %post
142 %update_desktop_database_post
143
144 %postun
145 %update_desktop_database_postun
146
147 %files
148 %defattr(644,root,root,755)
149 # -f %{name}.lang
150 %doc doc/license/bf-members.txt doc/guides/*.txt
151 %attr(755,root,root) %{_bindir}/blender
152 %attr(755,root,root) %{_bindir}/blender-thumbnailer.py
153 %attr(755,root,root) %{_datadir}/%{name}
154 %{_desktopdir}/*.desktop
155 %{_iconsdir}/hicolor/scalable/apps/blender.svg
156 %{_iconsdir}/hicolor/symbolic/apps/blender-symbolic.svg
157 %{_mandir}/man1/*
This page took 0.064178 seconds and 2 git commands to generate.