]> git.pld-linux.org Git - packages/X11-driver-firegl.git/blame - X11-driver-firegl.spec
- tabs in preamble
[packages/X11-driver-firegl.git] / X11-driver-firegl.spec
CommitLineData
73f83a82 1#
2# Conditional build:
65666b9f 3%bcond_without dist_kernel # without distribution kernel
56f8b0b0 4%bcond_without kernel # don't build kernel modules
de505e65 5%bcond_without smp # don't build SMP module
56f8b0b0 6%bcond_without userspace # don't build userspace tools
de505e65 7%bcond_with verbose # verbose build (V=1)
2aa20f95 8%bcond_without incall # include all sources in srpm
6cec6fba 9%bcond_with grsec_kernel # build for kernel-grsecurity
10#
9a8b5c18 11%if !%{with kernel}
37862d70 12%undefine with_dist_kernel
13%endif
6cec6fba 14#
15%if %{with kernel} && %{with dist_kernel} && %{with grsec_kernel}
16%define alt_kernel grsecurity
17%endif
18#
19%define _min_eq_x11 1:6.9.0
20%define _max_x11 1:7.0.0
21%define x11ver x690
37862d70 22
935ce2f3 23%ifarch %{ix86}
674278d1 24%define arch_sufix ""
25%define arch_dir x86
2aa20f95 26%else
42ab2c5b 27%define arch_sufix _64a
674278d1 28%define arch_dir x86_64
2aa20f95
PZ
29%endif
30
6cec6fba 31%define _rel 1
73f83a82 32Summary: Linux Drivers for ATI graphics accelerators
6ec2f123 33Summary(pl.UTF-8): Sterowniki do akceleratorów graficznych ATI
21b4bb90 34Name: X11-driver-firegl
58249301 35Version: 8.33.6
ec3d3e05 36Release: %{_rel}
3b871561 37License: ATI Binary (parts are GPL)
42ab2c5b 38Group: X11
d0c301b5 39Source0: http://www2.ati.com/drivers/linux/ati-driver-installer-%{version}-x86.x86_64.run
58249301 40# Source0-md5: 5fbd42d666d467a904acbaeb600c1d5a
54d5ebd9 41Patch0: firegl-panel.patch
44f1fe6d 42Patch1: firegl-panel-ugliness.patch
2ad3dd01 43Patch2: %{name}-kh.patch
44Patch3: %{name}-viak8t.patch
d6783586 45Patch4: %{name}-force-define-AGP.patch
d0c301b5 46URL: http://ati.amd.com/support/drivers/linux/linux-radeon.html
42ab2c5b 47#BuildRequires: X11-devel >= %{_min_eq_x11} # disabled for now
909a7a21 48%{?with_dist_kernel:BuildRequires: kernel%{_alt_kernel}-module-build >= 3:2.6.14}
6ad30d21 49%{?with_userspace:BuildRequires: qt-devel}
a3a376da 50BuildRequires: rpmbuild(macros) >= 1.330
9e00e8f6 51Requires: X11-OpenGL-core >= %{_min_eq_x11}
c8bdf4d6 52Requires: X11-Xserver
2ad3dd01 53%{?with_kernel:Requires: X11-driver-firegl(kernel)}
9e00e8f6 54Requires: X11-libs < %{_max_x11}
42ab2c5b 55Requires: X11-libs >= %{_min_eq_x11}
9e00e8f6 56Requires: X11-modules < %{_max_x11}
42ab2c5b 57Requires: X11-modules >= %{_min_eq_x11}
4aa9a663 58Provides: X11-OpenGL-libGL
65666b9f 59Provides: XFree86-OpenGL-libGL
8d7b5ede 60Obsoletes: Mesa
21b4bb90 61Obsoletes: X11-OpenGL-libGL
8d7b5ede 62Obsoletes: XFree86-OpenGL-libGL
21b4bb90 63Obsoletes: XFree86-driver-firegl
06d82cec 64ExclusiveArch: i586 i686 athlon pentium3 pentium4 %{x8664}
b0e61c0f
AM
65BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
66
ea373867 67%define _ccver %(rpm -q --qf "%{VERSION}" gcc | sed 's/\\..*//')
bf7a2974 68
2d2f8d91 69%define _noautoreqdep libGL.so.1
b0e61c0f 70
b0e61c0f
AM
71%define _prefix /usr/X11R6
72%define _mandir %{_prefix}/man
b0e61c0f
AM
73
74%description
77e2079e
AM
75Display driver files for the ATI Radeon 8500, 9700, Mobility M9 and
76the FireGL 8700/8800, E1, Z1/X1 graphics accelerators. This package
77provides 2D display drivers and hardware accelerated OpenGL.
b0e61c0f 78
69025518 79%description -l pl.UTF-8
77e2079e 80Sterowniki do kart graficznych ATI Radeon 8500, 9700, Mobility M9 oraz
69025518
JR
81graficznych akceleratorów FireGL 8700/8800, E1, Z1/X1. Pakiet
82dostarcza sterowniki obsługujące wyświetlanie 2D oraz sprzętowo
666ae80e 83akcelerowany OpenGL.
b0e61c0f 84
909a7a21 85%package -n kernel%{_alt_kernel}-video-firegl
b0e61c0f 86Summary: ATI kernel module for FireGL support
6ec2f123 87Summary(pl.UTF-8): Moduł jądra oferujący wsparcie dla ATI FireGL
ec3d3e05 88Release: %{_rel}@%{_kernel_ver_str}
b0e61c0f 89License: ATI
b0e61c0f 90Group: Base/Kernel
65666b9f 91%{?with_dist_kernel:%requires_releq_kernel_up}
ff402db6 92Requires(post,postun): /sbin/depmod
fa80fc8a 93Provides: X11-driver-firegl(kernel)
b0e61c0f 94
909a7a21 95%description -n kernel%{_alt_kernel}-video-firegl
b0e61c0f
AM
96ATI kernel module for FireGL support.
97
69025518
JR
98%description -n kernel%{_alt_kernel}-video-firegl -l pl.UTF-8
99Moduł jądra oferujący wsparcie dla ATI FireGL.
b0e61c0f 100
909a7a21 101%package -n kernel%{_alt_kernel}-smp-video-firegl
074bf6e3 102Summary: ATI kernel module for FireGL support
6ec2f123 103Summary(pl.UTF-8): Moduł jądra oferujący wsparcie dla ATI FireGL
ec3d3e05 104Release: %{_rel}@%{_kernel_ver_str}
074bf6e3 105License: ATI
074bf6e3 106Group: Base/Kernel
65666b9f 107%{?with_dist_kernel:%requires_releq_kernel_smp}
074bf6e3 108Requires(post,postun): /sbin/depmod
fa80fc8a 109Provides: X11-driver-firegl(kernel)
074bf6e3 110
909a7a21 111%description -n kernel%{_alt_kernel}-smp-video-firegl
074bf6e3
PG
112ATI kernel module for FireGL support.
113
69025518
JR
114%description -n kernel%{_alt_kernel}-smp-video-firegl -l pl.UTF-8
115Moduł jądra oferujący wsparcie dla ATI FireGL.
074bf6e3 116
b0e61c0f 117%prep
77e2079e 118%setup -q -c -T
42ab2c5b 119
42ab2c5b 120sh %{SOURCE0} --extract .
42ab2c5b 121
674278d1 122cp arch/%{arch_dir}/lib/modules/fglrx/build_mod/* common/lib/modules/fglrx/build_mod
42ab2c5b 123
56f8b0b0 124install -d panel_src
cbe5572b 125tar -xzf common/usr/src/ati/fglrx_panel_sources.tgz -C panel_src
54d5ebd9 126%patch0 -p1
44f1fe6d 127%patch1 -p1
42ab2c5b 128cd common
2ad3dd01 129%{?with_dist_kernel:%patch2 -p1}
130%patch3 -p1
d6783586 131%patch4 -p2
42ab2c5b 132cd -
133
134install -d common%{_prefix}/{%{_lib},bin}
8dfcd94a
AM
135cp -r %{x11ver}%{arch_sufix}%{_prefix}/%{_lib}/* common%{_prefix}/%{_lib}
136cp -r %{x11ver}%{arch_sufix}%{_bindir}/* common%{_bindir}
674278d1 137cp -r arch/%{arch_dir}%{_prefix}/%{_lib}/* common%{_prefix}/%{_lib}
138cp -r arch/%{arch_dir}%{_bindir}/* common%{_bindir}
b0e61c0f
AM
139
140%build
56f8b0b0 141%if %{with kernel}
42ab2c5b 142cd common/lib/modules/fglrx/build_mod
54eab238 143cp -f 2.6.x/Makefile .
bf7a2974 144%build_kernel_modules -m fglrx GCC_VER_MAJ=%{_ccver}
de505e65 145cd -
56f8b0b0 146%endif
123d3a2e 147
56f8b0b0 148%if %{with userspace}
c5f71a31 149%{__make} -C panel_src \
ca7c1407
KK
150 C="%{__cc}" \
151 CC="%{__cxx}" \
c5f71a31
PS
152 CCFLAGS="%{rpmcflags} -DFGLRX_USE_XEXTENSIONS" \
153 MK_QTDIR=/usr \
154 LIBQT_DYN=qt-mt
56f8b0b0 155%endif
b0e61c0f
AM
156
157%install
158rm -rf $RPM_BUILD_ROOT
b0e61c0f 159
56f8b0b0 160%if %{with kernel}
addd07ab 161%install_kernel_modules -m common/lib/modules/fglrx/build_mod/fglrx -d misc
56f8b0b0
JB
162%endif
163
164%if %{with userspace}
165install -d $RPM_BUILD_ROOT{%{_bindir},%{_libdir},%{_includedir}/X11/extensions} \
166 $RPM_BUILD_ROOT/usr/{%{_lib},include/GL}
b0e61c0f 167
674278d1 168install common%{_bindir}/{fgl_glxgears,fglrxinfo,aticonfig} \
5e5f3f25 169 $RPM_BUILD_ROOT%{_bindir}
c5f71a31
PS
170install panel_src/fireglcontrol.qt3.gcc%(gcc -dumpversion) \
171 $RPM_BUILD_ROOT%{_bindir}/fireglcontrol
42ab2c5b 172cp -r common%{_prefix}/%{_lib}/* $RPM_BUILD_ROOT%{_libdir}
b0e61c0f 173
56f8b0b0
JB
174ln -sf libGL.so.1 $RPM_BUILD_ROOT%{_libdir}/libGL.so
175
176# OpenGL ABI for Linux compatibility
177ln -sf %{_libdir}/libGL.so.1 $RPM_BUILD_ROOT/usr/%{_lib}/libGL.so.1
178ln -sf %{_libdir}/libGL.so $RPM_BUILD_ROOT/usr/%{_lib}/libGL.so
179
42ab2c5b 180install common/usr/include/GL/*.h $RPM_BUILD_ROOT/usr/include/GL
181install common%{_includedir}/X11/extensions/*.h $RPM_BUILD_ROOT%{_includedir}/X11/extensions
56f8b0b0 182%endif
b0e61c0f
AM
183
184%clean
185rm -rf $RPM_BUILD_ROOT
186
187%post -p /sbin/ldconfig
188%postun -p /sbin/ldconfig
189
909a7a21 190%post -n kernel%{_alt_kernel}-video-firegl
65666b9f 191%depmod %{_kernel_ver}
b0e61c0f 192
909a7a21 193%postun -n kernel%{_alt_kernel}-video-firegl
65666b9f 194%depmod %{_kernel_ver}
b0e61c0f 195
909a7a21 196%post -n kernel%{_alt_kernel}-smp-video-firegl
65666b9f 197%depmod %{_kernel_ver}smp
074bf6e3 198
909a7a21 199%postun -n kernel%{_alt_kernel}-smp-video-firegl
65666b9f 200%depmod %{_kernel_ver}smp
074bf6e3 201
56f8b0b0 202%if %{with userspace}
b0e61c0f
AM
203%files
204%defattr(644,root,root,755)
b0e61c0f 205%attr(755,root,root) %{_bindir}/*
56f8b0b0
JB
206%attr(755,root,root) %{_libdir}/libGL.so.*.*
207%attr(755,root,root) %{_libdir}/libGL.so
674278d1 208%attr(755,root,root) %{_libdir}/libfglrx_dm.so.*.*
56f8b0b0 209%attr(755,root,root) %{_libdir}/libfglrx_gamma.so.*.*
29617f5d 210%attr(755,root,root) %{_libdir}/libfglrx_pp.so.*.*
56f8b0b0
JB
211# Linux OpenGL ABI compatibility symlinks
212%attr(755,root,root) /usr/%{_lib}/libGL.so.1
213%attr(755,root,root) /usr/%{_lib}/libGL.so
214
69afe35e 215%attr(755,root,root) %{_libdir}/modules/dri/atiogl_a_dri.so
56f8b0b0 216%attr(755,root,root) %{_libdir}/modules/dri/fglrx_dri.so
42ab2c5b 217%attr(755,root,root) %{_libdir}/modules/drivers/fglrx_drv.so
218%attr(755,root,root) %{_libdir}/modules/linux/libfglrxdrm.so
219%doc ATI_LICENSE.TXT common%{_docdir}/fglrx/*.html common%{_docdir}/fglrx/articles common%{_docdir}/fglrx/release-notes common%{_docdir}/fglrx/user-manual
56f8b0b0
JB
220
221# -devel
222#%attr(755,root,root) %{_libdir}/libfglrx_gamma.so
223#%{_includedir}/X11/include/libfglrx_gamma.h
a5669d3a 224#/usr/include/GL/glATI.h
56f8b0b0
JB
225#/usr/include/GL/glxATI.h
226
227# -static
228#%{_libdir}/libfglrx_gamma.a
a5669d3a 229#%{_libdir}/libfglrx_pp.a
56f8b0b0
JB
230%endif
231
232%if %{with kernel}
909a7a21 233%files -n kernel%{_alt_kernel}-video-firegl
b0e61c0f 234%defattr(644,root,root,755)
c894bed3 235/lib/modules/%{_kernel_ver}/misc/*.ko*
074bf6e3 236
bbc12abe 237%if %{with smp} && %{with dist_kernel}
909a7a21 238%files -n kernel%{_alt_kernel}-smp-video-firegl
074bf6e3 239%defattr(644,root,root,755)
c894bed3 240/lib/modules/%{_kernel_ver}smp/misc/*.ko*
56f8b0b0 241%endif
bbc12abe 242%endif
This page took 0.097143 seconds and 4 git commands to generate.