2014-04-24 74 views
2

我想爲特定平臺編譯glib2。它需要gettext,所以我通過gettext庫的位置。例如:從頭開始編譯glib2

$ ./configure CC=.. CFLAGS=... -prefix=.. LDFLAGS="-L../libconv/lib/ -L../gettext/usr/local/lib" --enable-shared=no 

但它返回:

.... 
    checking libintl.h usability... no 
    checking libintl.h presence... no 
    checking for libintl.h... no 
    configure: error: 
    *** You must have either have gettext support in your C library, or use the 
    *** GNU gettext library. (http://www.gnu.org/software/gettext/gettext.html 

你想過爲什麼它沒有檢測到任何gettext的想法?

謝謝。

+1

您可能會從[this](http://askubuntu.com/questions/338656/installing-glib-gives-you-must-have-either-have-gettext-support),[this](https) ://github.com/Homebrew/homebrew/issues/14109)或[this](http://www.linuxquestions.org/questions/linux-from-scratch-13/no-gettext-support-in-c-庫-147703 /) –

回答

0

將所有內容「安裝」到主目錄下的目錄中時,需要在運行configure之前將--prefix目錄的「bin」子目錄添加到$ PATH中。