Onde o código-fonte do kernel RHEL7 está instalado?

2

Eu instalei o código fonte do kernel Linux RPM:

[root@localhost ~]# rpm -ivh kernel-3.10.0-229.el7.src.rpm
warning: kernel-3.10.0-229.el7.src.rpm: Header V3 RSA/SHA256 Signature, key ID f4a80eb5: NOKEY
Updating / installing...
   1:kernel-3.10.0-229.el7            ################################# [100%]
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root
warning: user builder does not exist - using root
warning: group builder does not exist - using root

O processo de instalação parece ser bem-sucedido, mas o uso do comando rpm -ql kernel-3.10.0-229.el7.src não consegue encontrar onde o código-fonte está instalado:

[root@localhost ~]# rpm -ql kernel-3.10.0-229.el7.src
package kernel-3.10.0-229.el7.src is not installed

Onde o código-fonte do kernel RHEL7 está instalado?

Atualização: rpm -qa | grep kernel comando ouput:

[root@localhost ~]# rpm -qa | grep kernel
kernel-headers-3.10.0-229.el7.x86_64
kernel-devel-3.10.0-229.el7.x86_64
kernel-3.10.0-229.el7.x86_64
kernel-tools-libs-3.10.0-229.el7.x86_64
abrt-addon-kerneloops-2.1.11-19.el7.x86_64
kernel-tools-3.10.0-229.el7.x86_64
    
por Nan Xiao 07.07.2015 / 09:50

2 respostas

2

Pacotes fonte não são adicionados ao banco de dados rpm, então eles não serão mostrados na consulta.

O local provável é ~ / rpmbuild / {SOURCES, SPECS} com SOURCES contendo as fontes de pacotes e os patches de distribuição, enquanto o subdiretório SPECS contendo o arquivo .spec sendo usado para construir o pacote (consulte a página man rpmbuild (8) para obter detalhes) .

Se você não encontrar as fontes lá, reinstale com a opção -vv para verificar o local se ele for sobrescrito:

$ rpm -ivvh kernel-3.10.0-229.7.2.el7.src.rpm 
--- snip ---
Updating / installing...
   1:kernel-3.10.0-229.7.2.el7        ################################# [100%]
D: ========== Directories not explicitly included in package:
D:          0 /home/user/rpmbuild/SOURCES/
D:          1 /home/user/rpmbuild/SPECS/
D: ==========
    
por 07.07.2015 / 10:50
0

Deve estar em / usr / src / kernel .

se você não encontrá-lo, você pode tentar

rpm -qa | grep -w kernel-devel

rpm -ql kernel-devel-x.x.x.x.x

Isso lhe dará a localização dos arquivos instalados pelo kernel rpm.

Por outro lado, a fonte do kernel deve ser instalada com o pacote kernel-devel, em vez do kernel-x.x.x.x

    
por 07.07.2015 / 10:02