2014-07-07 15:39:59 -03:00
|
|
|
Quick Start Guide
|
|
|
|
-----------------
|
|
|
|
|
2014-11-22 16:54:57 -04:00
|
|
|
1. Install Microsoft Visual Studio 2015, any edition.
|
2014-07-07 15:39:59 -03:00
|
|
|
2. Install Subversion, and make sure 'svn.exe' is on your PATH.
|
2014-11-01 20:42:46 -03:00
|
|
|
3. Run "build.bat -e" to build Python in 32-bit Release configuration.
|
|
|
|
4. (Optional, but recommended) Run the test suite with "rt.bat -q".
|
2014-07-07 15:39:59 -03:00
|
|
|
|
|
|
|
|
2013-10-25 04:58:16 -03:00
|
|
|
Building Python using Microsoft Visual C++
|
|
|
|
------------------------------------------
|
|
|
|
|
|
|
|
This directory is used to build CPython for Microsoft Windows NT version
|
2014-11-22 16:54:57 -04:00
|
|
|
6.0 or higher (Windows Vista, Windows Server 2008, or later) on 32 and 64
|
2013-10-25 04:58:16 -03:00
|
|
|
bit platforms. Using this directory requires an installation of
|
2014-11-22 16:54:57 -04:00
|
|
|
Microsoft Visual C++ 2015 (MSVC 14.0) of any edition. The specific
|
2013-10-25 04:58:16 -03:00
|
|
|
requirements are as follows:
|
2014-03-19 16:46:25 -03:00
|
|
|
|
2014-11-22 16:54:57 -04:00
|
|
|
Visual Studio Express 2015 for Desktop
|
|
|
|
Visual Studio Professional 2015
|
|
|
|
Either edition is sufficient for building all configurations except
|
|
|
|
for Profile Guided Optimization.
|
2014-07-07 16:33:24 -03:00
|
|
|
The Python build solution pcbuild.sln makes use of Solution Folders,
|
|
|
|
which this edition does not support. Any time pcbuild.sln is opened
|
2014-11-22 16:54:57 -04:00
|
|
|
or reloaded by Visual Studio, a warning about Solution Folders will
|
|
|
|
be displayed, which can be safely dismissed with no impact on your
|
2014-07-07 16:33:24 -03:00
|
|
|
ability to build Python.
|
2014-03-19 16:46:25 -03:00
|
|
|
Required for building 64-bit Debug and Release configuration builds
|
2014-11-22 16:54:57 -04:00
|
|
|
Visual Studio Premium 2015
|
2013-10-25 04:58:16 -03:00
|
|
|
Required for building Release configuration builds that make use of
|
2014-03-19 16:46:25 -03:00
|
|
|
Profile Guided Optimization (PGO), on either platform.
|
|
|
|
|
2013-10-25 04:58:16 -03:00
|
|
|
All you need to do to build is open the solution "pcbuild.sln" in Visual
|
|
|
|
Studio, select the desired combination of configuration and platform,
|
2014-11-22 16:54:57 -04:00
|
|
|
then build with "Build Solution". You can also build from the command
|
|
|
|
line using the "build.bat" script in this directory; see below for
|
|
|
|
details. The solution is configured to build the projects in the correct
|
|
|
|
order.
|
2013-10-25 04:58:16 -03:00
|
|
|
|
|
|
|
The solution currently supports two platforms. The Win32 platform is
|
2014-11-22 16:54:57 -04:00
|
|
|
used to build standard x86-compatible 32-bit binaries, output into the
|
|
|
|
win32 sub-directory. The x64 platform is used for building 64-bit AMD64
|
|
|
|
(aka x86_64 or EM64T) binaries, output into the amd64 sub-directory.
|
|
|
|
The Itanium (IA-64) platform is no longer supported. See the "Building
|
|
|
|
for AMD64" section below for more information about 64-bit builds.
|
2013-10-25 04:58:16 -03:00
|
|
|
|
|
|
|
Four configuration options are supported by the solution:
|
|
|
|
Debug
|
|
|
|
Used to build Python with extra debugging capabilities, equivalent
|
|
|
|
to using ./configure --with-pydebug on UNIX. All binaries built
|
|
|
|
using this configuration have "_d" added to their name:
|
2014-03-17 17:57:38 -03:00
|
|
|
python35_d.dll, python_d.exe, parser_d.pyd, and so on. Both the
|
2013-10-25 04:58:16 -03:00
|
|
|
build and rt (run test) batch files in this directory accept a -d
|
|
|
|
option for debug builds. If you are building Python to help with
|
|
|
|
development of CPython, you will most likely use this configuration.
|
|
|
|
PGInstrument, PGUpdate
|
|
|
|
Used to build Python in Release configuration using PGO, which
|
2014-07-07 16:31:34 -03:00
|
|
|
requires Premium Edition of Visual Studio. See the "Profile
|
2013-10-25 04:58:16 -03:00
|
|
|
Guided Optimization" section below for more information. Build
|
|
|
|
output from each of these configurations lands in its own
|
2014-11-22 16:54:57 -04:00
|
|
|
sub-directory of this directory. The official Python releases may
|
|
|
|
be built using these configurations.
|
2013-10-25 04:58:16 -03:00
|
|
|
Release
|
|
|
|
Used to build Python as it is meant to be used in production
|
|
|
|
settings, though without PGO.
|
|
|
|
|
Merged revisions 59605-59624 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r59606 | georg.brandl | 2007-12-29 11:57:00 +0100 (Sat, 29 Dec 2007) | 2 lines
Some cleanup in the docs.
........
r59611 | martin.v.loewis | 2007-12-29 19:49:21 +0100 (Sat, 29 Dec 2007) | 2 lines
Bug #1699: Define _BSD_SOURCE only on OpenBSD.
........
r59612 | raymond.hettinger | 2007-12-29 23:09:34 +0100 (Sat, 29 Dec 2007) | 1 line
Simpler documentation for itertools.tee(). Should be backported.
........
r59613 | raymond.hettinger | 2007-12-29 23:16:24 +0100 (Sat, 29 Dec 2007) | 1 line
Improve docs for itertools.groupby(). The use of xrange(0) to create a unique object is less obvious than object().
........
r59620 | christian.heimes | 2007-12-31 15:47:07 +0100 (Mon, 31 Dec 2007) | 3 lines
Added wininst-9.0.exe executable for VS 2008
Integrated bdist_wininst into PCBuild9 directory
........
r59621 | christian.heimes | 2007-12-31 15:51:18 +0100 (Mon, 31 Dec 2007) | 1 line
Moved PCbuild directory to PC/VS7.1
........
r59622 | christian.heimes | 2007-12-31 15:59:26 +0100 (Mon, 31 Dec 2007) | 1 line
Fix paths for build bot
........
r59623 | christian.heimes | 2007-12-31 16:02:41 +0100 (Mon, 31 Dec 2007) | 1 line
Fix paths for build bot, part 2
........
r59624 | christian.heimes | 2007-12-31 16:18:55 +0100 (Mon, 31 Dec 2007) | 1 line
Renamed PCBuild9 directory to PCBuild
........
2007-12-31 12:14:33 -04:00
|
|
|
|
2014-07-07 15:39:59 -03:00
|
|
|
Building Python using the build.bat script
|
|
|
|
----------------------------------------------
|
|
|
|
|
|
|
|
In this directory you can find build.bat, a script designed to make
|
2014-11-22 16:54:57 -04:00
|
|
|
building Python on Windows simpler. This script will use the env.bat
|
|
|
|
script to detect one of Visual Studio 2015, 2013, 2012, or 2010, any of
|
|
|
|
which may be used to build Python, though only Visual Studio 2015 is
|
|
|
|
officially supported.
|
2014-07-07 15:39:59 -03:00
|
|
|
|
|
|
|
By default, build.bat will build Python in Release configuration for
|
|
|
|
the 32-bit Win32 platform. It accepts several arguments to change
|
|
|
|
this behavior:
|
|
|
|
|
|
|
|
-c <configuration> Set the configuration (see above)
|
|
|
|
-d Shortcut for "-c Debug"
|
|
|
|
-p <platform> Set the platform to build for ("Win32" or "x64")
|
|
|
|
-r Rebuild instead of just building
|
2014-11-22 16:54:57 -04:00
|
|
|
-t <target> Set the target (Build, Rebuild, Clean or CleanAll)
|
2014-07-07 15:39:59 -03:00
|
|
|
-e Use get_externals.bat to fetch external sources
|
2014-11-22 16:54:57 -04:00
|
|
|
-M Don't build in parallel
|
|
|
|
-v Increased output messages
|
2014-07-07 15:39:59 -03:00
|
|
|
|
2014-10-26 00:57:05 -03:00
|
|
|
Up to 9 MSBuild switches can also be passed, though they must be passed
|
|
|
|
after specifying any of the above switches. For example, use:
|
|
|
|
|
2014-11-22 16:54:57 -04:00
|
|
|
build.bat -e -d /fl
|
2014-10-26 00:57:05 -03:00
|
|
|
|
2014-11-22 16:54:57 -04:00
|
|
|
to do a debug build with externals fetched as needed and write detailed
|
|
|
|
build logs to a file. If the MSBuild switch requires an equal sign
|
|
|
|
("="), the entire switch must be quoted:
|
2014-10-26 00:57:05 -03:00
|
|
|
|
2014-11-22 16:54:57 -04:00
|
|
|
build.bat -e -d "/p:ExternalsDir=P:\cpython-externals"
|
2014-10-26 00:57:05 -03:00
|
|
|
|
|
|
|
There may also be other situations where quotes are necessary.
|
|
|
|
|
2014-07-07 15:39:59 -03:00
|
|
|
|
2013-10-25 04:58:16 -03:00
|
|
|
C Runtime
|
Merged revisions 59642-59665 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r59653 | martin.v.loewis | 2008-01-01 22:05:17 +0100 (Tue, 01 Jan 2008) | 3 lines
Return results from Python callbacks to Tcl as Tcl objects.
Fixes Tk issue #1851526
........
r59654 | martin.v.loewis | 2008-01-01 22:08:18 +0100 (Tue, 01 Jan 2008) | 4 lines
Always convert Text.index result to string.
This improves compatibility with Tcl 8.5, which would
otherwise return textindex objects.
........
r59655 | martin.v.loewis | 2008-01-01 22:09:07 +0100 (Tue, 01 Jan 2008) | 2 lines
News item for r59653.
........
r59656 | martin.v.loewis | 2008-01-02 00:00:00 +0100 (Wed, 02 Jan 2008) | 1 line
Don't link with Tix; Tix is loaded dynamically by Tcl.
........
r59657 | martin.v.loewis | 2008-01-02 00:00:48 +0100 (Wed, 02 Jan 2008) | 1 line
Use Visual Studio 2009 on the build slaves.
........
r59658 | martin.v.loewis | 2008-01-02 00:36:24 +0100 (Wed, 02 Jan 2008) | 1 line
Test in PCbuild directory.
........
r59661 | kurt.kaiser | 2008-01-02 05:11:28 +0100 (Wed, 02 Jan 2008) | 6 lines
Issue1177
r58207 and r58247 patch logic is reversed. I noticed this when I
tried to use urllib to retrieve a file which required auth.
Fix that and add a test for 401 error to verify.
........
r59662 | kurt.kaiser | 2008-01-02 06:23:38 +0100 (Wed, 02 Jan 2008) | 2 lines
Change docstrings to comments so test output will display normally.
........
r59665 | christian.heimes | 2008-01-02 18:43:40 +0100 (Wed, 02 Jan 2008) | 5 lines
Removed PCbuild8/ directory and added a new build directory for VS 2005
based on the VS 2008 build directory to PC/VS8.0. The script
PCbuild/vs8to9.py was added to sync changes from PCbuild to PC/VS8.0.
Kristjan, the initial creator of the PCbuild8 directory is fine with the replacement. I've moved the new version of the VS 2005 build directory next to the other legacy build directories. The new sync script is based on the work of wreck and syncs changes in the project, property and solution files.
........
2008-01-02 14:30:52 -04:00
|
|
|
---------
|
|
|
|
|
2014-11-22 16:54:57 -04:00
|
|
|
Visual Studio 2015 uses version 14 of the C runtime (MSVCRT14). The
|
2013-10-25 04:58:16 -03:00
|
|
|
executables no longer use the "Side by Side" assemblies used in previous
|
|
|
|
versions of the compiler. This simplifies distribution of applications.
|
|
|
|
|
|
|
|
The run time libraries are available under the VC/Redist folder of your
|
|
|
|
Visual Studio distribution. For more info, see the Readme in the
|
|
|
|
VC/Redist folder.
|
|
|
|
|
|
|
|
|
|
|
|
Sub-Projects
|
|
|
|
------------
|
Merged revisions 59642-59665 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r59653 | martin.v.loewis | 2008-01-01 22:05:17 +0100 (Tue, 01 Jan 2008) | 3 lines
Return results from Python callbacks to Tcl as Tcl objects.
Fixes Tk issue #1851526
........
r59654 | martin.v.loewis | 2008-01-01 22:08:18 +0100 (Tue, 01 Jan 2008) | 4 lines
Always convert Text.index result to string.
This improves compatibility with Tcl 8.5, which would
otherwise return textindex objects.
........
r59655 | martin.v.loewis | 2008-01-01 22:09:07 +0100 (Tue, 01 Jan 2008) | 2 lines
News item for r59653.
........
r59656 | martin.v.loewis | 2008-01-02 00:00:00 +0100 (Wed, 02 Jan 2008) | 1 line
Don't link with Tix; Tix is loaded dynamically by Tcl.
........
r59657 | martin.v.loewis | 2008-01-02 00:00:48 +0100 (Wed, 02 Jan 2008) | 1 line
Use Visual Studio 2009 on the build slaves.
........
r59658 | martin.v.loewis | 2008-01-02 00:36:24 +0100 (Wed, 02 Jan 2008) | 1 line
Test in PCbuild directory.
........
r59661 | kurt.kaiser | 2008-01-02 05:11:28 +0100 (Wed, 02 Jan 2008) | 6 lines
Issue1177
r58207 and r58247 patch logic is reversed. I noticed this when I
tried to use urllib to retrieve a file which required auth.
Fix that and add a test for 401 error to verify.
........
r59662 | kurt.kaiser | 2008-01-02 06:23:38 +0100 (Wed, 02 Jan 2008) | 2 lines
Change docstrings to comments so test output will display normally.
........
r59665 | christian.heimes | 2008-01-02 18:43:40 +0100 (Wed, 02 Jan 2008) | 5 lines
Removed PCbuild8/ directory and added a new build directory for VS 2005
based on the VS 2008 build directory to PC/VS8.0. The script
PCbuild/vs8to9.py was added to sync changes from PCbuild to PC/VS8.0.
Kristjan, the initial creator of the PCbuild8 directory is fine with the replacement. I've moved the new version of the VS 2005 build directory next to the other legacy build directories. The new sync script is based on the work of wreck and syncs changes in the project, property and solution files.
........
2008-01-02 14:30:52 -04:00
|
|
|
|
2013-10-25 04:58:16 -03:00
|
|
|
The CPython project is split up into several smaller sub-projects which
|
|
|
|
are managed by the pcbuild.sln solution file. Each sub-project is
|
|
|
|
represented by a .vcxproj and a .vcxproj.filters file starting with the
|
|
|
|
name of the sub-project. These sub-projects fall into a few general
|
|
|
|
categories:
|
2000-06-30 21:03:43 -03:00
|
|
|
|
2013-10-25 04:58:16 -03:00
|
|
|
The following sub-projects represent the bare minimum required to build
|
|
|
|
a functioning CPython interpreter. If nothing else builds but these,
|
|
|
|
you'll have a very limited but usable python.exe:
|
2001-01-17 19:23:13 -04:00
|
|
|
pythoncore
|
2000-06-30 21:03:43 -03:00
|
|
|
.dll and .lib
|
|
|
|
python
|
|
|
|
.exe
|
2013-10-25 04:58:16 -03:00
|
|
|
make_buildinfo, make_versioninfo
|
|
|
|
helpers to provide necessary information to the build process
|
|
|
|
|
|
|
|
These sub-projects provide extra executables that are useful for running
|
|
|
|
CPython in different ways:
|
2000-06-30 21:03:43 -03:00
|
|
|
pythonw
|
2013-10-25 04:58:16 -03:00
|
|
|
pythonw.exe, a variant of python.exe that doesn't open a Command
|
|
|
|
Prompt window
|
|
|
|
pylauncher
|
|
|
|
py.exe, the Python Launcher for Windows, see
|
|
|
|
http://docs.python.org/3/using/windows.html#launcher
|
|
|
|
pywlauncher
|
|
|
|
pyw.exe, a variant of py.exe that doesn't open a Command Prompt
|
|
|
|
window
|
2013-11-05 23:55:46 -04:00
|
|
|
_testembed
|
|
|
|
_testembed.exe, a small program that embeds Python for testing
|
|
|
|
purposes, used by test_capi.py
|
2013-10-25 04:58:16 -03:00
|
|
|
|
|
|
|
These are miscellaneous sub-projects that don't really fit the other
|
2014-11-22 16:54:57 -04:00
|
|
|
categories:
|
2013-10-25 04:58:16 -03:00
|
|
|
_freeze_importlib
|
|
|
|
_freeze_importlib.exe, used to regenerate Python\importlib.h after
|
|
|
|
changes have been made to Lib\importlib\_bootstrap.py
|
|
|
|
bdist_wininst
|
2014-11-22 16:54:57 -04:00
|
|
|
..\Lib\distutils\command\wininst-14.0[-amd64].exe, the base
|
2013-10-25 04:58:16 -03:00
|
|
|
executable used by the distutils bdist_wininst command
|
|
|
|
python3dll
|
|
|
|
python3.dll, the PEP 384 Stable ABI dll
|
|
|
|
xxlimited
|
|
|
|
builds an example module that makes use of the PEP 384 Stable ABI,
|
|
|
|
see Modules\xxlimited.c
|
|
|
|
|
|
|
|
The following sub-projects are for individual modules of the standard
|
|
|
|
library which are implemented in C; each one builds a DLL (renamed to
|
|
|
|
.pyd) of the same name as the project:
|
|
|
|
_ctypes
|
|
|
|
_ctypes_test
|
|
|
|
_decimal
|
|
|
|
_elementtree
|
|
|
|
_hashlib
|
|
|
|
_msi
|
|
|
|
_multiprocessing
|
|
|
|
_overlapped
|
2000-06-30 21:03:43 -03:00
|
|
|
_socket
|
2001-02-03 23:09:53 -04:00
|
|
|
_testcapi
|
2012-02-25 07:24:21 -04:00
|
|
|
_testbuffer
|
2013-10-25 04:58:16 -03:00
|
|
|
_testimportmultiple
|
2002-02-13 19:56:46 -04:00
|
|
|
pyexpat
|
2000-06-30 21:03:43 -03:00
|
|
|
select
|
2001-01-24 06:07:22 -04:00
|
|
|
unicodedata
|
2000-06-30 21:03:43 -03:00
|
|
|
winsound
|
|
|
|
|
2013-10-25 04:58:16 -03:00
|
|
|
The following Python-controlled sub-projects wrap external projects.
|
|
|
|
Note that these external libraries are not necessary for a working
|
|
|
|
interpreter, but they do implement several major features. See the
|
|
|
|
"Getting External Sources" section below for additional information
|
|
|
|
about getting the source for building these libraries. The sub-projects
|
|
|
|
are:
|
2011-04-03 12:05:46 -03:00
|
|
|
_bz2
|
2013-10-25 04:58:16 -03:00
|
|
|
Python wrapper for version 1.0.6 of the libbzip2 compression library
|
|
|
|
Homepage:
|
2011-04-03 12:05:46 -03:00
|
|
|
http://www.bzip.org/
|
2011-11-29 18:25:06 -04:00
|
|
|
_lzma
|
2013-10-25 04:58:16 -03:00
|
|
|
Python wrapper for the liblzma compression library, using pre-built
|
2013-11-22 14:13:51 -04:00
|
|
|
binaries of XZ Utils version 5.0.5
|
2013-10-25 04:58:16 -03:00
|
|
|
Homepage:
|
|
|
|
http://tukaani.org/xz/
|
2002-12-03 01:47:26 -04:00
|
|
|
_ssl
|
2014-10-26 01:05:06 -03:00
|
|
|
Python wrapper for version 1.0.1j of the OpenSSL secure sockets
|
2013-10-25 04:58:16 -03:00
|
|
|
library, which is built by ssl.vcxproj
|
|
|
|
Homepage:
|
|
|
|
http://www.openssl.org/
|
|
|
|
|
|
|
|
Building OpenSSL requires nasm.exe (the Netwide Assembler), version
|
|
|
|
2.10 or newer from
|
|
|
|
http://www.nasm.us/
|
|
|
|
to be somewhere on your PATH. More recent versions of OpenSSL may
|
|
|
|
need a later version of NASM. If OpenSSL's self tests don't pass,
|
|
|
|
you should first try to update NASM and do a full rebuild of
|
2014-11-01 20:42:46 -03:00
|
|
|
OpenSSL. get_externals.py also downloads a snapshot of NASM, and the
|
2014-11-22 16:54:57 -04:00
|
|
|
libeay and ssleay sub-projects use that version of nasm.exe.
|
2013-10-25 04:58:16 -03:00
|
|
|
|
2014-11-22 16:54:57 -04:00
|
|
|
The libeay/ssleay sub-projects expect your OpenSSL sources to have
|
|
|
|
already been configured and be ready to build. If you get your sources
|
2014-05-09 11:07:50 -03:00
|
|
|
from svn.python.org as suggested in the "Getting External Sources"
|
|
|
|
section below, the OpenSSL source will already be ready to go. If
|
|
|
|
you want to build a different version, you will need to run
|
|
|
|
|
|
|
|
PCbuild\prepare_ssl.py path\to\openssl-source-dir
|
|
|
|
|
|
|
|
That script will prepare your OpenSSL sources in the same way that
|
|
|
|
those available on svn.python.org have been prepared. Note that
|
|
|
|
Perl must be installed and available on your PATH to configure
|
|
|
|
OpenSSL. ActivePerl is recommended and is available from
|
2010-10-28 14:57:25 -03:00
|
|
|
http://www.activestate.com/activeperl/
|
2002-12-03 01:47:26 -04:00
|
|
|
|
2014-11-22 16:54:57 -04:00
|
|
|
The libeay and ssleay sub-projects will build the modules of OpenSSL
|
|
|
|
required by _ssl and _hashlib and may need to be manually updated when
|
|
|
|
upgrading to a newer version of OpenSSL or when adding new
|
|
|
|
functionality to _ssl or _hashlib. They will not clean up their output
|
|
|
|
with the normal Clean target; CleanAll should be used instead.
|
2013-10-25 04:58:16 -03:00
|
|
|
_sqlite3
|
2014-03-02 14:42:50 -04:00
|
|
|
Wraps SQLite 3.8.3.1, which is itself built by sqlite3.vcxproj
|
2013-10-25 04:58:16 -03:00
|
|
|
Homepage:
|
|
|
|
http://www.sqlite.org/
|
|
|
|
_tkinter
|
2013-11-23 18:05:27 -04:00
|
|
|
Wraps version 8.6.1 of the Tk windowing system.
|
2013-10-25 04:58:16 -03:00
|
|
|
Homepage:
|
|
|
|
http://www.tcl.tk/
|
|
|
|
|
2014-03-22 00:58:19 -03:00
|
|
|
Tkinter's dependencies are built by the tcl.vcxproj and tk.vcxproj
|
|
|
|
projects. The tix.vcxproj project also builds the Tix extended
|
|
|
|
widget set for use with Tkinter.
|
|
|
|
|
|
|
|
Those three projects install their respective components in a
|
|
|
|
directory alongside the source directories called "tcltk" on
|
|
|
|
Win32 and "tcltk64" on x64. They also copy the Tcl and Tk DLLs
|
|
|
|
into the current output directory, which should ensure that Tkinter
|
|
|
|
is able to load Tcl/Tk without having to change your PATH.
|
|
|
|
|
2014-11-22 16:54:57 -04:00
|
|
|
The tcl, tk, and tix sub-projects do not clean their builds with
|
|
|
|
the normal Clean target; if you need to rebuild, you should use the
|
|
|
|
CleanAll target or manually delete their builds.
|
2000-06-30 21:03:43 -03:00
|
|
|
|
2008-04-02 12:06:49 -03:00
|
|
|
|
2013-10-25 04:58:16 -03:00
|
|
|
Getting External Sources
|
|
|
|
------------------------
|
2008-04-02 12:06:49 -03:00
|
|
|
|
2013-10-25 04:58:16 -03:00
|
|
|
The last category of sub-projects listed above wrap external projects
|
|
|
|
Python doesn't control, and as such a little more work is required in
|
|
|
|
order to download the relevant source files for each project before they
|
2014-07-07 15:39:59 -03:00
|
|
|
can be built. However, a simple script is provided to make this as
|
|
|
|
painless as possible, called "get_externals.bat" and located in this
|
|
|
|
directory. This script extracts all the external sub-projects from
|
2013-10-25 04:58:16 -03:00
|
|
|
http://svn.python.org/projects/external
|
2014-07-07 15:39:59 -03:00
|
|
|
via Subversion (so you'll need svn.exe on your PATH) and places them
|
2014-11-02 00:39:21 -03:00
|
|
|
in ..\externals (relative to this directory).
|
2013-10-25 04:58:16 -03:00
|
|
|
|
|
|
|
It is also possible to download sources from each project's homepage,
|
2014-07-07 15:39:59 -03:00
|
|
|
though you may have to change folder names or pass the names to MSBuild
|
|
|
|
as the values of certain properties in order for the build solution to
|
|
|
|
find them. This is an advanced topic and not necessarily fully
|
|
|
|
supported.
|
2013-10-25 04:58:16 -03:00
|
|
|
|
2004-07-20 11:37:48 -03:00
|
|
|
|
2006-02-14 16:42:55 -04:00
|
|
|
Building for AMD64
|
|
|
|
------------------
|
|
|
|
|
2013-10-25 04:58:16 -03:00
|
|
|
The build process for AMD64 / x64 is very similar to standard builds,
|
|
|
|
you just have to set x64 as platform. In addition, the HOST_PYTHON
|
|
|
|
environment variable must point to a Python interpreter (at least 2.4),
|
2014-11-22 16:54:57 -04:00
|
|
|
to support cross-compilation from Win32.
|
2006-04-21 07:40:58 -03:00
|
|
|
|
Merged revisions 59605-59624 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r59606 | georg.brandl | 2007-12-29 11:57:00 +0100 (Sat, 29 Dec 2007) | 2 lines
Some cleanup in the docs.
........
r59611 | martin.v.loewis | 2007-12-29 19:49:21 +0100 (Sat, 29 Dec 2007) | 2 lines
Bug #1699: Define _BSD_SOURCE only on OpenBSD.
........
r59612 | raymond.hettinger | 2007-12-29 23:09:34 +0100 (Sat, 29 Dec 2007) | 1 line
Simpler documentation for itertools.tee(). Should be backported.
........
r59613 | raymond.hettinger | 2007-12-29 23:16:24 +0100 (Sat, 29 Dec 2007) | 1 line
Improve docs for itertools.groupby(). The use of xrange(0) to create a unique object is less obvious than object().
........
r59620 | christian.heimes | 2007-12-31 15:47:07 +0100 (Mon, 31 Dec 2007) | 3 lines
Added wininst-9.0.exe executable for VS 2008
Integrated bdist_wininst into PCBuild9 directory
........
r59621 | christian.heimes | 2007-12-31 15:51:18 +0100 (Mon, 31 Dec 2007) | 1 line
Moved PCbuild directory to PC/VS7.1
........
r59622 | christian.heimes | 2007-12-31 15:59:26 +0100 (Mon, 31 Dec 2007) | 1 line
Fix paths for build bot
........
r59623 | christian.heimes | 2007-12-31 16:02:41 +0100 (Mon, 31 Dec 2007) | 1 line
Fix paths for build bot, part 2
........
r59624 | christian.heimes | 2007-12-31 16:18:55 +0100 (Mon, 31 Dec 2007) | 1 line
Renamed PCBuild9 directory to PCBuild
........
2007-12-31 12:14:33 -04:00
|
|
|
|
|
|
|
Profile Guided Optimization
|
|
|
|
---------------------------
|
|
|
|
|
Merged revisions 59883-59920 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r59887 | neal.norwitz | 2008-01-10 06:42:58 +0100 (Thu, 10 Jan 2008) | 1 line
Reword entry, not sure I made it much better though.
........
r59888 | andrew.kuchling | 2008-01-10 14:37:12 +0100 (Thu, 10 Jan 2008) | 1 line
Check for fd of -1 to save fsync() and fstat() call
........
r59891 | thomas.heller | 2008-01-10 19:45:40 +0100 (Thu, 10 Jan 2008) | 1 line
Reflow a paragraph, and fix a typo.
........
r59892 | raymond.hettinger | 2008-01-10 20:15:10 +0100 (Thu, 10 Jan 2008) | 1 line
Examples for named tuple subclassing should include __slots__
........
r59895 | raymond.hettinger | 2008-01-10 21:37:12 +0100 (Thu, 10 Jan 2008) | 1 line
Clarify how to add a field to a named tuple.
........
r59896 | amaury.forgeotdarc | 2008-01-10 22:59:42 +0100 (Thu, 10 Jan 2008) | 12 lines
Closing issue1761.
Surprising behaviour of the "$" regexp: it matches the
end of the string, AND just before the newline at the end
of the string::
re.sub('$', '#', 'foo\n') == 'foo#\n#'
Python is consistent with Perl and the pcre library, so
we just document it.
Guido prefers "\Z" to match only the end of the string.
........
r59898 | raymond.hettinger | 2008-01-11 00:00:01 +0100 (Fri, 11 Jan 2008) | 1 line
Neaten-up the named tuple docs
........
r59900 | raymond.hettinger | 2008-01-11 01:23:13 +0100 (Fri, 11 Jan 2008) | 1 line
Run doctests on the collections module
........
r59903 | raymond.hettinger | 2008-01-11 02:25:54 +0100 (Fri, 11 Jan 2008) | 1 line
Doctest results return a named tuple for readability
........
r59904 | raymond.hettinger | 2008-01-11 03:12:33 +0100 (Fri, 11 Jan 2008) | 1 line
Comment-out missing constant (from rev 59819)
........
r59905 | raymond.hettinger | 2008-01-11 03:24:13 +0100 (Fri, 11 Jan 2008) | 1 line
Have Decimal.as_tuple return a named tuple.
........
r59906 | raymond.hettinger | 2008-01-11 04:04:50 +0100 (Fri, 11 Jan 2008) | 1 line
Let most inspect functions return named tuples
........
r59907 | raymond.hettinger | 2008-01-11 04:20:54 +0100 (Fri, 11 Jan 2008) | 1 line
Improve usability of the SequenceMatcher by returning named tuples describing match ranges.
........
r59909 | thomas.heller | 2008-01-11 09:04:03 +0100 (Fri, 11 Jan 2008) | 1 line
Add an important missing blank.
........
r59910 | georg.brandl | 2008-01-11 10:19:11 +0100 (Fri, 11 Jan 2008) | 2 lines
Guard definition of TIPC_SUB_CANCEL with an #ifdef.
........
r59911 | georg.brandl | 2008-01-11 10:20:58 +0100 (Fri, 11 Jan 2008) | 2 lines
News entries for rev. 5990[567].
........
r59912 | georg.brandl | 2008-01-11 10:55:53 +0100 (Fri, 11 Jan 2008) | 2 lines
Documentation for r5990[3567].
........
r59913 | thomas.heller | 2008-01-11 13:41:39 +0100 (Fri, 11 Jan 2008) | 4 lines
The sqlite3 dll, when compiled in debug mode, must be linked with /MDd
to use the debug runtime library. Further, the dll will be named
sqlite3_d.dll.
........
r59919 | thomas.heller | 2008-01-11 16:38:46 +0100 (Fri, 11 Jan 2008) | 6 lines
Revert revision 59913, because it was wrong:
The sqlite3 dll, when compiled in debug mode, must be linked with
/MDd to use the debug runtime library. Further, the dll will be
named sqlite3_d.dll.
........
r59920 | christian.heimes | 2008-01-11 16:42:29 +0100 (Fri, 11 Jan 2008) | 1 line
Removed unused variable
........
2008-01-11 12:17:00 -04:00
|
|
|
The solution has two configurations for PGO. The PGInstrument
|
2013-10-25 04:58:16 -03:00
|
|
|
configuration must be built first. The PGInstrument binaries are linked
|
|
|
|
against a profiling library and contain extra debug information. The
|
|
|
|
PGUpdate configuration takes the profiling data and generates optimized
|
|
|
|
binaries.
|
Merged revisions 59605-59624 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r59606 | georg.brandl | 2007-12-29 11:57:00 +0100 (Sat, 29 Dec 2007) | 2 lines
Some cleanup in the docs.
........
r59611 | martin.v.loewis | 2007-12-29 19:49:21 +0100 (Sat, 29 Dec 2007) | 2 lines
Bug #1699: Define _BSD_SOURCE only on OpenBSD.
........
r59612 | raymond.hettinger | 2007-12-29 23:09:34 +0100 (Sat, 29 Dec 2007) | 1 line
Simpler documentation for itertools.tee(). Should be backported.
........
r59613 | raymond.hettinger | 2007-12-29 23:16:24 +0100 (Sat, 29 Dec 2007) | 1 line
Improve docs for itertools.groupby(). The use of xrange(0) to create a unique object is less obvious than object().
........
r59620 | christian.heimes | 2007-12-31 15:47:07 +0100 (Mon, 31 Dec 2007) | 3 lines
Added wininst-9.0.exe executable for VS 2008
Integrated bdist_wininst into PCBuild9 directory
........
r59621 | christian.heimes | 2007-12-31 15:51:18 +0100 (Mon, 31 Dec 2007) | 1 line
Moved PCbuild directory to PC/VS7.1
........
r59622 | christian.heimes | 2007-12-31 15:59:26 +0100 (Mon, 31 Dec 2007) | 1 line
Fix paths for build bot
........
r59623 | christian.heimes | 2007-12-31 16:02:41 +0100 (Mon, 31 Dec 2007) | 1 line
Fix paths for build bot, part 2
........
r59624 | christian.heimes | 2007-12-31 16:18:55 +0100 (Mon, 31 Dec 2007) | 1 line
Renamed PCBuild9 directory to PCBuild
........
2007-12-31 12:14:33 -04:00
|
|
|
|
2013-10-25 04:58:16 -03:00
|
|
|
The build_pgo.bat script automates the creation of optimized binaries.
|
|
|
|
It creates the PGI files, runs the unit test suite or PyBench with the
|
|
|
|
PGI python, and finally creates the optimized files.
|
|
|
|
|
|
|
|
See
|
|
|
|
http://msdn.microsoft.com/en-us/library/e7k32f4k(VS.100).aspx
|
|
|
|
for more on this topic.
|
Merged revisions 59605-59624 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r59606 | georg.brandl | 2007-12-29 11:57:00 +0100 (Sat, 29 Dec 2007) | 2 lines
Some cleanup in the docs.
........
r59611 | martin.v.loewis | 2007-12-29 19:49:21 +0100 (Sat, 29 Dec 2007) | 2 lines
Bug #1699: Define _BSD_SOURCE only on OpenBSD.
........
r59612 | raymond.hettinger | 2007-12-29 23:09:34 +0100 (Sat, 29 Dec 2007) | 1 line
Simpler documentation for itertools.tee(). Should be backported.
........
r59613 | raymond.hettinger | 2007-12-29 23:16:24 +0100 (Sat, 29 Dec 2007) | 1 line
Improve docs for itertools.groupby(). The use of xrange(0) to create a unique object is less obvious than object().
........
r59620 | christian.heimes | 2007-12-31 15:47:07 +0100 (Mon, 31 Dec 2007) | 3 lines
Added wininst-9.0.exe executable for VS 2008
Integrated bdist_wininst into PCBuild9 directory
........
r59621 | christian.heimes | 2007-12-31 15:51:18 +0100 (Mon, 31 Dec 2007) | 1 line
Moved PCbuild directory to PC/VS7.1
........
r59622 | christian.heimes | 2007-12-31 15:59:26 +0100 (Mon, 31 Dec 2007) | 1 line
Fix paths for build bot
........
r59623 | christian.heimes | 2007-12-31 16:02:41 +0100 (Mon, 31 Dec 2007) | 1 line
Fix paths for build bot, part 2
........
r59624 | christian.heimes | 2007-12-31 16:18:55 +0100 (Mon, 31 Dec 2007) | 1 line
Renamed PCBuild9 directory to PCBuild
........
2007-12-31 12:14:33 -04:00
|
|
|
|
|
|
|
|
|
|
|
Static library
|
|
|
|
--------------
|
|
|
|
|
2013-10-25 04:58:16 -03:00
|
|
|
The solution has no configuration for static libraries. However it is
|
|
|
|
easy to build a static library instead of a DLL. You simply have to set
|
|
|
|
the "Configuration Type" to "Static Library (.lib)" and alter the
|
|
|
|
preprocessor macro "Py_ENABLE_SHARED" to "Py_NO_ENABLE_SHARED". You may
|
|
|
|
also have to change the "Runtime Library" from "Multi-threaded DLL
|
|
|
|
(/MD)" to "Multi-threaded (/MT)".
|
|
|
|
|
Merged revisions 59605-59624 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r59606 | georg.brandl | 2007-12-29 11:57:00 +0100 (Sat, 29 Dec 2007) | 2 lines
Some cleanup in the docs.
........
r59611 | martin.v.loewis | 2007-12-29 19:49:21 +0100 (Sat, 29 Dec 2007) | 2 lines
Bug #1699: Define _BSD_SOURCE only on OpenBSD.
........
r59612 | raymond.hettinger | 2007-12-29 23:09:34 +0100 (Sat, 29 Dec 2007) | 1 line
Simpler documentation for itertools.tee(). Should be backported.
........
r59613 | raymond.hettinger | 2007-12-29 23:16:24 +0100 (Sat, 29 Dec 2007) | 1 line
Improve docs for itertools.groupby(). The use of xrange(0) to create a unique object is less obvious than object().
........
r59620 | christian.heimes | 2007-12-31 15:47:07 +0100 (Mon, 31 Dec 2007) | 3 lines
Added wininst-9.0.exe executable for VS 2008
Integrated bdist_wininst into PCBuild9 directory
........
r59621 | christian.heimes | 2007-12-31 15:51:18 +0100 (Mon, 31 Dec 2007) | 1 line
Moved PCbuild directory to PC/VS7.1
........
r59622 | christian.heimes | 2007-12-31 15:59:26 +0100 (Mon, 31 Dec 2007) | 1 line
Fix paths for build bot
........
r59623 | christian.heimes | 2007-12-31 16:02:41 +0100 (Mon, 31 Dec 2007) | 1 line
Fix paths for build bot, part 2
........
r59624 | christian.heimes | 2007-12-31 16:18:55 +0100 (Mon, 31 Dec 2007) | 1 line
Renamed PCBuild9 directory to PCBuild
........
2007-12-31 12:14:33 -04:00
|
|
|
|
|
|
|
Visual Studio properties
|
|
|
|
------------------------
|
|
|
|
|
2014-11-22 16:54:57 -04:00
|
|
|
The PCbuild solution makes use of Visual Studio property files (*.props)
|
|
|
|
to simplify each project. The properties can be viewed in the Property
|
|
|
|
Manager (View -> Other Windows -> Property Manager) but should be
|
|
|
|
carefully modified by hand.
|
|
|
|
|
|
|
|
The property files used are:
|
|
|
|
* python (versions, directories and build names)
|
|
|
|
* pyproject (base settings for all projects)
|
|
|
|
* openssl (used by libeay and ssleay projects)
|
2014-03-29 01:36:43 -03:00
|
|
|
* tcltk (used by _tkinter, tcl, tk and tix projects)
|
Merged revisions 59605-59624 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r59606 | georg.brandl | 2007-12-29 11:57:00 +0100 (Sat, 29 Dec 2007) | 2 lines
Some cleanup in the docs.
........
r59611 | martin.v.loewis | 2007-12-29 19:49:21 +0100 (Sat, 29 Dec 2007) | 2 lines
Bug #1699: Define _BSD_SOURCE only on OpenBSD.
........
r59612 | raymond.hettinger | 2007-12-29 23:09:34 +0100 (Sat, 29 Dec 2007) | 1 line
Simpler documentation for itertools.tee(). Should be backported.
........
r59613 | raymond.hettinger | 2007-12-29 23:16:24 +0100 (Sat, 29 Dec 2007) | 1 line
Improve docs for itertools.groupby(). The use of xrange(0) to create a unique object is less obvious than object().
........
r59620 | christian.heimes | 2007-12-31 15:47:07 +0100 (Mon, 31 Dec 2007) | 3 lines
Added wininst-9.0.exe executable for VS 2008
Integrated bdist_wininst into PCBuild9 directory
........
r59621 | christian.heimes | 2007-12-31 15:51:18 +0100 (Mon, 31 Dec 2007) | 1 line
Moved PCbuild directory to PC/VS7.1
........
r59622 | christian.heimes | 2007-12-31 15:59:26 +0100 (Mon, 31 Dec 2007) | 1 line
Fix paths for build bot
........
r59623 | christian.heimes | 2007-12-31 16:02:41 +0100 (Mon, 31 Dec 2007) | 1 line
Fix paths for build bot, part 2
........
r59624 | christian.heimes | 2007-12-31 16:18:55 +0100 (Mon, 31 Dec 2007) | 1 line
Renamed PCBuild9 directory to PCBuild
........
2007-12-31 12:14:33 -04:00
|
|
|
|
2014-11-22 16:54:57 -04:00
|
|
|
The pyproject property file defines all of the build settings for each
|
|
|
|
project, with some projects overriding certain specific values. The GUI
|
|
|
|
doesn't always reflect the correct settings and may confuse the user
|
|
|
|
with false information, especially for settings that automatically adapt
|
|
|
|
for diffirent configurations.
|
2013-10-25 04:58:16 -03:00
|
|
|
|
2006-04-21 07:40:58 -03:00
|
|
|
|
2013-10-25 04:58:16 -03:00
|
|
|
Your Own Extension DLLs
|
2000-06-30 21:03:43 -03:00
|
|
|
-----------------------
|
Merged revisions 59605-59624 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r59606 | georg.brandl | 2007-12-29 11:57:00 +0100 (Sat, 29 Dec 2007) | 2 lines
Some cleanup in the docs.
........
r59611 | martin.v.loewis | 2007-12-29 19:49:21 +0100 (Sat, 29 Dec 2007) | 2 lines
Bug #1699: Define _BSD_SOURCE only on OpenBSD.
........
r59612 | raymond.hettinger | 2007-12-29 23:09:34 +0100 (Sat, 29 Dec 2007) | 1 line
Simpler documentation for itertools.tee(). Should be backported.
........
r59613 | raymond.hettinger | 2007-12-29 23:16:24 +0100 (Sat, 29 Dec 2007) | 1 line
Improve docs for itertools.groupby(). The use of xrange(0) to create a unique object is less obvious than object().
........
r59620 | christian.heimes | 2007-12-31 15:47:07 +0100 (Mon, 31 Dec 2007) | 3 lines
Added wininst-9.0.exe executable for VS 2008
Integrated bdist_wininst into PCBuild9 directory
........
r59621 | christian.heimes | 2007-12-31 15:51:18 +0100 (Mon, 31 Dec 2007) | 1 line
Moved PCbuild directory to PC/VS7.1
........
r59622 | christian.heimes | 2007-12-31 15:59:26 +0100 (Mon, 31 Dec 2007) | 1 line
Fix paths for build bot
........
r59623 | christian.heimes | 2007-12-31 16:02:41 +0100 (Mon, 31 Dec 2007) | 1 line
Fix paths for build bot, part 2
........
r59624 | christian.heimes | 2007-12-31 16:18:55 +0100 (Mon, 31 Dec 2007) | 1 line
Renamed PCBuild9 directory to PCBuild
........
2007-12-31 12:14:33 -04:00
|
|
|
|
2013-10-25 04:58:16 -03:00
|
|
|
If you want to create your own extension module DLL (.pyd), there's an
|
|
|
|
example with easy-to-follow instructions in ..\PC\example\; read the
|
|
|
|
file readme.txt there first.
|