]> git.pld-linux.org Git - packages/X11-driver-firegl.git/blob - X11-driver-firegl.spec
- added (in theory) building of SMP module - to be tested...
[packages/X11-driver-firegl.git] / X11-driver-firegl.spec
1 #
2 # Conditional build:
3 # _without_dist_kernel
4 #
5
6 %define         _min_xfree      4.3.0
7
8 Summary:        Linux Drivers for ATI graphics accelerators
9 Summary(pl):    Sterowniki do akceleratorów graficznych ATI
10 Name:           XFree86-driver-firegl
11 Version:        3.2.8
12 Release:        1.5
13 License:        ATI Binary
14 Vendor:         ATI
15 Group:          X11/XFree86
16 Source0:        http://www2.ati.com/drivers/firegl/fglrx-glc22-%{_min_xfree}-%{version}.i586.rpm
17 # Source0-md5:  824aaaafd4b4867c2456860ea5eff5ec
18 Patch0:         firegl-panel.patch
19 Patch1:         XFree86-driver-firegl-kh.patch  
20 URL:            http://www.ati.com/support/drivers/linux/radeon-linux.html
21 BuildRequires:  cpio
22 %{!?_without_dist_kernel:BuildRequires:         kernel-headers >= 2.2.0 }
23 BuildRequires:  rpm-utils
24 Requires:       XFree86-Xserver
25 Requires:       XFree86-libs >= %{_min_xfree}
26 Requires:       XFree86-modules >= %{_min_xfree}
27 %{!?_without_dist_kernel:Requires:      kernel-video-firegl = %{version} }
28 Provides:       XFree86-OpenGL-core = %{_min_xfree}
29 Obsoletes:      Mesa
30 Obsoletes:      XFree86-OpenGL-libGL
31 Provides:       XFree86-OpenGL-libGL
32 ExclusiveArch:  i586 i686 athlon
33 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
34
35 %define         _noautoreqdep   libGL.so.1.2
36
37 %define         _prefix         /usr/X11R6
38 %define         _mandir         %{_prefix}/man
39
40 %description
41 Display driver files for the ATI Radeon 8500, 9700, Mobility M9 and
42 the FireGL 8700/8800, E1, Z1/X1 graphics accelerators. This package
43 provides 2D display drivers and hardware accelerated OpenGL.
44
45 %description -l pl
46 Sterowniki do kart graficznych ATI Radeon 8500, 9700, Mobility M9 oraz
47 graficznych akceleratorów FireGL 8700/8800, E1, Z1/X1. Pakiet
48 dostarcza sterowniki obs³uguj±ce wy¶wietlanie 2D oraz sprzêtowo
49 akcelerowany OpenGL.
50
51 %package -n kernel-video-firegl
52 Summary:        ATI kernel module for FireGL support
53 Summary(pl):    Modu³ j±dra oferuj±cy wsparcie dla ATI FireGL
54 Release:        %{release}@%{_kernel_ver_str}
55 License:        ATI
56 Vendor:         ATI
57 Group:          Base/Kernel
58 %{!?_without_dist_kernel:%requires_releq_kernel_up}
59 PreReq:         modutils >= 2.3.18-2
60 Requires(post,postun):  /sbin/depmod
61
62 %description -n kernel-video-firegl
63 ATI kernel module for FireGL support.
64
65 %description -n kernel-video-firegl -l pl
66 Modu³ j±dra oferuj±cy wsparcie dla ATI FireGL.
67
68 %package -n kernel-smp-video-firegl
69 Summary:        ATI kernel module for FireGL support
70 Summary(pl):    Modu³ j±dra oferuj±cy wsparcie dla ATI FireGL
71 Release:        %{release}@%{_kernel_ver_str}
72 License:        ATI
73 Vendor:         ATI
74 Group:          Base/Kernel
75 %{!?_without_dist_kernel:%requires_releq_kernel_smp}
76 PreReq:         modutils >= 2.3.18-2
77 Requires(post,postun):  /sbin/depmod
78
79 %description -n kernel-smp-video-firegl
80 ATI kernel module for FireGL support.
81
82 %description -n kernel-smp-video-firegl -l pl
83 Modu³ j±dra oferuj±cy wsparcie dla ATI FireGL.
84
85 %prep
86 %setup -q -c -T
87 rpm2cpio %{SOURCE0} | cpio -i -d
88 bzip2 -d -v usr/X11R6/bin/*.bz2
89 mkdir panel_src
90 tar -xzf usr/src/ATI/fglrx_panel_sources.tgz -C panel_src
91 %patch0 -p1
92 %{!?_without_dist_kernel:%patch1 -p1}
93
94 %build
95 cd lib/modules/fglrx/build_mod/
96 cp make.sh make.sh.org && rm -f make.sh
97 sed -e 's#gcc#%{kgcc}#g' -e 's#`id -u` -ne 0#`id -u` -ne `id -u`#g' make.sh.org > make.sh
98 chmod 755 make.sh
99 ./make.sh \
100         SMP=1
101 mv fglrx.o fglrx-smp.o
102 ./make.sh clean
103 ./make.sh
104 cd ../../../../panel_src
105
106 %{__make} \
107         MK_QTDIR=/usr \
108         LIBQT_DYN=qt-mt
109
110 %install
111 rm -rf $RPM_BUILD_ROOT
112 install -d $RPM_BUILD_ROOT{%{_bindir},%{_libdir},%{_includedir}/X11/extensions} \
113         $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}{,smp}/misc/
114
115 install lib/modules/fglrx/build_mod/fglrx.o $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}/misc
116 install lib/modules/fglrx/build_mod/fglrx-smp.o $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}smp/misc
117
118 install usr/X11R6/bin/{fgl_glxgears,fglrxconfig,fglrxinfo} $RPM_BUILD_ROOT%{_bindir}
119 install panel_src/{fireglcontrol.qt3.gcc3.3.1,fireglcontrol} $RPM_BUILD_ROOT%{_bindir}
120 cp -r usr/X11R6/lib/* $RPM_BUILD_ROOT%{_libdir}/
121
122 cd $RPM_BUILD_ROOT%{_libdir}
123 ln -s libGL.so.* libGL.so
124
125 %clean
126 rm -rf $RPM_BUILD_ROOT
127
128 %post   -p /sbin/ldconfig
129 %postun -p /sbin/ldconfig
130
131 %post   -n kernel-video-firegl
132 /sbin/depmod -a %{!?_without_dist_kernel:-F /boot/System.map-%{_kernel_ver} }%{_kernel_ver}
133
134 %postun -n kernel-video-firegl
135 /sbin/depmod -a %{!?_without_dist_kernel:-F /boot/System.map-%{_kernel_ver} }%{_kernel_ver}
136
137 %post   -n kernel-smp-video-firegl
138 /sbin/depmod -a %{!?_without_dist_kernel:-F /boot/System.map-%{_kernel_ver}smp }%{_kernel_ver}smp
139
140 %postun -n kernel-smp-video-firegl
141 /sbin/depmod -a %{!?_without_dist_kernel:-F /boot/System.map-%{_kernel_ver}smp }%{_kernel_ver}smp
142
143 %files
144 %defattr(644,root,root,755)
145 %attr(755,root,root) %{_bindir}/*
146 %attr(755,root,root) %{_libdir}/lib*.so*
147 %attr(755,root,root) %{_libdir}/modules/*/*.so
148 %attr(755,root,root) %{_libdir}/modules/*/*.o
149 %attr(644,root,root) %{_libdir}/modules/*/*.a
150 %attr(755,root,root) /usr/X11R6/lib/libfglrx_gamma.a
151
152 %files -n kernel-video-firegl
153 %defattr(644,root,root,755)
154 /lib/modules/%{_kernel_ver}/misc/*.o*
155
156 %files -n kernel-smp-video-firegl
157 %defattr(644,root,root,755)
158 /lib/modules/%{_kernel_ver}smp/misc/*.o*
This page took 0.042544 seconds and 4 git commands to generate.