コンパイル前にGlibcを設定すると、「--with-headers」を使用するようにカーネルヘッダーにエラーが発生します。

コンパイル前にGlibcを設定すると、「--with-headers」を使用するようにカーネルヘッダーにエラーが発生します。

私はスクラッチブックバージョンの最新の安定Linuxを使用しています。存在する5.5.1ステップ、Glibcの設定時に提供されたスクリプトを実行しましたが、--with-headers設定オプションを使用するようにエラーが発生しましたが、すでに使用していました。

この本では、構成が以下を使用することを示します。

../configure \ --prefix=/usr \ --host=$LFS_TGT \ --build=$(../scripts/config.guess) \ --enable-kernel=3.2 \ --with-headers=$LFS/usr/include \ libc_cv_slibdir=/lib

これを行うと、次のエラーが発生します。

checking installed Linux kernel header files... missing or too old!
configure: error: GNU libc requires kernel header files from
Linux 3.2.0 or later to be installed before configuring.
The kernel header files are found usually in /usr/include/asm and
/usr/include/linux; make sure these directories use files from
Linux 3.2.0 or later.  This check uses <linux/version.h>, so
make sure that file was built correctly when installing the kernel header
files.  To use kernel headers not from /usr/include/linux, use the
configure option --with-headers.

進行方法の提案をいただきありがとうございます。

ベストアンサー1

解決する。私の部分の単純な間違いです。後で他の人がこの問題に直面する場合:前の手順(5.4.1)でLinuxヘッダーをインストールしたときにエラーが発生した可能性があり、「cp -rv usr / include $ LFS / usr」ルートを実行できます。必須の。私の場合、私はこの特定のコマンドを見逃したに違いないので、glibcが次のステップで使用するヘッダーはまったくありませんでした。

おすすめ記事