我无法访问显示为构建过程一部分的几个关键头文件。
Ubuntu 软件中心显示 build-essential 已安装:
接下来我执行了以下两个命令,但问题并没有改善:
~$ sudo apt-get install build-essential
[sudo] password for:
Reading package lists... Done
Building dependency tree
Reading state information... Done
build-essential is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
:~$ sudo apt-get install -f
Reading package lists... Done
Building dependency tree
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
尝试安装后转储标头。
/usr/include/boost/interprocess/detail/atomic.hpp
/usr/include/boost/interprocess/smart_ptr/detail/sp_counted_base_atomic.hpp
/usr/include/qt4/Qt/qatomic.h /usr/include/qt4/Qt/qbasicatomic.h
/usr/include/qt4/QtCore/qatomic.h
/usr/include/qt4/QtCore/qbasicatomic.h
/usr/share/doc/git-annex/html/bugs/git_annex_unlock_is_not_atomic.html
/usr/src/linux-headers-3.11.0-15/arch/alpha/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/arc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/arm/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/arm64/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/avr32/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/blackfin/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/cris/include/arch-v10/arch/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/cris/include/arch-v32/arch/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/cris/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/frv/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/h8300/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/hexagon/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/ia64/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/m32r/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/m68k/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/metag/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/microblaze/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/mips/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/mn10300/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/parisc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/powerpc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/s390/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/score/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/sh/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/sparc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/tile/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/x86/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/arch/xtensa/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-15/include/asm-generic/atomic.h
/usr/src/linux-headers-3.11.0-15/include/asm-generic/bitops/atomic.h
/usr/src/linux-headers-3.11.0-15/include/asm-generic/bitops/ext2-atomic.h
/usr/src/linux-headers-3.11.0-15/include/asm-generic/bitops/non-atomic.h
/usr/src/linux-headers-3.11.0-15/include/linux/atomic.h
/usr/src/linux-headers-3.11.0-15-generic/include/linux/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/alpha/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/arc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/arm/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/arm64/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/avr32/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/blackfin/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/cris/include/arch-v10/arch/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/cris/include/arch-v32/arch/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/cris/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/frv/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/h8300/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/hexagon/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/ia64/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/m32r/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/m68k/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/metag/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/microblaze/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/mips/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/mn10300/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/parisc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/powerpc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/s390/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/score/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/sh/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/sparc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/tile/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/x86/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/arch/xtensa/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-17/include/asm-generic/atomic.h
/usr/src/linux-headers-3.11.0-17/include/asm-generic/bitops/atomic.h
/usr/src/linux-headers-3.11.0-17/include/asm-generic/bitops/ext2-atomic.h
/usr/src/linux-headers-3.11.0-17/include/asm-generic/bitops/non-atomic.h
/usr/src/linux-headers-3.11.0-17/include/linux/atomic.h
/usr/src/linux-headers-3.11.0-17-generic/include/linux/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/alpha/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/arc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/arm/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/arm64/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/avr32/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/blackfin/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/cris/include/arch-v10/arch/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/cris/include/arch-v32/arch/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/cris/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/frv/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/h8300/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/hexagon/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/ia64/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/m32r/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/m68k/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/metag/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/microblaze/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/mips/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/mn10300/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/parisc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/powerpc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/s390/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/score/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/sh/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/sparc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/tile/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/x86/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/arch/xtensa/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-18/include/asm-generic/atomic.h
/usr/src/linux-headers-3.11.0-18/include/asm-generic/bitops/atomic.h
/usr/src/linux-headers-3.11.0-18/include/asm-generic/bitops/ext2-atomic.h
/usr/src/linux-headers-3.11.0-18/include/asm-generic/bitops/non-atomic.h
/usr/src/linux-headers-3.11.0-18/include/linux/atomic.h
/usr/src/linux-headers-3.11.0-18-generic/include/linux/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/alpha/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/arc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/arm/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/arm64/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/avr32/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/blackfin/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/cris/include/arch-v10/arch/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/cris/include/arch-v32/arch/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/cris/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/frv/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/h8300/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/hexagon/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/ia64/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/m32r/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/m68k/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/metag/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/microblaze/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/mips/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/mn10300/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/parisc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/powerpc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/s390/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/score/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/sh/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/sparc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/tile/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/x86/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/arch/xtensa/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-19/include/asm-generic/atomic.h
/usr/src/linux-headers-3.11.0-19/include/asm-generic/bitops/atomic.h
/usr/src/linux-headers-3.11.0-19/include/asm-generic/bitops/ext2-atomic.h
/usr/src/linux-headers-3.11.0-19/include/asm-generic/bitops/non-atomic.h
/usr/src/linux-headers-3.11.0-19/include/linux/atomic.h
/usr/src/linux-headers-3.11.0-19-generic/include/linux/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/alpha/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/arc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/arm/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/arm64/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/avr32/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/blackfin/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/cris/include/arch-v10/arch/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/cris/include/arch-v32/arch/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/cris/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/frv/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/h8300/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/hexagon/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/ia64/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/m32r/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/m68k/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/metag/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/microblaze/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/mips/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/mn10300/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/parisc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/powerpc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/s390/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/score/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/sh/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/sparc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/tile/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/x86/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/arch/xtensa/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-20/include/asm-generic/atomic.h
/usr/src/linux-headers-3.11.0-20/include/asm-generic/bitops/atomic.h
/usr/src/linux-headers-3.11.0-20/include/asm-generic/bitops/ext2-atomic.h
/usr/src/linux-headers-3.11.0-20/include/asm-generic/bitops/non-atomic.h
/usr/src/linux-headers-3.11.0-20/include/linux/atomic.h
/usr/src/linux-headers-3.11.0-20-generic/include/linux/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/alpha/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/arc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/arm/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/arm64/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/avr32/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/blackfin/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/cris/include/arch-v10/arch/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/cris/include/arch-v32/arch/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/cris/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/frv/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/h8300/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/hexagon/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/ia64/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/m32r/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/m68k/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/metag/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/microblaze/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/mips/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/mn10300/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/parisc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/powerpc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/s390/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/score/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/sh/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/sparc/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/tile/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/x86/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/arch/xtensa/include/asm/atomic.h
/usr/src/linux-headers-3.11.0-22/include/asm-generic/atomic.h
/usr/src/linux-headers-3.11.0-22/include/asm-generic/bitops/atomic.h
/usr/src/linux-headers-3.11.0-22/include/asm-generic/bitops/ext2-atomic.h
/usr/src/linux-headers-3.11.0-22/include/asm-generic/bitops/non-atomic.h
/usr/src/linux-headers-3.11.0-22/include/linux/atomic.h
/usr/src/linux-headers-3.11.0-22-generic/include/linux/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/alpha/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/arc/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/arm/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/arm64/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/avr32/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/blackfin/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/cris/include/arch-v10/arch/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/cris/include/arch-v32/arch/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/cris/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/frv/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/hexagon/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/ia64/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/m32r/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/m68k/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/metag/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/microblaze/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/mips/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/mn10300/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/parisc/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/powerpc/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/s390/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/score/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/sh/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/sparc/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/tile/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/x86/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/arch/xtensa/include/asm/atomic.h
/usr/src/linux-headers-3.14.4-031404/include/asm-generic/atomic.h
/usr/src/linux-headers-3.14.4-031404/include/asm-generic/bitops/atomic.h
/usr/src/linux-headers-3.14.4-031404/include/asm-generic/bitops/ext2-atomic.h
/usr/src/linux-headers-3.14.4-031404/include/asm-generic/bitops/non-atomic.h
/usr/src/linux-headers-3.14.4-031404/include/linux/atomic.h
/usr/src/linux-headers-3.14.4-031404-generic/include/linux/atomic.h
/usr/src/linux-headers-3.14.4-031404-lowlatency/include/linux/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/alpha/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/arc/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/arm/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/arm64/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/avr32/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/blackfin/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/cris/include/arch-v10/arch/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/cris/include/arch-v32/arch/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/cris/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/frv/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/h8300/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/hexagon/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/ia64/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/m32r/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/m68k/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/metag/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/microblaze/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/mips/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/mn10300/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/parisc/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/powerpc/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/s390/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/score/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/sh/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/sparc/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/tile/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/x86/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/arch/xtensa/include/asm/atomic.h
/usr/src/linux-lts-saucy-3.11.0/include/asm-generic/atomic.h
/usr/src/linux-lts-saucy-3.11.0/include/asm-generic/bitops/atomic.h
/usr/src/linux-lts-saucy-3.11.0/include/asm-generic/bitops/ext2-atomic.h
/usr/src/linux-lts-saucy-3.11.0/include/asm-generic/bitops/non-atomic.h
/usr/src/linux-lts-saucy-3.11.0/include/linux/atomic.h
/usr/src/linux-lts-saucy-3.11.0/ubuntu/lttng/lib/ringbuffer/vatomic.h
/usr/src/linux-lts-saucy-3.11.0/ubuntu/lttng/wrapper/ringbuffer/vatomic.h
/usr/src/linux-lts-saucy-3.11.0/ubuntu/lttng-modules/lib/ringbuffer/vatomic.h
/usr/src/linux-lts-saucy-3.11.0/ubuntu/lttng-modules/wrapper/ringbuffer/vatomic.h
是的,我知道这里有多个相同类型的标头,但它们是不同的版本。版本“linux-headers-3.14.4-031404”显示为最新版本。
Ubuntu 显示“无需安装任何内容”。
但是,Eclipse 和 QT4 显示缺少以下 C/C++ 头文件。
#include <linux/version.h>
#include <linux/module.h>
#include <linux/socket.h>
#include <linux/miscdevice.h>
#include <linux/list.h>
#include <linux/vmalloc.h>
#include <linux/slab.h>
#include <linux/init.h>
#include <asm/uaccess.h>
#include <asm/atomic.h>
#include <linux/delay.h>
#include <linux/usb.h>
该问题出现在我的 32 位版本 Ubuntu 和两个 64 位版本上。
我做错了什么?
答案1
看起来您正在尝试编译一个使用 Linux 内核头文件的项目,无论是内核驱动程序还是其他使用 Linux 内核数据结构和 API 的项目。内核开发是一个非常具体的用例,并未涵盖在构建必需品 包,因此安装 build-essential 不会自动使这些头文件提供给您,这并不奇怪。
要安装这些头文件,你需要确保linux-headers-通用 软件包已安装。这将安装 Ubuntu 存储库提供的与当前内核版本相对应的头文件。
即使正确安装,这些头文件也不会安装在默认系统包含路径(目录中/usr/include
),因为它们不打算由主机库和应用程序包含。相反,它们安装在特定于每个已安装内核副本的版本目录中。
在为您的内核版本安装 Linux 内核头文件后,找到它们的标准方式是查看/lib/modules/$(uname -r)/build/include
,其中$(uname -r)
是当前内核版本的 shell 替换:
$ ls /lib/modules/$(uname -r)/build/include/
确保安装了头文件包后,您必须将构建系统指向 Linux 内核包含路径。如果您正在使用基于 Makefile 或 Automake 的项目,则可以使用CPPFLAGS
项目 Makefile 中的变量来完成此操作:
CPPFLAGS = -I/lib/modules/$(shell uname -r)/build/include
现在,如果您正在构建 Linux 内核模块,则可以通过特定方法来设置项目 Makefile 以与 Linux 内核构建系统集成,例如