~ubuntu-branches/ubuntu/precise/kompozer/precise

« back to all changes in this revision

Viewing changes to mozilla/extensions/python/xpcom/src/readme.html

  • Committer: Bazaar Package Importer
  • Author(s): Anthony Yarusso
  • Date: 2007-08-27 01:11:03 UTC
  • Revision ID: james.westby@ubuntu.com-20070827011103-2jgf4s6532gqu2ka
Tags: upstream-0.7.10
ImportĀ upstreamĀ versionĀ 0.7.10

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<!-- Copyright (c) 2000-2001 ActiveState Tool Corporation. -->
 
2
<!-- See the file LICENSE.txt for licensing information. -->
 
3
 
 
4
<html>
 
5
 
 
6
<head>
 
7
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
 
8
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
 
9
<meta name="ProgId" content="FrontPage.Editor.Document">
 
10
<title>Building the Python XPCOM package</title>
 
11
</head>
 
12
 
 
13
<body>
 
14
 
 
15
<h1>Building the Python XPCOM package.</h1>
 
16
 
 
17
<p>This file describes how to build the Python XPCOM C++ sources.</p>
 
18
<p>There are the following steps</p>
 
19
<ul>
 
20
  <li><a href="#ConfiguringTheEnvironment">Configure environment variables</a></li>
 
21
  <li><a href="#BuildingTheSources">Building the sources</a></li>
 
22
</ul>
 
23
<p>Testing etc is described in the <a href="../readme.html">main readme</a>.</p>
 
24
<h2><a name="ConfiguringTheEnvironment">Configuring environment variables</a></h2>
 
25
<h3> MOZ_SRC&nbsp;</h3>
 
26
<p><b>Windows: </b>Run the standard MOZENV.BAT used to build Mozilla.&nbsp; This
 
27
sets MOZ_SRC</p>
 
28
<p><b>Unix:</b> Set MOZ_SRC to point to the base source directory -  assumes
 
29
&quot;mozilla&quot; sub-directory with mozilla directory  tree under that. eg: assuming
 
30
<i>/home/user/src/mozilla/dist/...</i>&quot;</p>
 
31
<pre>export MOZ_SRC=/home/user/src</pre>
 
32
<h3>PYTHON_SRC</h3>
 
33
<p><b>Windows:</b> Set <i> PYTHON_SRC</i> to point to the base Python source  directory.&nbsp;
 
34
eg: assuming <i>c:\src\python\PCBuild\...</i><pre>set PYTHON_SRC=c:\src\python</pre>
 
35
<p>Unix: Set PYTHON_SRC to point to the base of an &quot;installed&quot; Python
 
36
tree. eg:<pre>export PYTHON_SRC=/usr/local/ActivePython-1.6</pre>
 
37
<h2><a name="BuildingTheSources">Building the sources</a></h2>
 
38
<p>You must ensure some environment variables are setup.&nbsp; The section on <a href="#ConfiguringTheEnvironment">configuring
 
39
environment variables explains how.</a></p>
 
40
<p>There are 2 build processes to run All C++ sources are in the <i>xpcom\src</i>
 
41
 directory.:</p>
 
42
<h3>Windows</h3>
 
43
<ul>
 
44
  <li> Execute &quot;compile.py&quot; in this directory.  This will take <i>Setup.in</i>, create an MSDev project, and build
 
45
    <i>..\_xpcom.pyd</i> and <i>..\_xpcom_d.pyd</i>&quot;</li>
 
46
  <li> Change to the <i>loader</i> directory.</li>
 
47
  <li> Run <i>nmake -f makefile.win</i>.  This will create <i>pyloader.dll</i>,  and
 
48
    automatically copy it to the Mozilla build directory.</li>
 
49
 <a href="#ConfiguringTheEnvironment">
 
50
  </ul>
 
51
  <p>Finally, </a><a href="../readme.html#RunningTheTests">run the tests</a>,
 
52
  where we also test everything imports correctly.</p>
 
53
<h3>Linux</h3>
 
54
<p><b> NOTE:</b>  Do not attempt to use &quot;Setup.in&quot; to create a Makefile&nbsp;</p>
 
55
<ul>
 
56
  <li>Run &quot;make&quot; in this directory.&nbsp; This will create <i>../_xpcommodule.so</i></li>
 
57
  <li> Run "make" in the loader directory.  This will create <i>libpyloader.so</i>,
 
58
    and copy it to the Mozilla directory.</li>
 
59
 <a href="#ConfiguringTheEnvironment">
 
60
  </ul>
 
61
  <p>Finally, </a><a href="../readme.html#RunningTheTests">running the tests</a>,
 
62
  where we also test everything imports correctly.</p>
 
63
 
 
64
</body>
 
65
 
 
66
</html>