|
# Developer environment |
|
|
# This gets symlinked into /etc/rpm/macros |
|
|
|
|
1 |
## Build directory |
## Build directory |
2 |
%_topdir %(echo $HOME)/rpms |
%_topdir %(echo $HOME)/rpms |
3 |
|
|
14 |
%_smp_mflags -j5 |
%_smp_mflags -j5 |
15 |
|
|
16 |
%distversion %(rpm -qf --qf='%{VERSION}' /etc/redhat-release) |
%distversion %(rpm -qf --qf='%{VERSION}' /etc/redhat-release) |
17 |
%distname %(grep -i fedora /etc/redhat-release >/dev/null && echo "Fedora Core" || echo "Red Hat Linux") |
%dist .el%{distversion}.sme |
18 |
%disttag el%{distversion} |
%smerelease() %(echo "%{?1}%{?dist}.%{?2}" | sed -e's|\\.$||') |
|
%dist .2.%disttag.sme |
|
|
%smerelease() %{?1}%{?dist} |
|
19 |
|
|
20 |
#--------------------------------------------------------------------- |
#--------------------------------------------------------------------- |
21 |
|
|
29 |
|
|
30 |
%_with_smp %(test -d %{kmod_kernelsrcdir smp} && echo 1 || echo 0) |
%_with_smp %(test -d %{kmod_kernelsrcdir smp} && echo 1 || echo 0) |
31 |
%_with_hugemem %(test -d %{kmod_kernelsrcdir hugemem} && echo 1 || echo 0) |
%_with_hugemem %(test -d %{kmod_kernelsrcdir hugemem} && echo 1 || echo 0) |
32 |
|
%_with_xen0 %(test -d %{kmod_kernelsrcdir xen0} && echo 1 || echo 0) |
33 |
|
%_with_xenU %(test -d %{kmod_kernelsrcdir xenU} && echo 1 || echo 0) |
34 |
|
%_with_xen %(test -d %{kmod_kernelsrcdir xen} && echo 1 || echo 0) |
35 |
|
|
36 |
%kmod() \ |
%kmod() \ |
37 |
%{expand:%%global _kmodname %1} \ |
%{expand:%%global _kmodname %1} \ |
44 |
License: GPL \ |
License: GPL \ |
45 |
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-%(id -u -n)-root |
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-%(id -u -n)-root |
46 |
|
|
47 |
|
%kmod_kernel() \ |
48 |
|
%{expand:%%if %%{_with_%1}}\ |
49 |
|
%package %1 \ |
50 |
|
%{expand:%%kmod_dependencies %1} \ |
51 |
|
%{expand:%%kmod_desc %1} \ |
52 |
|
%{expand:%%kmod_scripts %1} \ |
53 |
|
%files %1 \ |
54 |
|
%defattr(-, root, root, -) \ |
55 |
|
%{expand:%%kmod_moduledir %1} \ |
56 |
|
%endif \ |
57 |
|
%{nil} |
58 |
|
|
59 |
%kmod_dependencies() \ |
%kmod_dependencies() \ |
60 |
Summary: %{_kmodname} kernel module(s) \ |
Summary: %{_kmodname} kernel module(s) \ |
61 |
Group: System Environment/Kernel \ |
Group: System Environment/Kernel \ |