プレフィックスパスにroot権限なしでautoreconfを使用すると、構成スクリプトが破損します。

プレフィックスパスにroot権限なしでautoreconfを使用すると、構成スクリプトが破損します。

sedパッケージ(libdrm-2.4.59)をコンパイルし、依存関係を使用および削除しようとしていますautoreconf

sed -e "/pthread-stubs/d" -i configure.ac &&
autoreconf -fiv

次の出力が生成されます。

autoreconf: Entering directory `.'
autoreconf: configure.ac: not using Gettext
autoreconf: running: aclocal -I /u/f0/students/estermad/tmp/share/aclocal --force -I m4 ${ACLOCAL_FLAGS}
autoreconf: configure.ac: tracing
autoreconf: running: libtoolize --install --copy --force
libtoolize: putting auxiliary files in AC_CONFIG_AUX_DIR, 'build-aux'.
libtoolize: copying file 'build-aux/config.guess'
libtoolize: copying file 'build-aux/config.sub'
libtoolize: copying file 'build-aux/install-sh'
libtoolize: copying file 'build-aux/ltmain.sh'
libtoolize: putting macros in AC_CONFIG_MACRO_DIRS, 'm4'.
libtoolize: copying file 'm4/libtool.m4'
libtoolize: You should add the contents of 'm4/libtool.m4' to 'aclocal.m4'.
libtoolize: copying file 'm4/ltoptions.m4'
libtoolize: You should add the contents of 'm4/ltoptions.m4' to 'aclocal.m4'.
libtoolize: copying file 'm4/ltsugar.m4'
libtoolize: You should add the contents of 'm4/ltsugar.m4' to 'aclocal.m4'.
libtoolize: copying file 'm4/ltversion.m4'
libtoolize: copying file 'm4/lt~obsolete.m4'
libtoolize: You should add the contents of 'm4/lt~obsolete.m4' to 'aclocal.m4'.
autoreconf: running: /usr/bin/autoconf --force
autoreconf: running: /usr/bin/autoheader --force
autoreconf: running: automake --add-missing --copy --force-missing
configure.ac:32: installing `build-aux/missing'
exynos/Makefile.am: installing `build-aux/depcomp'
autoreconf: Leaving directory `.'

これまでは大丈夫に見えますが、前述したように、configure奇妙なエラーが原因でビルドが停止します。

...
checking for pkg-config... /u/f0/students/estermad/tmp/bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for PCIACCESS... configure: error: in `/u/f0/students/estermad/xc/libdrm-2.4.59':
configure: error: The pkg-config script could not be found or is too old.  Make sure it
is in your PATH or set the PKG_CONFIG environment variable to the full
path to pkg-config.
...

以下は、エラー、適切に設定された対応するコンパイラおよびリンカフラグ、設定されていないconfig.log関連値を示す部分セクションです。pkg-config

configure:12927: checking for PCIACCESS
configure:12932: $PKG_CONFIG --exists --print-errors "pciaccess >= 0.10"
configure:12935: $? = 0
configure:12945: $PKG_CONFIG --exists --print-errors "pciaccess >= 0.10"
configure:12948: $? = 0
configure:12970: error: in `/u/f0/students/estermad/xc/libdrm-2.4.59':
...
ac_cv_env_PCIACCESS_CFLAGS_set=set
ac_cv_env_PCIACCESS_CFLAGS_value=-I/u/f0/students/estermad/tmp/include
ac_cv_env_PCIACCESS_LIBS_set=set
ac_cv_env_PCIACCESS_LIBS_value='-L/u/f0/students/estermad/tmp/lib -lpciaccess'
ac_cv_env_PKG_CONFIG_set=
ac_cv_env_PKG_CONFIG_value=

これは私のシステムにはないautoreconfので、自分で構築する必要があります。このシステムで実行されるすべてのビルドにはプレフィックスがあります。異なる項目間の依存関係を構築するために使用されるプレフィックスです。なぜなら、私は以下を実行したからです。libtoolizelibtoollibdrmlibtool

$ cd libtool-2.4.5
$ ./configure --prefix=/u/f0/students/estermad/tmp && make && make install
$ libtool --finish /u/f0/students/estermad/tmp/lib

ただし、libtoolのビルドとインストールはエラーなく実行されました。生成されたconfigureスクリプトが破損しているかautoreconf(/usr/bin/autoreconfにある)、libtoolize(/u/f0/students/estermad/tmp/binにあります)、aclocalまたはその他の理由で不明です。

手動コメントをlibdrm使わずにビルドしようとしています。ビルドがうまく実行されます。したがって、上記の問題はを実行した後にのみ明らかになります。いくつかの役に立つヒントを教えてください、本当にありがとうございます。autoreconfpthread-stubsautoreconf

ベストアンサー1

解決策は、pkg-configを最新バージョン(現在0.28)に更新することです。 0.18があります。

おすすめ記事