/[packages]/cauldron/dkms-bbswitch/current/SPECS/dkms-bbswitch.spec
ViewVC logotype

Contents of /cauldron/dkms-bbswitch/current/SPECS/dkms-bbswitch.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 584524 - (show annotations) (download)
Thu Feb 6 14:21:52 2014 UTC (10 years, 2 months ago) by akien
File size: 1718 byte(s)
- Add documentation files
- SILENT: Improve description

1 %define oname bbswitch
2
3 Name: dkms-%{oname}
4 Summary: bbswitch - Optimus GPU power switcher
5 Group: System/Kernel and hardware
6 Version: 0.8
7 Release: %mkrel 1
8 License: GPLv2+
9 URL: https://github.com/Bumblebee-Project/bbswitch
10 # source from git repo git://github.com/Bumblebee-Project/bbswitch.git
11 Source0: %{oname}-%{version}.tar.gz
12 BuildArch: noarch
13 Requires: dkms
14
15 %description
16 bbswitch is a kernel module which automatically detects the required
17 ACPI calls for two kinds of Optimus laptops : "real" (e.g. Nvidia GT 425M)
18 and "legacy" (e.g. Nvidia GT 310M) Optimus laptops.
19 The universal calls should work for every laptop model supporting either
20 Optimus calls.
21
22 This package uses DKMS to automatically build the bbswitch kernel module.
23
24 %files
25 %doc NEWS README.md
26 %{_usrsrc}/%{oname}-%{version}-%{release}/*
27
28 %post
29 dkms add -m %{oname} -v %{version}-%{release} --rpm_safe_upgrade &&
30 dkms build -m %{oname} -v %{version}-%{release} --rpm_safe_upgrade &&
31 dkms install -m %{oname} -v %{version}-%{release} --rpm_safe_upgrade --force
32 true
33 /sbin/modprobe %{oname}
34
35 %preun
36 dkms remove --binary -m %{oname} -v %{version}-%{release} --rpm_safe_upgrade --all
37 true
38 /sbin/rmmod %{oname}
39
40 #--------------------------------------------------------------------
41 %prep
42 %setup -qn %{oname}-%{version}
43 sed -i 's/#MODULE_VERSION#/%{version}-%{release}/g' dkms/dkms.conf
44
45 %install
46 mkdir -p %{buildroot}%{_usrsrc}/%{oname}-%{version}-%{release}
47 cp %{oname}.c %{buildroot}%{_usrsrc}/%{oname}-%{version}-%{release}
48 cp Makefile %{buildroot}%{_usrsrc}/%{oname}-%{version}-%{release}
49 cp dkms/dkms.conf %{buildroot}%{_usrsrc}/%{oname}-%{version}-%{release}/dkms.conf

  ViewVC Help
Powered by ViewVC 1.1.30