`
freeway2000
  • 浏览: 25537 次
社区版块
存档分类
最新评论

facebook open platform的libfbml库在redhat下编译问题汇总

阅读更多

本文着重解决在编译libfbml中遇到的一些具体问题,所以具体的安装步骤一概省略。

我使用的linux环境是:
Red Hat Enterprise Linux AS release 4 (Nahant Update 4)
Linux version 2.6.9-42.0.10.ELsmp (brewbuilder@ls20-bc1-14.build.redhat.com) (gcc version 3.4.6 20060404 (Red Hat 3.4.6-3)) #1 SMP Fri Feb 16 17:13:42 EST 2007
x86_64 GNU/Linux


之前需要安装: xorg-x11-devel、freetype、freetype-devel、fontconfig-devel、php_devel、libjpeg、zip、unzip、libjpeg


==========================================================================================================

状况:
checking for gcc option to accept ANSI C... none needed
checking for a BSD-compatible install... /usr/bin/install -c
checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... no
checking for pkg-config... /usr/bin/pkg-config
configure: error: *** pkg-config too old; version 0.16 or better required.
Running "./configure" within the "glib-2.14.6" subdirectory failed with error code 256.  Aborting script..
.
解决:
./configure --prefix=/usr
==========================================================================================================
状况:
checking for pkg-config... /usr/bin/pkg-config
checking for GLIB - version >= 2.5.7...
*** 'pkg-config --modversion glib-2.0' returned 2.14.6, but GLIB (2.4.7)
*** was found! If pkg-config was correct, then it is best
*** to remove the old version of GLib. You may also be able to fix the error
*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing
*** /etc/ld.so.conf. Make sure you have run ldconfig if that is
*** required on your system.
*** If pkg-config was wrong, set the environment variable PKG_CONFIG_PATH
*** to point to the correct configuration files
no
configure: error:
*** GLIB 2.5.7 or better is required. The latest version of
*** GLIB is always available from ftp://ftp.gtk.org/. If GLIB is installed
*** but not in the same location as pkg-config add the location of the file
*** glib-2.0.pc to the environment variable PKG_CONFIG_PATH.
Running "./configure" within the "atk-1.9.1" subdirectory failed with error code 256.  Aborting script...

解决:
ll /usr/lib/libglib*

lrwxrwxrwx  1 root root      21 Feb 13  2007 /usr/lib/libglib-1.2.so.0 -> libglib-1.2.so.0.0.10
-rwxr-xr-x  1 root root  142948 Aug  9  2004 /usr/lib/libglib-1.2.so.0.0.10
-rwxr-xr-x  1 root root     810 Oct 14 14:49 /usr/lib/libglib-2.0.la
lrwxrwxrwx  1 root root      23 Oct 14 14:49 /usr/lib/libglib-2.0.so -> libglib-2.0.so.0.1400.6
lrwxrwxrwx  1 root root      23 Oct 14 14:49 /usr/lib/libglib-2.0.so.0 -> libglib-2.0.so.0.1400.6
-rwxr-xr-x  1 root root 2604816 Oct 14 14:49 /usr/lib/libglib-2.0.so.0.1400.6

确认/usr/lib/libglib-2.0.so 是否指向了 libglib-2.0.so.0.1400.6
否则需要
cd /usr/lib/
rm libglib-2.0.so
ln -s libglib-2.0.so.0.1400.6 libglib-2.0.so


==========================================================================================================
状况:
/usr/local/lib/libcairo.so: undefined reference to `FT_GlyphSlot_Embolden'
collect2: ld returned 1 exit status
make[2]: *** [cairosimple] Error 1
make[2]: Leaving directory `/opt/huwei/fbopen/libfbml-1.2.0/dependencies/pango-1.18.4/examples'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/opt/huwei/fbopen/libfbml-1.2.0/dependencies/pango-1.18.4'
make: *** [all] Error 2
Running "make" within the "pango-1.18.4" subdirectory failed with error code 512.  Aborting script...

解决:
将libXft的安装顺序放在pango的前面

==========================================================================================================
状况:
checking for jpeg_destroy_decompress in -ljpeg... no
configure: WARNING: *** JPEG loader will not be built (JPEG library not found) ***
configure: error:
*** Checks for JPEG loader failed. You can build without it by passing
*** --without-libjpeg to configure but some programs using GTK+ may
*** not work properly
Running "./configure" within the "gtk+-2.10.13" subdirectory failed with error code 256.  Aborting script...

解决:
./configure --without-libjpeg 或者安装libjpeg
==========================================================================================================
状况:
编译gtk时出现
checking for x86 platform... no
checking for X... no
configure: error: X development libraries not found

解决:
./configure --x-includes=/usr/X11R6/includes --x-libraries=/usr/X11R6/lib64 --without-libjpeg

==========================================================================================================
状况:
编译gtk时出现
checking for X... libraries /usr/X11R6/lib, headers /usr/X11R6/includes
checking for dnet_ntoa in -ldnet... no
checking for dnet_ntoa in -ldnet_stub... no
checking for gethostbyname... yes
checking for connect... yes
checking for remove... yes
checking for shmat... yes
checking for IceConnectionNumber in -lICE... no
checking for XOpenDisplay... no
configure: error: *** libX11 not found. Check 'config.log' for more details.

解决:
说明需要安装xorg-x11-devel,如果无法安装请先安装几个依赖的包freetype、freetype-devel、fontconfig-devel

==========================================================================================================
状况:
编译libXft时遇到
checking for XRenderFindStandardFormat... no
configure: error: libXrender not found or too old.

解决:
再编译安装一遍xrender-0.8.3
===========================================================================================================
状况:
../../dist/lib/libgkconcvs_s.a(nsCanvasRenderingContext2D.o)(.text+0x149d): In function

`nsCanvasRenderingContext2D::SetDimensions(int, int)':
: undefined reference to `XCreatePixmap'
collect2: ld returned 1 exit status
gmake[3]: *** [libgklayout.so] Error 1
gmake[3]: Leaving directory `/usr/home/yunfeng/facebook/facebook/fb-open-platform/libfbml-

1.2.0/dependencies/mozilla/layout/build'
gmake[2]: *** [libs] Error 2
gmake[2]: Leaving directory `/usr/home/yunfeng/facebook/facebook/fb-open-platform/libfbml-

1.2.0/dependencies/mozilla/layout'
gmake[1]: *** [tier_9] Error 2
gmake[1]: Leaving directory `/usr/home/yunfeng/facebook/facebook/fb-open-platform/libfbml-1.2.0/dependencies/mozilla'
make: *** [default] Error 2

解决:
修改dependencies/mozilla/layout/build/Makefile.in
查找
ifdef MOZ_ENABLE_GTK2
EXTRA_DSO_LDOPTS += $(MOZ_GTK2_LIBS) \
            $(NULL)

改成
ifdef MOZ_ENABLE_GTK2
EXTRA_DSO_LDOPTS += $(MOZ_GTK2_LIBS) \
-L/usr/X11R6/lib -lX11 -lXrender \
        $(NULL)

这个错误一般发生在firefox编译的时候,我一般都手动解压缩firefox软件,然后修改Makefile.in,然后在build-all.py中屏蔽解压缩

firefox的语句就行

===========================================================================================================
如果是x86_64系统编译firefox时发生如下类似错误时

/usr/bin/ld: skipping incompatible /usr/X11R6/lib/libX11.so when searching for -lX11
/usr/bin/ld: cannot find -lX11

需要加入如下参数:

./configure --enable-application=browser --enable-system-cairo --x-libraries=/usr/X11R6/lib64
如果还不行,执行 ldconfig -p | grep libX11 进行分析,看文件是否存在如不存在说明需要安装xorg_x11_devel包
===========================================================================================================

状况:
编译fbml,如果是64位机器会出现
make[1]: *** No rule to make target `src/lib/os_Linux_x86.o'.  Stop.
make: *** [src/lib/os_Linux_x86.o] Error 2
Failed to make libfbml.... Aborting
解决:
修改build-all.py
找到
    system("rm -f src/lib/" + filename) # force the removal of previously set up soft links
    createSoftLink(dependenciesdir + sep + mozilla, filename, "src" + sep + "lib", ".." + sep + "..")

修改成:
    system("rm -f src/lib/" + filename) # force the removal of previously set up soft links
    if filename=="os_Linux_x86_64.o": system("rm -f src/lib/os_Linux_x86.o")
    createSoftLink(dependenciesdir + sep + mozilla, filename, "src" + sep + "lib", ".." + sep + "..")

找到
    command = "ln -s " + commonparentdir + sep + match + " " + destdir + sep + filename
    system(command)
修改成
    command = "ln -s " + commonparentdir + sep + match + " " + destdir + sep + filename
    if filename == "os_Linux_x86_64.o":
                command = "ln -s " + commonparentdir + sep + match + " " + destdir + sep + "os_Linux_x86.o"
                system(command)
    system(command)
===========================================================================================================
状况:
sh: phpize: command not found
Running "phpize" within the "ext" subdirectory failed with error code 32512.  Aborting script..
解决:

安装php_devel

=============================

其他安装帮助
http://forum.developers.facebook.com/viewtopic.php?id=16511
http://code.google.com/p/facebook-install/wiki/HowToInstallFBMLInUbuntu8
http://blog.5ilinux.com/cgi-bin/mt-search.cgi?IncludeBlogs=1&search=%E4%B8%8B%E8%BD%BD
http://fyp832008.blog.163.com/blog/static/914394162008914102158448/

2
0
分享到:
评论

相关推荐

    redhat 交叉编译环境搭建

    本教程将详细介绍如何在Redhat 5.5环境下搭建arm-Linux-gcc-4.5.1版本的交叉编译环境,该过程同样适用于Ubuntu系统。 首先,理解交叉编译的基本概念至关重要。交叉编译是指在一个平台(宿主机)上编译出可以在另一...

    在Redhat4Linux上编译内核

    在Redhat4Linux系统上编译内核是一项高级的系统管理员任务,涉及到操作系统的核心构建过程。这不仅可以让你根据特定需求定制内核,还能让你更好地理解Linux的内部运作机制。以下是一份详细的步骤指南,涵盖了从获取...

    shellcheck在centOS/redHat下已编译的可执行文件

    shellcheck在centOS/redHat下没有可用的可执行文件或者可以直接编译生成的命令...附件是在centOS/redHat下已编译的可执行文件,理论上可以在其他centOS/redHat平台版本下使用,因编译过程太艰辛曲折,收取10分辛苦分。

    boost库1.68版本Linux下编译的动态库和静态库

    如果所有测试都通过,那么说明库编译成功。 6. **使用编译好的库**:在项目中使用编译的Boost库时,需要链接对应的动态库(如`-lboost_thread -lboost_system`)或者静态库,并确保库的路径被系统搜索路径(`LD_...

    基于Redhat 9.0实现Linux 0.01编译与运行.pdf

    在实现Linux 0.01编译与运行时,作者采用了Redhat 9.0平台作为开发环境,GNU工具链作为开发工具,并使用GNU工具链的AT&T语法汇编器进行汇编程序的编译。在源代码语法的修改方面,作者参照Linux 0.11源代码,对Linux ...

    在Redhat 9下建立 ARM-Linux 交叉编译环境

    ### 在Redhat 9下建立ARM-Linux交叉编译环境 #### 一、背景与目的 随着嵌入式系统的快速发展,ARM架构因其低功耗、高性能等特性成为了嵌入式领域的主流选择之一。为了能够在非目标平台(如x86架构的PC)上为ARM...

    RedHat6.5-linux内核配置与编译

    本文主要介绍了如何在RedHat6.5环境下对Linux2.6.26内核进行配置与编译的过程。对于想要深入了解Linux内核工作原理或进行定制化开发的用户来说,这一过程十分重要。 #### 二、准备工作 在开始内核配置与编译之前,...

    openSSL编译好的版本

    标题"OpenSSL编译好的版本"指的是已经预先为Visual Studio编译过的OpenSSL库,这通常意味着开发者无需自行配置编译环境,可以直接在项目中使用这些预编译的库文件。这极大地简化了开发流程,避免了因编译环境设置不...

    redhat中Qt编译

    redhat中Qt的正确编译方法,同时还给出了qt编译过程中出现的错误及解决方法

    redhat或fedora中交叉编译环境的建立

    本实验旨在使学习者能够掌握如何在RedHat或Fedora环境下构建一个完整的交叉编译环境,并熟悉在此环境下的工作流程与原理。特别地,实验将重点介绍NFS (Network File System) 和 TFTP (Trivial File Transfer ...

    linux内核编译——redhat9+vm7+2.6.10

    Linux内核编译是Linux系统管理员和开发者的重要技能之一,特别是在定制特定功能或者优化系统性能时。本篇文章将详细介绍如何在Red Hat 9系统上,使用VMware虚拟机(假设为VMware 7)编译Linux 2.6.10内核。以下是...

    RedHat6.4+版本的编译安装LAMP架构

    在编译安装过程中,可能会遇到各种问题,例如缺少依赖库或配置选项错误。遇到问题时,首先要查看错误提示,根据提示进行解决,如上述例子中提到的`ncurses-devel`和`openssl-devel`。如果不清楚如何解决,可以使用...

    适用于OpenEuler, RedHat的openssh 9.7p1

    目前已经验证过可用的系统为OpenEuler和RedHat 该RPM包只是为了方便各位升级Linux的SSH版本而制作的,压缩包内附有安装说明,请参考使用。 各位可以免费下载使用,不需要积分,也算是反哺一下吧。

    redhat6.4 gcc 编译

    在编译过程中,开发者可能会遇到诸如链接错误、找不到头文件等问题,这些问题通常可以通过正确配置环境变量和安装相应的开发包来解决。在实际操作中,使用`yum`或`dnf`(在RHEL7及以上版本中)等包管理器进行安装会...

    redis redhat 编译版本

    下面将详细介绍在Red Hat环境下编译Redis 3.0.1版本的过程及其相关知识点。 1. **获取源码**:首先,你需要从Redis官方网站或GitHub仓库下载Redis 3.0.1的源代码。你可以使用`wget`命令或者直接访问网站下载。例如...

    Redhat Linux上vsftpd编译安装

    在Redhat Linux操作系统中,vsftpd(Very Secure FTP Daemon)是一个流行的FTP服务器软件,它以其安全性而闻名。为了在系统上安装并使用vsftpd,通常需要进行编译和安装过程,因为默认的软件仓库可能不包含最新的...

    RedHat9下安装yum

    如果在编译过程中遇到依赖问题,可能需要手动安装相应的开发工具包。 安装完成后,可以通过运行`yum`命令来测试其功能。记得更新Yum的元数据,使用`yum update`命令,以便获取最新的软件包信息。 总的来说,这个...

    在RedHat 9.0下建立ARM-Linux交叉编译环境

    ### 在RedHat 9.0下建立ARM-Linux交叉编译环境 #### 一、概述 在RedHat 9.0环境下搭建ARM-Linux交叉编译环境是一项重要的工作,尤其对于那些希望在ARM架构上开发嵌入式系统的开发者来说更是如此。通过本文档,您将...

    redhat linux 下PHP的完整安装过程

    redhat linux 下PHP的完整安装过程,最新版本的PHP源码包。

Global site tag (gtag.js) - Google Analytics