| 首页 | 技术文章 | 软件下载 | 博客 | 论坛 | 精品教程 | 黑客动画 | 视频资源 | 在线服务 | 黑客游戏 | 

您现在的位置: 中国X黑客小组 >> 技术文章 >> 编程技术 >> 程序设计 >> 文章正文 用户登录 新用户注册
  FireFox 1.0.7 编译方法及步骤         ★★★ 【字体:
FireFox 1.0.7 编译方法及步骤
作者:黄鑫(gl…    文章来源:CnXHacker.Net    点击数:    更新时间:2006-2-25    

根据 Mozilla 官方网站上的编译步骤操作总会遇到各种各样的错误提示,以下是在虚拟机环境下验证通过的编译步骤。 

1、准备工作 

  1) 依次安装 Visual C++ 6, Visual C++ Service Pack 5, Visual C++ Processor Pack。 
   
  2) 安装 cygwin 至 C 盘根目录,选择 DOS 风格(默认为 UNIX 风格)。除默认组件外,还应选择以下组件: 
    # ash -- UNIX-like command line interpreter shell 
    # autoconf -- Wrapper scripts for autoconf2.1 and autoconf2.5 
    # coreutils -- GNU core utilities (includes fileutils, sh-utils, and textutils) 
    # cvs -- Concurrent Version System 
    # diffutils -- file comparison utility 
    # findutils -- Utilities for finding files--find, xargs, locate, updatedb 
    # gawk -- pattern matching language (Devel category) 
    # gcc -- C compiler upgrade helper 
    # grep -- text search tool 
    # make -- dependency analyzer for software builds (Devel category) 
    # patchutils -- a small collection of programs that operate on patch files 
    # perl -- a scripting language used to control parts of the build (Interpreters category) 
    # sed -- a search and replace language 
    # unzip -- zip file extraction (Archive category) 
    # zip -- zip file creation (Archive category) 
   
  3) 下载并解压 firefox-1.0.7-source.tar.bz2 至 C 盘根目录,解压后生成 c:\mozilla 目录。 
   
  4) 下载并解压 Netscape’s wintools,在 buildtools 目录编写以下 BAT 文件,运行后生成 moztools 目录: 
  -------------- moztools.bat -------------- 
  set MOZ_TOOLS=c:\mozilla\moztools 
  md %MOZ_TOOLS% 
  cd windows 
  install.bat 
  ------------------ end ------------------- 
   
  5) 编写 .mozconfig 文件保存至 c:\mozilla 目录: 
  --------------- .mozconfig --------------- 
  . $topsrcdir/browser/config/mozconfig 
   
  mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/ff 
   
  ac_add_options --enable-optimize 
  ac_add_options --disable-debug 
  ac_add_options --disable-tests 
  ac_add_options --enable-static 
  ac_add_options --disable-shared 
  ac_add_options --enable-official-branding 
  ------------------ end ------------------- 
   
  6) 编写 mozbuild.bat 文件保存至 c:\mozilla 目录: 
  -------------- mozbuild.bat -------------- 
  @echo off 
  set MOZ_TOOLS=c:\mozilla\moztools 
  set PATH=%PATH%;"C:\Program Files\Microsoft Visual Studio\VC98\Bin";c:\cygwin\bin;%MOZ_TOOLS%\bin 
  call VCVARS32.BAT 

  c:\cygwin\bin\make.exe -f client.mk build 
  ------------------ end ------------------- 
   
  7) 重命名 cygwin\bin\link.exe 


2、编译 

  启动 cygwin 后运行以下命令 
   
  Administrator@win2kpro ~ 
  $ cd c: 
   
  Administrator@win2kpro /cygdrive/c 
  $ cd mozilla/ 
   
  Administrator@win2kpro /cygdrive/c/mozilla 
  $ ./mozbuild.bat 
   
   
  以下为编译时的部分输出结果: 
   
  Setting environment for using Microsoft Visual C++ tools. 
  Adding client.mk options from /cygdrive/c/mozilla/.mozconfig: 
    MOZ_PHOENIX=1 
    MOZ_OBJDIR=$(TOPSRCDIR)/ff 
  cd /cygdrive/c/mozilla/ff 
  /cygdrive/c/mozilla/configure 
  Adding configure options from /cygdrive/c/mozilla/.mozconfig: 
   --disable-ldap 
   --disable-mailnews 
   --enable-extensions=cookie,xml-rpc,xmlextras,pref,transformiix,universalchardet,webservices,inspector,gnomevfs,negotiateauth 
   --enable-crypto 
   --disable-composer 
   --enable-single-profile 
   --disable-profilesharing 
   --enable-optimize 
   --disable-debug 
   --disable-tests 
   --enable-static 
   --disable-shared 
   --enable-official-branding 
   --enable-ui-locale=zh-CN 
  loading cache ./config.cache 
  checking host system type... i686-pc-cygwin 
  checking target system type... i686-pc-cygwin 
  checking build system type... i686-pc-cygwin 
  checking for gcc... (cached) cl 
  checking whether the C compiler (cl ) works... yes 
  checking whether the C compiler (cl ) is a cross-compiler... no 
  checking whether we are using GNU C... (cached) no 
  checking whether cl accepts -g... (cached) no 
  checking for c++... (cached) cl 
  checking whether the C++ compiler (cl ) works... yes 
  checking whether the C++ compiler (cl ) is a cross-compiler... no 
  checking whether we are using GNU C++... (cached) no 
  checking whether cl accepts -g... (cached) no 
  checking for ranlib... (cached) ranlib 
  checking for ml... (cached) /cygdrive/c/PROGRA~1/MICROS~2/VC98/BIN/ml 
  checking for ar... (cached) ar 
  checking for ld... (cached) link 
  checking for strip... (cached) strip 
  checking for windres... (cached) windres 
  checking for gawk... (cached) gawk 
  checking for midl... (cached) midl 
  checking for midl flags... none needed 
  checking how to run the C preprocessor... cl 
  checking for mmintrin.h... (cached) no 
  checking how to run the C preprocessor... cl 
  checking how to run the C++ preprocessor... (cached) /lib/cpp 
  checking for a BSD compatible install... (cached) /usr/bin/install -c 
  checking whether ln -s works... (cached) yes 
  checking for perl5... (cached) /usr/bin/perl 
  checking for minimum required perl version >= 5.004... 5.008007 
  checking for full perl installation... yes 
  checking for doxygen... (cached) : 
  checking for whoami... (cached) /usr/bin/whoami 
  checking for autoconf... (cached) /usr/bin/autoconf 
  checking for unzip... (cached) /usr/bin/unzip 
  checking for zip... (cached) /usr/bin/zip 
  checking for makedepend... no 
  checking for xargs... (cached) /usr/bin/xargs 
  checking for make... (cached) /usr/bin/make 
  checking for X... (cached) no 
  checking for 64-bit OS... no 
  checking for valid optimization flags... yes 
  creating ./config.status 
  creating config/autoconf.mk 
  creating config/doxygen.cfg 
  creating xpfe/global/buildconfig.html 
  creating toolkit/content/buildconfig.html 
  creating toolkit/components/passwordmgr/resources/content/contents.rdf 
  creating toolkit/mozapps/contents-content.rdf 
  creating gfx/gfx-config.h 
  gfx/gfx-config.h is unchanged 
  creating netwerk/necko-config.h 
  netwerk/necko-config.h is unchanged 
  creating xpcom/xpcom-config.h 
  xpcom

[1] [2] 下一页

文章录入:IceRiver    责任编辑:IceRiver 
  • 上一篇文章:

  • 下一篇文章:
  • 发表评论】【加入收藏】【告诉好友】【打印此文】【关闭窗口
    最新热点 最新推荐 相关文章
    Sniffit常见问题及防范策略分
    微软OneCare删除用户Outlook
    US CERT:谷歌eBay雅虎网站均
    补丁无济于事 Firefox仍面临
    密码管理AI RoboForm Pro具有
    Grandstream GXV-3000 电话远
    Epic Games Unreal有多个远程
    金山WPS Office 2007意外泄露
    微软DirectX开发包存缺陷
    用VMware虚拟环境让恶意软件
      网友评论:(只显示最新5条。评论内容只代表网友观点,与本站立场无关!)
    Powered by ICE RIVER - STUDIO
    » CnXHacker.CoM   © CopyRight 2002-2006, CnXHacker.CoM™, Inc. All Rights Reserved.