UbuntuエラーにOpenFlowをインストールする:glibconfig.h:そのファイルまたはディレクトリはありません。

UbuntuエラーにOpenFlowをインストールする:glibconfig.h:そのファイルまたはディレクトリはありません。

私のUbuntuコンピュータにOpenFlowをインストールしようとしています。私は次のステップに従っています。協会

次のコマンドを実行しようとすると:

cd utilities/wireshark_dissectors/openflow
make
sudo make install

make私には、次のエラーが発生します。

/usr/include/glib-2.0/glib/gtypes.h:32:24: fatal error: glibconfig.h: No such file or directory
compilation terminated.
<builtin>: recipe for target 'packet-openflow.o' failed
make: *** [packet-openflow.o] Error 1

~によるとこれこれを行う必要がありますが、私の場合はmakeファイルがあります。

gcc `pkg-config --cflags glib-2.0` foo.c `pkg-config --libs glib-2.0`

この問題を解決するにはどうすればよいですか?

ベストアンサー1

次のコマンドを使用して、必要なコマンドラインパラメータを渡すことができますCPPFLAGS

make CPPFLAGS="$(pkg-config --cflags glib-2.0)"

これにより、コンパイラに必要なインクルードパスが提供されます。

おすすめ記事