10 |
|
|
11 |
cd /tmp/ || die "Can't chdir to /tmp/ ." |
cd /tmp/ || die "Can't chdir to /tmp/ ." |
12 |
|
|
13 |
if [ ! -r kernel-2.6.32-71.14.1.el6.src.rpm ] |
if [ ! -r kernel-2.6.32-71.29.1.el6.src.rpm ] |
14 |
then |
then |
15 |
wget http://ftp.redhat.com/pub/redhat/linux/enterprise/6Server/en/os/SRPMS/kernel-2.6.32-71.14.1.el6.src.rpm || die "Can't download source package." |
wget http://ftp.riken.jp/Linux/centos/6.0/updates/SRPMS/kernel-2.6.32-71.29.1.el6.src.rpm || die "Can't download source package." |
16 |
fi |
fi |
17 |
rpm --checksig kernel-2.6.32-71.14.1.el6.src.rpm || die "Can't verify signature." |
rpm --checksig kernel-2.6.32-71.29.1.el6.src.rpm || die "Can't verify signature." |
18 |
rpm -ivh kernel-2.6.32-71.14.1.el6.src.rpm || die "Can't install source package." |
rpm -ivh kernel-2.6.32-71.29.1.el6.src.rpm || die "Can't install source package." |
19 |
|
|
20 |
cd /root/rpmbuild/SOURCES/ || die "Can't chdir to /root/rpmbuild/SOURCES/ ." |
cd /root/rpmbuild/SOURCES/ || die "Can't chdir to /root/rpmbuild/SOURCES/ ." |
21 |
if [ ! -r ccs-patch-1.8.0-20101231.tar.gz ] |
if [ ! -r ccs-patch-1.8.2-20110903.tar.gz ] |
22 |
then |
then |
23 |
wget -O ccs-patch-1.8.0-20101231.tar.gz 'http://sourceforge.jp/frs/redir.php?f=/tomoyo/49684/ccs-patch-1.8.0-20101231.tar.gz' || die "Can't download patch." |
wget -O ccs-patch-1.8.2-20110903.tar.gz 'http://sourceforge.jp/frs/redir.php?f=/tomoyo/49684/ccs-patch-1.8.2-20110903.tar.gz' || die "Can't download patch." |
|
fi |
|
|
|
|
|
if [ ! -r ccs-patch-2.6.32-centos-6.0-1.8.0-20110112.diff ] |
|
|
then |
|
|
wget -O ccs-patch-2.6.32-centos-6.0-1.8.0-20110112.diff 'http://sourceforge.jp/projects/tomoyo/svn/view/trunk/1.8.x/ccs-patch/patches/ccs-patch-2.6.32-centos-6.0.diff?root=tomoyo&revision=4346&content-type=text%2Fplain' |
|
24 |
fi |
fi |
25 |
|
|
26 |
cd /root/rpmbuild/SPECS/ || die "Can't chdir to /root/rpmbuild/SPECS/ ." |
cd /root/rpmbuild/SPECS/ || die "Can't chdir to /root/rpmbuild/SPECS/ ." |
33 |
# by setting the define to ".local" or ".bz123456" |
# by setting the define to ".local" or ".bz123456" |
34 |
# |
# |
35 |
-# % define buildid .local |
-# % define buildid .local |
36 |
+%define buildid _tomoyo_1.8.0 |
+%define buildid _tomoyo_1.8.2p2 |
37 |
|
|
38 |
%define rhel 1 |
%define rhel 1 |
39 |
%if %{rhel} |
%if %{rhel} |
55 |
Group: System Environment/Kernel |
Group: System Environment/Kernel |
56 |
License: GPLv2 |
License: GPLv2 |
57 |
URL: http://www.kernel.org/ |
URL: http://www.kernel.org/ |
58 |
@@ -713,7 +713,7 @@ |
@@ -715,7 +715,7 @@ |
59 |
Provides: kernel-devel-uname-r = %{KVERREL}%{?1:.%{1}}\ |
Provides: kernel-devel-uname-r = %{KVERREL}%{?1:.%{1}}\ |
60 |
AutoReqProv: no\ |
AutoReqProv: no\ |
61 |
Requires(pre): /usr/bin/find\ |
Requires(pre): /usr/bin/find\ |
64 |
This package provides kernel headers and makefiles sufficient to build modules\ |
This package provides kernel headers and makefiles sufficient to build modules\ |
65 |
against the %{?2:%{2} }kernel package.\ |
against the %{?2:%{2} }kernel package.\ |
66 |
%{nil} |
%{nil} |
67 |
@@ -879,6 +879,10 @@ |
@@ -881,6 +881,10 @@ |
68 |
|
|
69 |
ApplyOptionalPatch linux-kernel-test.patch |
ApplyOptionalPatch linux-kernel-test.patch |
70 |
|
|
71 |
+# TOMOYO Linux |
+# TOMOYO Linux |
72 |
+tar -zxf %_sourcedir/ccs-patch-1.8.0-20101231.tar.gz |
+tar -zxf %_sourcedir/ccs-patch-1.8.2-20110903.tar.gz |
73 |
+patch -sp1 < %_sourcedir/ccs-patch-2.6.32-centos-6.0-1.8.0-20110112.diff |
+patch -sp1 < patches/ccs-patch-2.6.32-centos-6.0.diff |
74 |
+ |
+ |
75 |
# Any further pre-build tree manipulations happen here. |
# Any further pre-build tree manipulations happen here. |
76 |
|
|
77 |
chmod +x scripts/checkpatch.pl |
chmod +x scripts/checkpatch.pl |
78 |
@@ -903,6 +907,9 @@ |
@@ -905,6 +909,9 @@ |
79 |
for i in *.config |
for i in *.config |
80 |
do |
do |
81 |
mv $i .config |
mv $i .config |