How to build the environment of XPCOM in Windows XP

rel="File-List" href="file:///C:/DOCUME%7E1/MICROS%7E1/LOCALS%7E1/Temp/msoclip1/01/clip_filelist.xml"> rel="Edit-Time-Data" href="file:///C:/DOCUME%7E1/MICROS%7E1/LOCALS%7E1/Temp/msoclip1/01/clip_editdata.mso">

How to build the environment of XPCOM in Windows XP

1. Download xulrunner-1.8.0.4.en-US.win32.zip and extract it in the appropriate folder, for example ‘C:/XXX/ xulrunner-1.8.0.4’.

2. Download gecko-sdk-win32-msvc-1.8.0.4.zip and extract it in the appropriate folder, for example ‘C:/XXX/ xulrunner-1.8.0.4/ gecko-sdk-1.8.0.4’.

3. Click ‘My Computer’ by the right button of mouse, and select ‘Properties’ menu item.

4. Select ‘Advanced’ tab page in the dialog, please refer the figure-1 below.


Figure-1

5. Click ‘Environment Variables’ button and add ‘C:/XXX/xulrunner-1.8.0.4/ gecko-sdk-1.8.0.4/bin’ into the environment variable of ‘path’, and then click ok until closing all dialogs.

6. Download wintools.zip and extract ‘wintools/buildtools/windows/bin/x86/glib-1.2.dll, libIDL-0.6.dll’ into ‘C:/XXX/ xulrunner-1.8.0.4/ gecko-sdk-1.8.0.4/bin’. If you are a perfectionist, please extract ‘buildtools/windows/lib/ glib-1.2.lib, libIDL-0.6.lib’ into ‘C:/XXX/ xulrunner-1.8.0.4/ gecko-sdk-1.8.0.4/lib’J.

Ok, if you there any ‘*.idl’ files to generate ‘*.h’ and ‘*.xpt’, now you can try.

For instance:

C:/YYY>xpidl.exe -m header -I c:/XXX/xulrunner-1.8.0.4/gecko-sdk-1.8.0.4/idl IMyComponent.idl

C:/YYY>xpidl.exe -m typelib -I c:/XXX/xulrunner-1.8.0.4/gecko-sdk-1.8.0.4/idl IMyComponent.idl

Notice:

XXX indicates the root directory of xulrunner-1.8.0.4 and YYY contains the ‘*.idl’. For this case, it is IMyComponent.idl.

When you finish buiding, ‘IMyComponent.h’ and ‘IMyComponent.xpt’ are found in the current directory. Otherwise, please recheck the related configuration!

7. Download mozilla-win32-1.8b1.zip and unpack it into appropriate folder. For example, ‘C:/ XXX/xulrunner-1.8.0.4/mozilla-1.8b1’.

8. If you ‘*.dll’ and ‘*.xpt’ are available now, please copy them into ‘C:/ XXX/xulrunner-1.8.0.4/mozilla-1.8b1/components’, then use ‘regxpcom.exe’ to register them into mozilla.

For example:

C:> regxpcom.exe -x “C:/ XXX/xulrunner-1.8.0.4/mozilla-1.8b1/components”

Notice:

1. If the path includes blackspaces, the double quotation(“) must be used.

2. When you meet the trouble with the following errors, please use xpidl.exe to regenerate ‘*.h’ and ‘*.xpt’ in your environment. As you know, some samples utilize the new/old version to do that, and will not wholly match your configuration for ever.

“Can not initialize XPCOM Glue”

“Can not aquire component registrar”

“Registration failed: (c1f30001) Files/Mozilla”

“Can not initialize XPCOM Glue”

“Can not aquire component registrar”

“Registration failed: (c1f30001) mozilla/components”

8. If all javascript and html files are ready, please use mozilla to open and check the result.

 

[summarization and suggestions]

1. It only introduces HOWTO for mozilla browser, but it is common way to other, such as firefox, etc.

2. Please keep aware that the versions between mozilla and geck-sdk had better be coherent, otherwise it maybe brings about some unknown issues(Free source codes are free for anythings including bugsJ).

3. If you can not decide whether or not registeration is successful, please use XPCOMViewer into your browser to check.

4. If you fail to register XPCOM after invoking regxpcom.exe, please add an empty file ‘.autoreg’ in the mozill/firefox folder. For instance, ‘C:/XXX/xulrunner-1.8.0.4/mozilla-1.8b1’ or ‘C:/Program Files/Mozilla Firefox’. Try it again.

5. When you compile your source codes, you must take aware of MACROs and LIBs depended. For example, if mozilla or firefox is used to load your program, please DO NOT define XPCOM_GLUE and only link xpcom.lib xpcomglue_s.lib, otherwise xpcomglue.lib is available. In some special cases, you must add nspr4.lib for the former, however, you must try you best to avoid this scenario. Moreover, if you want to be compatible to the old version of browser, please add MOZILLA_STRICT_API for preprocesser. I strongly recommend that you had better read the related notices before you test.

6. Please do you best to find the proper SDK when you decide to build environement. If XULRunner-SDK and Gecko-SDK have been integrated in the package, and it is luckyJ.

 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 3
    评论
"Preproduction Blueprint" is a complete system for planning your game environments and level designs. This could be for a playable level or a game environment exploration to show off in a portfolio. Planning process is called pre-production and what you end up with is a "Preproduction Blueprint". It is an essential step to finishing your projects. Unfortunately, planning tends to be a rushed part of the process or completely ignored. Creating a game environment or a level design is very similar. Once you have an idea you have to go through the steps of: Knowing what you are going to create How the game environment is going to look How the level will play Location, theme and setting of your game environment or level design Creating a top-down layout Defining and designing objectives, obstacles and scripted events Knowing your project purpose Collecting photo reference Creating a story Visual development Creating to do lists, a plan of action Rushing into a level design or game environment without planning will most likely result in unfinished project. All you need is a solid plan of what your environment is going to look and play like prior to creating it. "Preproduction Blueprint" is the planning system and workbook. These are the same steps I use to design environments and levels. It took me years to figure out and to refine so you don’t have to. I laid everything out for you to use in a step-by-step process. After going through the book, you’ll be able to close your eyes and walk through the environment. The level will be finished in your mind. The next step will be to open up a level editor and begin construction. Table of Contents Inner Cover Legal: Copyright, Trademarks, Disclaimers Acknowledgements Table of Content: The Secret Behind Preproduction Blueprint 11 Step Planning Overview How to Follow “Preproduction Blueprint” Playable Level or Stand-Alone Game Environment Step 1: Ideas Step 2: Setting, Location and Theme Step 3: Project Purpose Step 4: Feat
评论 3
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值