[prev in list] [next in list] [prev in thread] [next in thread] 

List:       python-cpp-sig
Subject:    Re: [C++-sig] Trouble building boost with Visual Studio 2010
From:       David Aldrich <David.Aldrich () EMEA ! NEC ! COM>
Date:       2016-03-10 15:54:47
Message-ID: 41302A7145AC054FA7A96CFD03835A0A0BAAAC39 () EX10MBX02 ! EU ! NEC ! COM
[Download RAW message or body]

Hi Liam

Thanks for your reply and help. I'm going to try using the pre-built libraries \
instead.

Best regards

David

From: Cplusplus-sig [mailto:cplusplus-sig-bounces+david.aldrich=emea.nec.com@python.org] \
                On Behalf Of Liam Herron
Sent: 10 March 2016 15:39
To: Development of Python/C++ integration <cplusplus-sig@python.org>
Subject: Re: [C++-sig] Trouble building boost with Visual Studio 2010

Unfortunately, I don't have python3 installed on my computer so I never had to deal \
with this.     My only suggestion is to hack the "libs/python/build/Jamfile.v2"  file \
to get it to work. Sorry I can't be of more help :(

--Liam

From: Cplusplus-sig [mailto:cplusplus-sig-bounces+herron=ellington.com@python.org] On \
                Behalf Of David Aldrich
Sent: Thursday, March 10, 2016 7:21 AM
To: Development of Python/C++ integration
Subject: Re: [C++-sig] Trouble building boost with Visual Studio 2010

Thanks for your reply. I have set my path to start with Python 2.7:

PATH=c:\Python27;C:\Program Files (x86)\Microsoft Visual Studio \
10.0\VSTSDB\Deploy;C:\Program Files (x86)\Microsoft Visual Studio \
10.0\Common7\IDE\;c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\BIN; etc.

I have created a user-config.jam:

using msvc ;

using python
    : 2.7                   # Version
    : C:\\Python27\\python.exe      # Python Path
    : C:\\Python27\\include         # include path
    : C:\\Python27\\libs            # lib path(s)
    : <define>BOOST_ALL_NO_LIB=1
    ;

I then invoke bjam:

b2 --user-config=user-config.jam toolset=msvc-10.0 --with-python link=shared

but it is still trying to use Python 3.4:

...patience...
...patience...
...found 1927 targets...
...updating 9 targets...
msvc.link.dll bin.v2\libs\python\build\msvc-10.0\debug\threading-multi\boost_python-vc100-mt-gd-1_60.dll
 LINK : fatal error LNK1104: cannot open file 'python34.lib'

Any thought please why it's still choosing Python 3.4 instead of 2.7 please?

Best regards

David

From: Cplusplus-sig [mailto:cplusplus-sig-bounces+david.aldrich=emea.nec.com@python.org] \
                On Behalf Of Liam Herron
Sent: 09 March 2016 17:03
To: Development of Python/C++ integration \
                <cplusplus-sig@python.org<mailto:cplusplus-sig@python.org>>
Subject: Re: [C++-sig] Trouble building boost with Visual Studio 2010

After you open the cmd shell, just change the PATH for that cmd shell and then run \
the build.

From: Cplusplus-sig [mailto:cplusplus-sig-bounces+herron=ellington.com@python.org] On \
                Behalf Of David Aldrich
Sent: Wednesday, March 09, 2016 11:59 AM
To: Development of Python/C++ integration
Subject: Re: [C++-sig] Trouble building boost with Visual Studio 2010

Ok, thanks. The console defaults to 3.5, which is the problem.

I'll see what I can do.

From: Cplusplus-sig [mailto:cplusplus-sig-bounces+david.aldrich=emea.nec.com@python.org] \
                On Behalf Of Liam Herron
Sent: 09 March 2016 16:52
To: Development of Python/C++ integration \
                <cplusplus-sig@python.org<mailto:cplusplus-sig@python.org>>
Subject: Re: [C++-sig] Trouble building boost with Visual Studio 2010

I believe if you don't specify a python directly in the config files, it will simply \
use whatever python it picks up with the "python" cmd.  When you open a cmd shell and \
simply type "python", which version does it run?  If you get this to be your 32-bit \
version, I think it will work. Else, you can muck around with the  "jam" files to try \
to point it to the python version you want.

--Liam

From: Cplusplus-sig [mailto:cplusplus-sig-bounces+herron=ellington.com@python.org] On \
                Behalf Of David Aldrich
Sent: Wednesday, March 09, 2016 11:35 AM
To: Development of Python/C++ integration
Subject: Re: [C++-sig] Trouble building boost with Visual Studio 2010

Hi Liam

I have Python 2.7 (32-bit) and Python 3.4 (64-bit) installed on my Win 10 system. As \
you suggested I opened a VS2010 command prompt (I believe 32-bit), executed bootstrap \
and then:

b2 toolset=msvc-10.0 --with-python link=shared

I still see this error:

msvc.link.dll bin.v2\libs\python\build\msvc-10.0\release\threading-multi\boost_python-vc100-mt-1_60.dll
 python34.lib(python34.dll) : fatal error LNK1112: module machine type 'x64' \
conflicts with target machine type 'X86'

So it seems to be picking up python34.lib in preference to python27.lib

Do you think this just depends on the path order?

David

From: Cplusplus-sig [mailto:cplusplus-sig-bounces+david.aldrich=emea.nec.com@python.org] \
                On Behalf Of Liam Herron
Sent: 09 March 2016 14:40
To: Development of Python/C++ integration \
                <cplusplus-sig@python.org<mailto:cplusplus-sig@python.org>>
Subject: Re: [C++-sig] Trouble building boost with Visual Studio 2010

You should open a cmd shell tool that comes with VS :
     e.g. "VS2010 x86 Native Tools Command Prompt"
       or "VS2010 x64 Native Tools Command Prompt"

And then in this shell, run your:

b2 toolset=msvc-10.0 --with-python link=shared

It looks like your python version is 64-bit python (Is that true?) so maybe you want \
to build the 64bit cmd shell that will build the 64 bit version of boost and boost \
python.

If you want the build 32bit version, make sure you have a 32 bit version of python \
and python libs and then use the x86 cmd shell to build the 32 bit version of boost \
and boost python.

Hope that helps.
--Liam


From: Cplusplus-sig [mailto:cplusplus-sig-bounces+herron=ellington.com@python.org] On \
                Behalf Of David Aldrich
Sent: Wednesday, March 09, 2016 5:05 AM
To: Development of Python/C++ integration
Subject: [C++-sig] Trouble building boost with Visual Studio 2010

Hi

I am trying to build Boost 1.60 with Visual Studio 2010 Professional on Windows 10.

I use the command:

b2 toolset=msvc-10.0 --with-python link=shared

and get the following error:

python34.lib(python34.dll) : fatal error LNK1112: module machine type 'x64' conflicts \
with target machine type 'X86'

I guess this means I have a conflict of 32-bit and 64-bit libraries.  I want to \
target 32-bit (X86).

Do I need to install a 32-bit version of Python?  I wonder if that can co-exist with \
the current version of Python?

Best regards

David


=============================================================================================
 Email transmissions can not be guaranteed to be secure or error-free, as information \
could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or \
contain viruses. The sender therefore does not accept liability for any errors or \
omissions in the contents of this message which arise as a result of email \
transmission. In addition, the information contained in this email message is \
intended only for use of the individual or entity named above. If the reader of this \
message is not the intended recipient, or the employee or agent responsible to \
deliver it to the intended recipient, you are hereby notified that any dissemination, \
distribution,or copying of this communication, disclosure of the parties to it, or \
any action taken or omitted to be taken in reliance on it, is strictly prohibited, \
and may be unlawful. If you are not the intended recipient please delete this email \
message. ============================================================================================== \


Click here<https://www.mailcontrol.com/sr/VIdq9eIbFJ3GX2PQPOmvUiQSa3+T5MHvzY1DQvi2lw+FqzJbzBJIALiBTIHiUs7caaqy85oZ6mcgL4AI7al!HQ==> \
to report this email as spam.


[Attachment #3 (text/html)]

<html xmlns:v="urn:schemas-microsoft-com:vml" \
xmlns:o="urn:schemas-microsoft-com:office:office" \
xmlns:w="urn:schemas-microsoft-com:office:word" \
xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" \
xmlns="http://www.w3.org/TR/REC-html40"> <head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
	{font-family:Wingdings;
	panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
	{font-family:"Cambria Math";
	panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
	{font-family:Calibri;
	panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
	{font-family:Tahoma;
	panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
	{margin:0cm;
	margin-bottom:.0001pt;
	font-size:11.0pt;
	font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
	{mso-style-priority:99;
	color:#0563C1;
	text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
	{mso-style-priority:99;
	color:#954F72;
	text-decoration:underline;}
p
	{mso-style-priority:99;
	mso-margin-top-alt:auto;
	margin-right:0cm;
	mso-margin-bottom-alt:auto;
	margin-left:0cm;
	font-size:12.0pt;
	font-family:"Times New Roman",serif;}
p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
	{mso-style-priority:99;
	mso-style-link:"Balloon Text Char";
	margin:0cm;
	margin-bottom:.0001pt;
	font-size:8.0pt;
	font-family:"Tahoma",sans-serif;}
span.BalloonTextChar
	{mso-style-name:"Balloon Text Char";
	mso-style-priority:99;
	mso-style-link:"Balloon Text";
	font-family:"Tahoma",sans-serif;}
span.EmailStyle20
	{mso-style-type:personal;
	font-family:"Calibri",sans-serif;
	color:windowtext;}
span.EmailStyle21
	{mso-style-type:personal;
	font-family:"Calibri",sans-serif;
	color:#1F497D;}
span.EmailStyle22
	{mso-style-type:personal;
	font-family:"Calibri",sans-serif;
	color:#1F497D;}
span.EmailStyle23
	{mso-style-type:personal;
	font-family:"Calibri",sans-serif;
	color:#1F497D;}
span.EmailStyle24
	{mso-style-type:personal;
	font-family:"Calibri",sans-serif;
	color:#1F497D;}
span.EmailStyle25
	{mso-style-type:personal;
	font-family:"Calibri",sans-serif;
	color:#1F497D;}
span.EmailStyle26
	{mso-style-type:personal;
	font-family:"Calibri",sans-serif;
	color:#1F497D;}
span.EmailStyle27
	{mso-style-type:personal;
	font-family:"Calibri",sans-serif;
	color:#1F497D;}
span.EmailStyle28
	{mso-style-type:personal-reply;
	font-family:"Calibri",sans-serif;
	color:#1F497D;}
.MsoChpDefault
	{mso-style-type:export-only;
	font-size:10.0pt;}
@page WordSection1
	{size:612.0pt 792.0pt;
	margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
	{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-GB" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal"><span style="color:#1F497D;mso-fareast-language:EN-US">Hi \
Liam<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D;mso-fareast-language:EN-US"><o:p>&nbsp;</o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D;mso-fareast-language:EN-US">Thanks for \
your reply and help. I&#8217;m going to try using the pre-built libraries \
instead.<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D;mso-fareast-language:EN-US"><o:p>&nbsp;</o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D;mso-fareast-language:EN-US">Best regards \
<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D;mso-fareast-language:EN-US"><o:p>&nbsp;</o:p></span></p> <p \
class="MsoNormal"><span \
style="color:#1F497D;mso-fareast-language:EN-US">David<o:p></o:p></span></p> <p \
class="MsoNormal"><span \
style="color:#1F497D;mso-fareast-language:EN-US"><o:p>&nbsp;</o:p></span></p> <div \
style="border:none;border-left:solid blue 1.5pt;padding:0cm 0cm 0cm 4.0pt"> <div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US">From:</span></b><span lang="EN-US"> \
Cplusplus-sig [mailto:cplusplus-sig-bounces&#43;david.aldrich=emea.nec.com@python.org]
 <b>On Behalf Of </b>Liam Herron<br>
<b>Sent:</b> 10 March 2016 15:39<br>
<b>To:</b> Development of Python/C&#43;&#43; integration \
&lt;cplusplus-sig@python.org&gt;<br> <b>Subject:</b> Re: [C&#43;&#43;-sig] Trouble \
building boost with Visual Studio 2010<o:p></o:p></span></p> </div>
</div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D">Unfortunately, I \
don&#8217;t have python3 installed on my computer so I never had to deal with \
this.&nbsp;&nbsp;&nbsp;&nbsp; My only suggestion is to hack the \
&#8220;libs/python/build/Jamfile.v2&#8221;&nbsp; file to get it to \
work.<o:p></o:p></span></p> <p class="MsoNormal"><span lang="EN-US" \
style="color:#1F497D">Sorry I can&#8217;t be of more help </span><span lang="EN-US" \
style="font-family:Wingdings;color:#1F497D">L</span><span lang="EN-US" \
style="color:#1F497D"><o:p></o:p></span></p> <p class="MsoNormal"><span lang="EN-US" \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
lang="EN-US" style="color:#1F497D">--Liam<o:p></o:p></span></p> <p \
class="MsoNormal"><span lang="EN-US" \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" \
style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,sans-serif">From:</span></b><span \
lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,sans-serif"> \
Cplusplus-sig [<a href="mailto:cplusplus-sig-bounces&#43;herron=ellington.com@python.org">mailto:cplusplus-sig-bounces&#43;herron=ellington.com@python.org</a>]
 <b>On Behalf Of </b>David Aldrich<br>
<b>Sent:</b> Thursday, March 10, 2016 7:21 AM<br>
<b>To:</b> Development of Python/C&#43;&#43; integration<br>
<b>Subject:</b> Re: [C&#43;&#43;-sig] Trouble building boost with Visual Studio \
2010<o:p></o:p></span></p> </div>
</div>
<p class="MsoNormal"><span lang="EN-US"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Thanks for your reply. I have set my \
path to start with Python 2.7:<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">PATH=c:\Python27;C:\Program Files (x86)\Microsoft Visual Studio \
10.0\VSTSDB\Deploy;C:\Program Files (x86)\Microsoft Visual Studio \
10.0\Common7\IDE\;c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\BIN;  \
etc.<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">I have created a user-config.jam:<o:p></o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D">using msvc ;<o:p></o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D">using python<o:p></o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D">&nbsp;&nbsp;&nbsp; : \
2.7&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \
# Version<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">&nbsp;&nbsp;&nbsp; : \
C:\\Python27\\python.exe&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; # Python \
Path<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">&nbsp;&nbsp;&nbsp; : \
C:\\Python27\\include&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; # include \
path<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">&nbsp;&nbsp;&nbsp; : \
C:\\Python27\\libs&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \
# lib path(s)<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">&nbsp;&nbsp;&nbsp; : \
&lt;define&gt;BOOST_ALL_NO_LIB=1<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">&nbsp;&nbsp;&nbsp; ;<o:p></o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D">I then invoke \
bjam:<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">b2 --user-config=user-config.jam toolset=msvc-10.0 \
--with-python link=shared<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">but it is still trying to use Python 3.4:<o:p></o:p></span></p> \
<p class="MsoNormal"><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D">...patience...<o:p></o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D">...patience...<o:p></o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D">...found 1927 \
targets...<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">...updating 9 targets...<o:p></o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D">msvc.link.dll \
bin.v2\libs\python\build\msvc-10.0\debug\threading-multi\boost_python-vc100-mt-gd-1_60.dll<o:p></o:p></span></p>
 <p class="MsoNormal"><span style="color:#1F497D">LINK : fatal error LNK1104: cannot \
open file 'python34.lib'<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">Any thought please why it&#8217;s still choosing Python 3.4 \
instead of 2.7 please?<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">Best regards<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">David<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <div \
style="border:none;border-left:solid blue 1.5pt;padding:0cm 0cm 0cm 4.0pt"> <div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US">From:</span></b><span lang="EN-US"> \
Cplusplus-sig [<a href="mailto:cplusplus-sig-bounces&#43;david.aldrich=emea.nec.com@py \
thon.org">mailto:cplusplus-sig-bounces&#43;david.aldrich=emea.nec.com@python.org</a>] \
<b>On Behalf Of </b>Liam Herron<br> <b>Sent:</b> 09 March 2016 17:03<br>
<b>To:</b> Development of Python/C&#43;&#43; integration &lt;<a \
href="mailto:cplusplus-sig@python.org">cplusplus-sig@python.org</a>&gt;<br> \
<b>Subject:</b> Re: [C&#43;&#43;-sig] Trouble building boost with Visual Studio \
2010<o:p></o:p></span></p> </div>
</div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D">After you open the cmd \
shell, just change the PATH for that cmd shell and then run the \
build.<o:p></o:p></span></p> <p class="MsoNormal"><span lang="EN-US" \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" \
style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,sans-serif">From:</span></b><span \
lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,sans-serif"> \
Cplusplus-sig [<a href="mailto:cplusplus-sig-bounces&#43;herron=ellington.com@python.org">mailto:cplusplus-sig-bounces&#43;herron=ellington.com@python.org</a>]
 <b>On Behalf Of </b>David Aldrich<br>
<b>Sent:</b> Wednesday, March 09, 2016 11:59 AM<br>
<b>To:</b> Development of Python/C&#43;&#43; integration<br>
<b>Subject:</b> Re: [C&#43;&#43;-sig] Trouble building boost with Visual Studio \
2010<o:p></o:p></span></p> </div>
</div>
<p class="MsoNormal"><span lang="EN-US"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Ok, thanks. The console defaults to \
3.5, which is the problem.<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">I&#8217;ll see what I can do.<o:p></o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <div \
style="border:none;border-left:solid blue 1.5pt;padding:0cm 0cm 0cm 4.0pt"> <div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US">From:</span></b><span lang="EN-US"> \
Cplusplus-sig [<a href="mailto:cplusplus-sig-bounces&#43;david.aldrich=emea.nec.com@py \
thon.org">mailto:cplusplus-sig-bounces&#43;david.aldrich=emea.nec.com@python.org</a>] \
<b>On Behalf Of </b>Liam Herron<br> <b>Sent:</b> 09 March 2016 16:52<br>
<b>To:</b> Development of Python/C&#43;&#43; integration &lt;<a \
href="mailto:cplusplus-sig@python.org">cplusplus-sig@python.org</a>&gt;<br> \
<b>Subject:</b> Re: [C&#43;&#43;-sig] Trouble building boost with Visual Studio \
2010<o:p></o:p></span></p> </div>
</div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D">I believe if you \
don&#8217;t specify a python directly in the config files, it will simply use \
whatever python it picks up with the &#8220;python&#8221; cmd.&nbsp; When you open a \
cmd shell and simply type &#8220;python&#8221;, which  version does it run?&nbsp; If \
you get this to be your 32-bit version, I think it will work. Else, you can muck \
around with the &nbsp;&#8220;jam&#8221; files to try to point it to the python \
version you want.<o:p></o:p></span></p> <p class="MsoNormal"><span lang="EN-US" \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
lang="EN-US" style="color:#1F497D">--Liam<o:p></o:p></span></p> <p \
class="MsoNormal"><span lang="EN-US" \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" \
style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,sans-serif">From:</span></b><span \
lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,sans-serif"> \
Cplusplus-sig [<a href="mailto:cplusplus-sig-bounces&#43;herron=ellington.com@python.org">mailto:cplusplus-sig-bounces&#43;herron=ellington.com@python.org</a>]
 <b>On Behalf Of </b>David Aldrich<br>
<b>Sent:</b> Wednesday, March 09, 2016 11:35 AM<br>
<b>To:</b> Development of Python/C&#43;&#43; integration<br>
<b>Subject:</b> Re: [C&#43;&#43;-sig] Trouble building boost with Visual Studio \
2010<o:p></o:p></span></p> </div>
</div>
<p class="MsoNormal"><span lang="EN-US"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Hi Liam<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">I have Python 2.7 (32-bit) and \
Python 3.4 (64-bit) installed on my Win 10 system. As you suggested I opened a VS2010 \
command prompt (I believe 32-bit), executed bootstrap and then:<o:p></o:p></span></p> \
<p class="MsoNormal"><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D">b2 toolset=msvc-10.0 --with-python \
link=shared<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">I still see this error:<o:p></o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p \
class="MsoNormal"><span style="color:#1F497D">msvc.link.dll \
bin.v2\libs\python\build\msvc-10.0\release\threading-multi\boost_python-vc100-mt-1_60.dll<o:p></o:p></span></p>
 <p class="MsoNormal"><span style="color:#1F497D">python34.lib(python34.dll) : fatal \
error LNK1112: module machine type 'x64' conflicts with target machine type \
'X86'<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">So it seems to be picking up python34.lib in preference to \
python27.lib<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">Do you think this just depends on the path \
order?<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D">David<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <div \
style="border:none;border-left:solid blue 1.5pt;padding:0cm 0cm 0cm 4.0pt"> <div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US">From:</span></b><span lang="EN-US"> \
Cplusplus-sig [<a href="mailto:cplusplus-sig-bounces&#43;david.aldrich=emea.nec.com@py \
thon.org">mailto:cplusplus-sig-bounces&#43;david.aldrich=emea.nec.com@python.org</a>] \
<b>On Behalf Of </b>Liam Herron<br> <b>Sent:</b> 09 March 2016 14:40<br>
<b>To:</b> Development of Python/C&#43;&#43; integration &lt;<a \
href="mailto:cplusplus-sig@python.org">cplusplus-sig@python.org</a>&gt;<br> \
<b>Subject:</b> Re: [C&#43;&#43;-sig] Trouble building boost with Visual Studio \
2010<o:p></o:p></span></p> </div>
</div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D">You should open a cmd \
shell tool that comes with VS :<o:p></o:p></span></p> <p class="MsoNormal"><span \
lang="EN-US" style="color:#1F497D">&nbsp;&nbsp;&nbsp;&nbsp; e.g. &#8220;VS2010 x86 \
Native Tools Command Prompt&#8221;<o:p></o:p></span></p> <p class="MsoNormal"><span \
lang="EN-US" style="color:#1F497D">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; or \
&#8220;VS2010 x64 Native Tools Command Prompt&#8221;<o:p></o:p></span></p> <p \
class="MsoNormal"><span lang="EN-US" \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
lang="EN-US" style="color:#1F497D">And then in this shell, run \
your:<o:p></o:p></span></p> <p class="MsoNormal"><span lang="EN-US" \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal">b2 \
toolset=msvc-10.0 --with-python link=shared<span lang="EN-US" \
style="color:#1F497D"><o:p></o:p></span></p> <p class="MsoNormal"><span lang="EN-US" \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
lang="EN-US" style="color:#1F497D">It looks like your python version is 64-bit python \
(Is that true?) so maybe you want to build the 64bit cmd shell that will build the 64 \
bit version of boost and boost python.<o:p></o:p></span></p> <p \
class="MsoNormal"><span lang="EN-US" \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
lang="EN-US" style="color:#1F497D">If you want the build 32bit version, make sure you \
have a 32 bit version of python and python libs and then use the x86 cmd shell to \
build the 32 bit version of boost and boost python.<o:p></o:p></span></p> <p \
class="MsoNormal"><span lang="EN-US" \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
lang="EN-US" style="color:#1F497D">Hope that helps.<o:p></o:p></span></p> <p \
class="MsoNormal"><span lang="EN-US" \
style="color:#1F497D">--Liam<o:p></o:p></span></p> <p class="MsoNormal"><span \
lang="EN-US" style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <p \
class="MsoNormal"><span lang="EN-US" \
style="color:#1F497D"><o:p>&nbsp;</o:p></span></p> <div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" \
style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,sans-serif">From:</span></b><span \
lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,sans-serif"> \
Cplusplus-sig [<a href="mailto:cplusplus-sig-bounces&#43;herron=ellington.com@python.org">mailto:cplusplus-sig-bounces&#43;herron=ellington.com@python.org</a>]
 <b>On Behalf Of </b>David Aldrich<br>
<b>Sent:</b> Wednesday, March 09, 2016 5:05 AM<br>
<b>To:</b> Development of Python/C&#43;&#43; integration<br>
<b>Subject:</b> [C&#43;&#43;-sig] Trouble building boost with Visual Studio \
2010<o:p></o:p></span></p> </div>
</div>
<p class="MsoNormal"><span lang="EN-US"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal">Hi<o:p></o:p></p>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal">I am trying to build Boost 1.60 with Visual Studio 2010 \
Professional on Windows 10.<o:p></o:p></p> <p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal">I use the command:<o:p></o:p></p>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal">b2 toolset=msvc-10.0 --with-python link=shared<o:p></o:p></p>
<p class="MsoNormal" style="text-indent:36.0pt"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal">and get the following error:<o:p></o:p></p>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal">python34.lib(python34.dll) : fatal error LNK1112: module machine \
type 'x64' conflicts with target machine type 'X86'<o:p></o:p></p> <p \
class="MsoNormal"><o:p>&nbsp;</o:p></p> <p class="MsoNormal">I guess this means I \
have a conflict of 32-bit and 64-bit libraries.&nbsp; I want to target 32-bit \
(X86).<o:p></o:p></p> <p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal">Do I need to install a 32-bit version of Python?&nbsp; I wonder \
if that can co-exist with the current version of Python?<o:p></o:p></p> <p \
class="MsoNormal"><o:p>&nbsp;</o:p></p> <p class="MsoNormal">Best \
regards<o:p></o:p></p> <p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal">David<o:p></o:p></p>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal" style="margin-bottom:12.0pt"><span lang="EN-US" \
style="font-size:12.0pt;font-family:&quot;Times New Roman&quot;,serif"><br> \
=============================================================================================<br>
 Email transmissions can not be guaranteed to be secure or error-free, as information \
could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or \
contain viruses. The sender therefore does not accept liability for any errors or \
omissions  in the contents of this message which arise as a result of email \
transmission. In addition, the information contained in this email message is \
intended only for use of the individual or entity named above. If the reader of this \
message is not the intended  recipient, or the employee or agent responsible to \
deliver it to the intended recipient, you are hereby notified that any dissemination, \
distribution,or copying of this communication, disclosure of the parties to it, or \
any action taken or omitted to be taken  in reliance on it, is strictly prohibited, \
and may be unlawful. If you are not the intended recipient please delete this email \
message. ============================================================================================== \
&nbsp;&nbsp;&shy;&shy;&nbsp;&nbsp;<span \
style="background:white"><o:p></o:p></span></span></p> <p align="center" \
style="text-align:center"><span lang="EN-US" style="background:white">Click <a \
href="https://www.mailcontrol.com/sr/VIdq9eIbFJ3GX2PQPOmvUiQSa3&#43;T5MHvzY1DQvi2lw&#43;FqzJbzBJIALiBTIHiUs7caaqy85oZ6mcgL4AI7al!HQ==">
 here</a> to report this email as spam.<o:p></o:p></span></p>
</div>
</div>
</div>
</div>
</div>
</body>
</html>



_______________________________________________
Cplusplus-sig mailing list
Cplusplus-sig@python.org
https://mail.python.org/mailman/listinfo/cplusplus-sig
--===============4811837553488765518==--

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic