make后无法找到build

下载centos的src rpm包:http://vault.centos.org/6.4/os/Source/SPackages/

  • 安装

useradd mockbuild

su mockbuild

rpm -i kernel-2.6.32-358.el6.src.rpm

【这时会产生目录/home/mockbuild/rpmbuild/SOURCES和/home/mockbuild/rpmbuild/SPECS】

  • 重建

cd /home/mockbuild/rpmbuild/SPECS

rpmbuild -bp --target=$(uname -m) kernel.spec

【源代码产生在目录/home/mockbuild/rpmbuild/BUILD/kernel-2.6.32-358.el6下,此目录有两个子目录:linux-2.6.32-358.el6.x86_64和vanilla-2.6.32-358.el6,后者是纯粹的源码,无法编译;后者是加了.config文件和key信息的可直接编译的源码】

你可能感兴趣的:(make后无法找到build)