level 7
农民工学编程
楼主
编译 glib x86 版本 : ./configure --prefix=/opt/glib-2.24.2 CFLAGS="-I/opt/zlib-1.2.5/include -I/opt/gettext-0.18.1.1/include" LDFLAGS="-L/opt/zlib-1.2.5/lib -L/opt/gettext-0.18.1.1/lib"
在编译前, 先下载编译 gettext 这个应用程序本地化的工具(GNU多国语言...) 编译完后,得到库文件, 工具程序.... 在编译 glib 时候会测试检测 gettext , 这个步骤是通过枚举 PATH 在是否存在 (gettext_root)/msgfmt 这个应用程序工具来确定的, 所在编译 glib 的时候, 要设置好 PATH, 我的情况是这样设置的:export PATH=/opt/gettext-0.18.1.1/bin:$PATH
最后:
make && make install
下面是编译 dbus-glib 库部分: 源文件下载地址:http://www.linuxfromscratch.org/blfs/view/cvs/general/dbus-bindings.html
./configure --prefix=/opt/dbus-glib-0.82 CFLAGS="-I/opt/expat-2.0.1/include -I/opt/dbus-1.4.0/include" LDFLAGS="-L/opt/expat-2.0.1/lib -L/opt/dbus-1.4.0/lib" DBUS_CFLAGS="-I/opt/dbus-1.4.0/include" DBUS_LIBS="-L/opt/dbus-1.4.0/lib" DBUS_GLIB_CFLAGS="-I/opt/glib-2.24.2/include" DBUS_GLIB_LIBS="-L/opt/glib-2.24.2/lib"
编译中要检测 expat , dbus glib 库,所以要事先编译好.....当然, 如果对 linux 的 configure 命令编译熟练, 就可以从编译选项参数中看到大概了 .....
2012年04月07日 16点04分
1
在编译前, 先下载编译 gettext 这个应用程序本地化的工具(GNU多国语言...) 编译完后,得到库文件, 工具程序.... 在编译 glib 时候会测试检测 gettext , 这个步骤是通过枚举 PATH 在是否存在 (gettext_root)/msgfmt 这个应用程序工具来确定的, 所在编译 glib 的时候, 要设置好 PATH, 我的情况是这样设置的:export PATH=/opt/gettext-0.18.1.1/bin:$PATH
最后:
make && make install
下面是编译 dbus-glib 库部分: 源文件下载地址:http://www.linuxfromscratch.org/blfs/view/cvs/general/dbus-bindings.html
./configure --prefix=/opt/dbus-glib-0.82 CFLAGS="-I/opt/expat-2.0.1/include -I/opt/dbus-1.4.0/include" LDFLAGS="-L/opt/expat-2.0.1/lib -L/opt/dbus-1.4.0/lib" DBUS_CFLAGS="-I/opt/dbus-1.4.0/include" DBUS_LIBS="-L/opt/dbus-1.4.0/lib" DBUS_GLIB_CFLAGS="-I/opt/glib-2.24.2/include" DBUS_GLIB_LIBS="-L/opt/glib-2.24.2/lib"
编译中要检测 expat , dbus glib 库,所以要事先编译好.....当然, 如果对 linux 的 configure 命令编译熟练, 就可以从编译选项参数中看到大概了 .....