]>
Commit | Line | Data |
---|---|---|
8594399f JB |
1 | # |
2 | # Conditional build: | |
5985f375 | 3 | %bcond_without nvidia_settings # build the main package |
b27b2c83 | 4 | %bcond_without libXNVCtrl # build libXNVCtrl for http://websvn.kde.org/trunk/kdenonbeta/nvidia/ |
8594399f | 5 | # |
6f31a50d | 6 | %define _buildid 20061219 |
eac12459 | 7 | %define _rel 2 |
b27b2c83 | 8 | Summary: Tool for configuring the NVIDIA driver |
b7eb71c7 | 9 | Summary(pl.UTF-8): Narzędzie do konfigurowania sterownika NVIDIA |
b27b2c83 ER |
10 | Name: nvidia-settings |
11 | Version: 1.0 | |
5985f375 | 12 | Release: 0.%{_buildid}.%{_rel} |
b27b2c83 ER |
13 | License: GPL |
14 | Group: X11 | |
b27b2c83 | 15 | Source0: ftp://download.nvidia.com/XFree86/nvidia-settings/%{name}-%{version}.tar.gz |
6f31a50d | 16 | # Source0-md5: 414a838f01093ceb0ae8535c35e21eac |
84ced5dd | 17 | Patch0: libXNVCtrl-shared.patch |
b27b2c83 | 18 | Patch1: %{name}-xlibs.patch |
8594399f | 19 | URL: ftp://download.nvidia.com/XFree86/nvidia-settings/ |
4a9d0e43 | 20 | BuildRequires: XFree86-devel |
b27b2c83 | 21 | %if %{with nvidia_settings} |
4a9d0e43 | 22 | BuildRequires: gtk+2-devel |
728ab98a | 23 | BuildRequires: m4 |
4a9d0e43 | 24 | BuildRequires: pkgconfig |
b27b2c83 | 25 | %endif |
5985f375 | 26 | Requires: libXNVCtrl = %{version}-%{release} |
b27b2c83 ER |
27 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
28 | ||
29 | %description | |
30 | The `nvidia-settings` utility is a tool for configuring the NVIDIA | |
31 | Linux graphics driver. It operates by communicating with the NVIDIA X | |
32 | driver, querying and updating state as appropriate. This communication | |
33 | is done with the NV-CONTROL X extension. | |
34 | ||
35 | Values such as brightness and gamma, XVideo attributes, temperature, | |
36 | and OpenGL settings can be queried and configured via nvidia-settings. | |
37 | ||
38 | When nvidia-settings starts, it reads the current settings from its | |
39 | configuration file and sends those settings to the X server. Then, it | |
40 | displays a graphical user interface (GUI) interface for configuring | |
41 | the current settings. When nvidia-settings exits, it queries the | |
42 | current settings from the X server and saves them to the configuration | |
43 | file. | |
44 | ||
8798252c JR |
45 | %description -l pl.UTF-8 |
46 | Narzędzie nvidia-settings służy do konfiguracji sterownika do kart | |
47 | graficznych firmy NVIDIA. Działa komunikując się ze sterownikiem X | |
48 | NVIDIA, sprawdzając i uaktualniając stan w razie potrzeby. Komunikacja | |
49 | odbywa się poprzez rozszerzenie X NV-CONTROL. | |
8594399f | 50 | |
8798252c JR |
51 | Za pomocą nvidia-settings można odczytywać i zmieniać wartości takie |
52 | jak jasność i korekcja gamma, atrybuty XVideo, temperatura barw i | |
8594399f JB |
53 | ustawienia OpenGL. |
54 | ||
8798252c JR |
55 | Przy uruchamianiu nvidia-settings odczytuje bieżące ustawienia z pliku |
56 | konfiguracyjnego i wysyła te ustawienia do serwera X. Następnie | |
57 | wyświetla graficzny interfejs użytkownika (GUI) do konfiguracji | |
58 | ustawień. Przy wyłączniu nvidia-settings odczytuje bieżące ustawienia | |
8594399f JB |
59 | z serwera X i zapisuje je do pliku konfiguracyjnego. |
60 | ||
b27b2c83 ER |
61 | %package -n libXNVCtrl |
62 | Summary: libXNVCtrl library | |
b7eb71c7 | 63 | Summary(pl.UTF-8): Biblioteka libXNVCtrl |
b27b2c83 ER |
64 | Group: Libraries |
65 | ||
66 | %description -n libXNVCtrl | |
67 | Library for accessing NV-CONTROL extension in NVIDIA's latest drivers. | |
68 | ||
8798252c JR |
69 | %description -n libXNVCtrl -l pl.UTF-8 |
70 | Biblioteka do obsługi rozszerzenia NV-CONTROL z najnowszych | |
71 | sterowników NVIDIA. | |
8594399f | 72 | |
b27b2c83 | 73 | %package -n libXNVCtrl-devel |
8594399f | 74 | Summary: libXNVCtrl development headers |
b7eb71c7 | 75 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libXNVCtrl |
b27b2c83 | 76 | Group: Development/Libraries |
b27b2c83 | 77 | Requires: XFree86-devel |
eac12459 | 78 | Requires: libXNVCtrl = %{version}-%{release} |
b27b2c83 ER |
79 | |
80 | %description -n libXNVCtrl-devel | |
8594399f JB |
81 | Development headers for libXNVCtrl. |
82 | ||
8798252c JR |
83 | %description -n libXNVCtrl-devel -l pl.UTF-8 |
84 | Pliki nagłówkowe biblioteki libXNVCtrl. | |
b27b2c83 ER |
85 | |
86 | %package -n libXNVCtrl-static | |
87 | Summary: libXNVCtrl static library | |
b7eb71c7 | 88 | Summary(pl.UTF-8): Biblioteka statyczna libXNVCtrl |
eac12459 | 89 | Group: Development/Libraries |
b27b2c83 ER |
90 | Requires: libXNVCtrl-devel = %{version}-%{release} |
91 | ||
92 | %description -n libXNVCtrl-static | |
93 | Static library for libXNVCtrl. | |
94 | ||
8798252c | 95 | %description -n libXNVCtrl-static -l pl.UTF-8 |
8594399f JB |
96 | Biblioteka statyczna libXNVCtrl. |
97 | ||
b27b2c83 ER |
98 | %prep |
99 | %setup -q | |
100 | %patch0 -p1 | |
101 | %patch1 -p1 | |
102 | ||
103 | %build | |
104 | %if %{with libXNVCtrl} | |
105 | cd src/libXNVCtrl | |
106 | xmkmf | |
107 | %{__make} clean | |
4a9d0e43 | 108 | %{__make} \ |
109 | CC="%{__cc}" \ | |
110 | CFLAGS="%{rpmcflags}" | |
8594399f | 111 | cd ../.. |
b27b2c83 ER |
112 | %endif |
113 | ||
114 | %if %{with nvidia_settings} | |
115 | %{__make} \ | |
116 | CC="%{__cc}" \ | |
4a9d0e43 | 117 | CFLAGS="%{rpmcflags}" \ |
118 | LDFLAGS="%{rpmldflags}" | |
b27b2c83 ER |
119 | %endif |
120 | ||
121 | %install | |
122 | rm -rf $RPM_BUILD_ROOT | |
123 | %if %{with nvidia_settings} | |
728ab98a | 124 | install -d $RPM_BUILD_ROOT{%{_bindir},%{_mandir}/man1} |
b27b2c83 | 125 | install nvidia-settings $RPM_BUILD_ROOT%{_bindir} |
728ab98a | 126 | install doc/nvidia-settings.1 $RPM_BUILD_ROOT%{_mandir}/man1/nvidia-settings.1 |
b27b2c83 ER |
127 | %endif |
128 | ||
129 | %if %{with libXNVCtrl} | |
eac12459 ER |
130 | install -d $RPM_BUILD_ROOT%{_examplesdir}/libXNVCtrl-%{version} |
131 | cp -a samples/* $RPM_BUILD_ROOT%{_examplesdir}/libXNVCtrl-%{version} | |
b27b2c83 ER |
132 | %{__make} install \ |
133 | -C src/libXNVCtrl \ | |
134 | DESTDIR=$RPM_BUILD_ROOT | |
135 | %endif | |
136 | ||
137 | %clean | |
138 | rm -rf $RPM_BUILD_ROOT | |
139 | ||
140 | %post -n libXNVCtrl -p /sbin/ldconfig | |
141 | %postun -n libXNVCtrl -p /sbin/ldconfig | |
142 | ||
143 | %if %{with nvidia_settings} | |
144 | %files | |
145 | %defattr(644,root,root,755) | |
b27b2c83 | 146 | %attr(755,root,root) %{_bindir}/%{name} |
728ab98a | 147 | %{_mandir}/man1/* |
b27b2c83 ER |
148 | %endif |
149 | ||
8594399f | 150 | %if %{with libXNVCtrl} |
b27b2c83 ER |
151 | %files -n libXNVCtrl |
152 | %defattr(644,root,root,755) | |
8594399f | 153 | %attr(755,root,root) /usr/X11R6/%{_lib}/libXNVCtrl.so.*.*.* |
b27b2c83 ER |
154 | |
155 | %files -n libXNVCtrl-devel | |
156 | %defattr(644,root,root,755) | |
eac12459 | 157 | %doc doc/{FRAMELOCK,NV-CONTROL-API}.txt |
8594399f JB |
158 | /usr/X11R6/include/X11/extensions/NVCtrl.h |
159 | /usr/X11R6/include/X11/extensions/NVCtrlLib.h | |
160 | /usr/X11R6/%{_lib}/libXNVCtrl.so | |
eac12459 | 161 | %{_examplesdir}/libXNVCtrl-%{version} |
b27b2c83 ER |
162 | |
163 | %files -n libXNVCtrl-static | |
164 | %defattr(644,root,root,755) | |
8594399f JB |
165 | /usr/X11R6/%{_lib}/libXNVCtrl.a |
166 | %endif |