Boost C++ Libraries: Ticket #2185: bjam hangs when building libs/python/examples/quickstart under MacOS X https://svn.boost.org/trac10/ticket/2185 <p> After compilation/installation of Boost, trying to build the Boost.Python example in libs/python/examples/quickstart makes bjam hang after executing the step </p> <p> darwin.link.dll bin/darwin-4.0.1/debug/extending.so </p> <p> The library file extending.so is still built (apparently correctly), but bjam does not continue after this step. By running the link command line (obtained with bjam -n -a) directly in the terminal, I have verified that it is not the linker that hangs. </p> <p> Tested with today's development trunk under MacOS 10.4.11 (Intel) and with Boost 1.35.0 under MacOS 10.4.11 (Intel and PowerPC). I have found reports about the same problem under MacOS 10.5 in various newsgroups. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/2185 Trac 1.4.3 Marshall Clow Tue, 09 Sep 2008 19:51:07 GMT status, component, milestone changed; resolution set https://svn.boost.org/trac10/ticket/2185#comment:1 https://svn.boost.org/trac10/ticket/2185#comment:1 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">worksforme</span> </li> <li><strong>component</strong> <span class="trac-field-old">None</span> → <span class="trac-field-new">Building Boost</span> </li> <li><strong>milestone</strong> <span class="trac-field-old">Boost 1.36.0</span> → <span class="trac-field-new">Boost 1.37.0</span> </li> </ul> <p> Just tried it with the current trunk and gcc 4.0.1 (Xcode 3.1 install) and $ gcc --version i686-apple-darwin9-gcc-4.0.1 (GCC) 4.0.1 (Apple Inc. build 5484) $ bjam --version Boost.Build V2 (Milestone 12) Boost.Jam 03.1.16 </p> <p> No hang - closing as "works for me" Please re-open if this still happens for you using current boost/gcc/bjam. </p> Ticket konrad.hinsen@… Fri, 19 Sep 2008 19:41:01 GMT <link>https://svn.boost.org/trac10/ticket/2185#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:2</guid> <description> <p> I updated to XCode 2.5 (the latest for MacOS 10.4) and tried with boost 1.36.0. It still hangs, at the same place. </p> <p> $ gcc --version i686-apple-darwin8-gcc-4.0.1 (GCC) 4.0.1 (Apple Computer, Inc. build 5370) </p> <p> $ ./tools/jam/src/bin.macosxx86/bjam --version Boost.Build V2 (Milestone 12) Boost.Jam 03.1.16 </p> <p> Note: I tried to change the status to "reopen", but apparently I do not have the necessary permissions. The site just says "Warning: No permission to change ticket fields." I don't see a way to create an account either, so I am blocked. Now I try to add my comment without changing the status as this still seems better than doing nothing at all... </p> </description> <category>Ticket</category> </item> <item> <author>jason@…</author> <pubDate>Sat, 11 Apr 2009 03:43:35 GMT</pubDate> <title>status changed; resolution deleted https://svn.boost.org/trac10/ticket/2185#comment:3 https://svn.boost.org/trac10/ticket/2185#comment:3 <ul> <li><strong>status</strong> <span class="trac-field-old">closed</span> → <span class="trac-field-new">reopened</span> </li> <li><strong>resolution</strong> <span class="trac-field-deleted">worksforme</span> </li> </ul> <p> I am having the same problem. Building the example "quickstart" for Boost.Python hangs on the line described above. Versions: OS X - 10.5.6 gcc - i686-apple-darwin9-gcc-4.0.1 (GCC) 4.0.1 (Apple Inc. build 5490) Boost 1.38.0 Boost.Jam 03.1.17 </p> <p> I've also tried using bjam -n -a to get at the commands being run and to run them manually, as outlined here: <a class="ext-link" href="http://mail.python.org/pipermail/cplusplus-sig/2008-August/013580.html"><span class="icon">​</span>http://mail.python.org/pipermail/cplusplus-sig/2008-August/013580.html</a> </p> <p> I managed to run the command that hangs under bjam, successfully. But in the next step I ran into "darwin.link.dll: command not found" and that (alias?) didn't seem to be explicitly defined in the commands I saw, so I set this aside for the moment. </p> Ticket Steven Watanabe Sun, 19 Apr 2009 02:56:21 GMT component changed https://svn.boost.org/trac10/ticket/2185#comment:4 https://svn.boost.org/trac10/ticket/2185#comment:4 <ul> <li><strong>component</strong> <span class="trac-field-old">Building Boost</span> → <span class="trac-field-new">Python</span> </li> </ul> <p> darwin.link.dll is a Boost.Build rule, not a command that you can run from a shell. </p> Ticket Dave Abrahams Thu, 04 Jun 2009 21:43:49 GMT <link>https://svn.boost.org/trac10/ticket/2185#comment:5 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:5</guid> <description> <p> This is happening for me, too. I'm not sure where to start in trying to fix it, though! </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Dave Abrahams</dc:creator> <pubDate>Thu, 04 Jun 2009 22:11:45 GMT</pubDate> <title>status changed; owner set https://svn.boost.org/trac10/ticket/2185#comment:6 https://svn.boost.org/trac10/ticket/2185#comment:6 <ul> <li><strong>owner</strong> set to <span class="trac-author">René Rivera</span> </li> <li><strong>status</strong> <span class="trac-field-old">reopened</span> → <span class="trac-field-new">new</span> </li> </ul> <p> Another strange fact: adding -d+2 doesn't cause the command to be printed out before Python is started. I even added an explicit fflush to the bjam sources to try to force it. If I do a "ps waux" I can clearly see that it has started running the Python command, though! </p> Ticket anonymous Thu, 04 Jun 2009 23:42:35 GMT <link>https://svn.boost.org/trac10/ticket/2185#comment:7 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:7</guid> <description> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/2185#comment:6" title="Comment 6">dave</a>: </p> <blockquote class="citation"> <p> Another strange fact: adding -d+2 doesn't cause the command to be printed out before Python is started. I even added an explicit fflush to the bjam sources to try to force it. If I do a "ps waux" I can clearly see that it has started running the Python command, though! </p> </blockquote> <p> This was part of <a class="changeset" href="https://svn.boost.org/trac10/changeset/38009" title="Implement running action commands through pipes (-p option) to fix ...">[38009]</a>. It's annoying and should probably be disabled for single threaded builds. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Fri, 05 Jun 2009 09:29:35 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:8 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:8</guid> <description> <p> could somebody run bjam with '-l5' (undocumented) option and see if it helps? </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Fri, 05 Jun 2009 14:50:25 GMT</pubDate> <title>attachment set https://svn.boost.org/trac10/ticket/2185 https://svn.boost.org/trac10/ticket/2185 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">execunix.c.patch</span> </li> </ul> <p> updated </p> Ticket Dave Abrahams Fri, 05 Jun 2009 18:43:56 GMT <link>https://svn.boost.org/trac10/ticket/2185#comment:9 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:9</guid> <description> <p> With -l5, (that's a lowercase "L", right?) I get: </p> <pre class="wiki">#!/bin/sh $ bjam -l5 ...patience... ...patience... ...found 3236 targets... ...updating 2 targets... capture-output ../../../bin.v2/libs/parameter/test/python_test.test/darwin-4.0.1/debug/python_test 5 second time limit exceeded DYLD_LIBRARY_PATH=/System/Library/Frameworks/Python.framework/Versions/2.5/lib:/System/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/config:/Users/dave/src/boost/bin.v2/libs/parameter/test/python_test.test/darwin-4.0.1/debug:/Users/dave/src/boost/bin.v2/libs/python/build/darwin-4.0.1/debug:$DYLD_LIBRARY_PATH export DYLD_LIBRARY_PATH PYTHONPATH=../../../bin.v2/libs/parameter/test/python_test.test/darwin-4.0.1/debug export PYTHONPATH "/usr/bin/python2.5" "python_test.py" &gt; "../../../bin.v2/libs/parameter/test/python_test.test/darwin-4.0.1/debug/python_test.output" 2&gt;&amp;1 status=$? echo &gt;&gt; "../../../bin.v2/libs/parameter/test/python_test.test/darwin-4.0.1/debug/python_test.output" echo EXIT STATUS: $status &gt;&gt; "../../../bin.v2/libs/parameter/test/python_test.test/darwin-4.0.1/debug/python_test.output" if test $status -eq 0 ; then cp "../../../bin.v2/libs/parameter/test/python_test.test/darwin-4.0.1/debug/python_test.output" "../../../bin.v2/libs/parameter/test/python_test.test/darwin-4.0.1/debug/python_test" fi verbose=0 if test $status -ne 0 ; then verbose=1 fi if test $verbose -eq 1 ; then echo ====== BEGIN OUTPUT ====== cat "../../../bin.v2/libs/parameter/test/python_test.test/darwin-4.0.1/debug/python_test.output" echo ====== END OUTPUT ====== fi exit $status ...failed capture-output ../../../bin.v2/libs/parameter/test/python_test.test/darwin-4.0.1/debug/python_test... ...failed updating 1 target... ...skipped 1 target... zreba:test dave$ </pre><p> I did this one in /libs/parameter/test because it has only one Python-related test. I don't know if you're suggesting it, but I'll try the patch next. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Dave Abrahams</dc:creator> <pubDate>Fri, 05 Jun 2009 18:51:15 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:10 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:10</guid> <description> <p> Applying the patch makes no apparent difference to my results </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Dave Abrahams</dc:creator> <pubDate>Fri, 05 Jun 2009 20:16:20 GMT</pubDate> <title>severity changed https://svn.boost.org/trac10/ticket/2185#comment:11 https://svn.boost.org/trac10/ticket/2185#comment:11 <ul> <li><strong>severity</strong> <span class="trac-field-old">Problem</span> → <span class="trac-field-new">Showstopper</span> </li> </ul> <p> I'm able to run these tests with CMake, so this is not a blocker for me, but it surely is for someone else! </p> Ticket ilyasokol@… Sun, 07 Jun 2009 10:31:07 GMT attachment set https://svn.boost.org/trac10/ticket/2185 https://svn.boost.org/trac10/ticket/2185 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">execunix.c.2.patch</span> </li> </ul> <p> removes o_nonblock from both ends of pipe </p> Ticket ilyasokol@… Sun, 07 Jun 2009 10:37:00 GMT <link>https://svn.boost.org/trac10/ticket/2185#comment:12 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:12</guid> <description> <p> If the patch above doesn't work then I am out of ideas. I hope we are hitting this bug: <a class="ext-link" href="http://lists.apple.com/archives/Darwin-kernel/2005/Dec/msg00058.html"><span class="icon">​</span>http://lists.apple.com/archives/Darwin-kernel/2005/Dec/msg00058.html</a> </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Dave Abrahams</dc:creator> <pubDate>Sun, 07 Jun 2009 18:44:58 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:13 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:13</guid> <description> <p> Makes no difference for me, I'm afraid. Note, though, that the 2nd hunk of your patch applied at an offset of 4 lines, which makes me think you're working with a different version of the source. </p> <p> If you need it I can hook you up with a MacOS account to try this on. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Sun, 07 Jun 2009 19:46:10 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:14 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:14</guid> <description> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/2185#comment:13" title="Comment 13">dave</a>: </p> <blockquote class="citation"> <p> If you need it I can hook you up with a MacOS account to try this on. </p> </blockquote> <p> That would be great. Please contact me by email ilyasokol&lt;at&gt;gmail&lt;dot&gt;com </p> </description> <category>Ticket</category> </item> <item> <author>Randolph Fritz <rfritz@…></author> <pubDate>Wed, 08 Jul 2009 21:20:24 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:15 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:15</guid> <description> <p> Still seeing this with Boost 1.39.0 on Mac OS X 10.5.7. I will try adding the timeout described in <a class="ext-link" href="http://article.gmane.org/gmane.comp.lib.boost.build/18302"><span class="icon">​</span>http://article.gmane.org/gmane.comp.lib.boost.build/18302</a>. To be continued... </p> </description> <category>Ticket</category> </item> <item> <author>Randolph Fritz <rfritz@…></author> <pubDate>Thu, 09 Jul 2009 20:12:40 GMT</pubDate> <title>severity changed https://svn.boost.org/trac10/ticket/2185#comment:16 https://svn.boost.org/trac10/ticket/2185#comment:16 <ul> <li><strong>severity</strong> <span class="trac-field-old">Showstopper</span> → <span class="trac-field-new">Problem</span> </li> </ul> <p> The hang actually occurs in test_extending.py. I am starting to doubt this is a bjam problem. </p> Ticket Randolph Fritz <rfritz@…> Thu, 09 Jul 2009 20:24:04 GMT <link>https://svn.boost.org/trac10/ticket/2185#comment:17 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:17</guid> <description> <p> Situation is: </p> <ul><li>Configure dynamic libraries and PYTHONPATH from command line. Run "python test_extending.py". Test succeeds. </li></ul><ul><li>Run tests from bjam, with command "bjam test_ext". Test hangs. </li></ul><ul><li>Run tests from bjam, with timeout; command "bjam -l15 test_ext". Test fails by timeout. </li></ul><p> It is probably some subtle environment-related bug, either in the Apple release of python 2.5.1 or in Boost.Python itself, but so far I am unable to determine which. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Tue, 11 Aug 2009 23:48:30 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:18 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:18</guid> <description> <p> I know it's been bumped down, but can this be bumped back up to showstopper? I't seem like one -- I can find no consistent workaround, and it's made boost.python unavailable to what appears to be a large segment of population for at least a year now. (I've spoken to two other people who have abandoned boost because of this bug.) </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Wed, 12 Aug 2009 17:00:33 GMT</pubDate> <title>severity changed https://svn.boost.org/trac10/ticket/2185#comment:19 https://svn.boost.org/trac10/ticket/2185#comment:19 <ul> <li><strong>severity</strong> <span class="trac-field-old">Problem</span> → <span class="trac-field-new">Showstopper</span> </li> </ul> Ticket anonymus Thu, 26 Nov 2009 13:08:47 GMT <link>https://svn.boost.org/trac10/ticket/2185#comment:20 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:20</guid> <description> <p> apparently, somebody got it running here <a class="ext-link" href="http://lists.boost.org/boost-users/2009/02/45404.php"><span class="icon">​</span>http://lists.boost.org/boost-users/2009/02/45404.php</a> </p> <p> go to later posts in this thread. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Marshall Clow</dc:creator> <pubDate>Mon, 30 Nov 2009 01:14:55 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:21 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:21</guid> <description> <p> Additional data point: I just tried this on Mac OS X 10.6.2 / gcc 4.2.1 (Intel), and was unable to reproduce. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Sat, 15 May 2010 18:34:40 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:22 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:22</guid> <description> <p> FWIW, 'bjam toolset=darwin test' still hangs for me. However, 'extending' and 'embedding' both compile without problems, and I can import the generated extension module (after moving 'libboost_python.dylib' into a library path.) It sounds like 'test' works on Snow Leopard, but not on Leopard. Given that boost.python obviously works on Leopard, this isn't a showstopper for me, but it would have been really great if there had been a note somewhere, because I all but abandoned boost.python for over a year because I thought it simply didn't work on OS X (and others have said the same). </p> <ul><li>OS X 10.5.8 </li></ul><ul><li>Developer Tools 3.1.4 </li></ul><ul><li>gcc version 4.0.1 (Apple Inc. build 5493) </li></ul><ul><li>boost_1_43_0 </li></ul><ul><li>Boost.Jam Version 3.1.17. OS=MACOSX </li></ul> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Tue, 19 Oct 2010 10:00:08 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:23 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:23</guid> <description> <p> hanging at: </p> <p> darwin.link.dll bin/darwin-4.2.1/debug/extending.so </p> <hr /> <p> OS X 10.6.4 </p> <p> darwin-4.2.1 </p> <p> boost_1_44_0 </p> <p> Boost.Jam 03.1.18 </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Tue, 19 Oct 2010 10:00:15 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:23 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:23</guid> <description> <p> hanging at: </p> <p> darwin.link.dll bin/darwin-4.2.1/debug/extending.so </p> <hr /> <p> OS X 10.6.4 </p> <p> darwin-4.2.1 </p> <p> boost_1_44_0 </p> <p> Boost.Jam 03.1.18 </p> </description> <category>Ticket</category> </item> <item> <author>meowsqueak@…</author> <pubDate>Mon, 09 Jul 2012 22:36:59 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:24 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:24</guid> <description> <p> I have this problem right now with: </p> <blockquote> <p> $ bjam toolset=darwin --verbose-test test </p> </blockquote> <p> It hangs after the line: </p> <blockquote> <p> darwin.link.dll bin/darwin-4.2.1/debug/extending.so </p> </blockquote> <p> Ctrl-c and inspecting the bin/ directory shows some .o and .so files, but no .dylib files, in bin/darwin-4.2.1/debug/ but these don't seem to be 'importable' by Python. </p> <p> This command (not sure if that's the right PYTHONPATH?) fails: </p> <blockquote> <p> $ PYTHONPATH=bin/darwin-4.2.1/debug python test_extending.py ... <a class="missing wiki">ImportError</a>: dlopen(/Users/david/Downloads/boost_1_50_0/libs/python/example/quickstart/bin/darwin-4.2.1/debug/extending.so, 2): Library not loaded: libboost_python.dylib </p> </blockquote> <p> Not sure why bjam created a .so instead of a .dylib? </p> <p> My platform: *OS X 10.6.8 64bit *Python 2.7.3 (built locally with pythonbrew) *i686-apple-darwin10-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5666) (dot 3) *boost_1_50_0 *Boost.Build 2011.12-svn (bjam built locally from boost_1_50_0) </p> </description> <category>Ticket</category> </item> <item> <author>meowsqueak@…</author> <pubDate>Mon, 09 Jul 2012 22:54:45 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:25 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:25</guid> <description> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/2185#comment:24" title="Comment 24">meowsqueak@…</a>: </p> <blockquote class="citation"> <p> This command (not sure if that's the right PYTHONPATH?) fails: </p> <blockquote> <p> $ PYTHONPATH=bin/darwin-4.2.1/debug python test_extending.py ... <a class="missing wiki">ImportError</a>: dlopen(/Users/david/Downloads/boost_1_50_0/libs/python/example/quickstart/bin/darwin-4.2.1/debug/extending.so, 2): Library not loaded: libboost_python.dylib </p> </blockquote> </blockquote> <p> Just as a follow up, after hitting Ctrl-C at the hang, I was able to successfully run 'test_extending.py' with: </p> <pre class="wiki"> $ export DYLD_LIBRARY_PATH=../../../../bin.v2/libs/python/build/darwin-4.2.1/debug $ export LD_LIBRARY_PATH=../../../../bin.v2/libs/python/build/darwin-4.2.1/debug $ export PYTHONPATH=bin/darwin-4.2.1/debug $ python test_extending.py ... 9 passed and 0 failed. Test passed. </pre> </description> <category>Ticket</category> </item> <item> <author>jamestwebber@…</author> <pubDate>Fri, 28 Sep 2012 00:46:18 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:26 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:26</guid> <description> <p> I'm having the exact problem that meowsqueak reports: bjam hanged after </p> <blockquote> <p> <code>darwin.link.dll bin/darwin-4.2.1/debug/extending.so</code> </p> </blockquote> <p> But I can run test_extending.py fine after killing the command and export the relevant variables. No new wrinkles from what's been previously reported, but wanted to add another data point. </p> <p> I'm using OS X 10.7.5 and python 2.7.3 built with homebrew, boost 1.50.0 and bjam built locally from boost. </p> <p> Digging a bit into the commands, I can see as dave did that Python is running, with the command </p> <pre class="wiki">"/usr/local/Cellar/python/2.7.3/Frameworks/Python.framework/Versions/2.7/bin/python" "test_extending.py" &gt; "bin/test_ext.test/darwin-4.2.1/debug/test_ext.output" 2&gt;&amp;1 </pre><p> But when I run that command alone (after compiling) it runs fine. The test_ext.output looks fine except that it starts with the characters <code>\E[?1034h </code>which appears to be related to some weird behavior from readline (CAPTCHA isn't working so I can't post this link, but: search for "readline+1034h")? I have no idea if that might cause a problem--I'm not sure how it would. </p> <p> If I kill the Python process it remains hanging, but killing the bash script stops the test (which then fails because the output is wrong). </p> <h2 class="section" id="Actually">Actually…</h2> <p> I tried running the testing script manually, by pasting this into the terminal: </p> <pre class="wiki"> /bin/sh -c DYLD_LIBRARY_PATH="/usr/local/Cellar/python/2.7.3/Frameworks/Python.framework/Versions/2.7/lib:/usr/local/Cellar/python/2.7.3/Frameworks/Python.framework/Versions/2.7/lib/python2.7/config:/usr/local/boost_1_51_0/bin.v2/libs/python/build/darwin-4.2.1/debug:/usr/local/boost_1_51_0/libs/python/example/quickstart/bin/darwin-4.2.1/debug:$DYLD_LIBRARY_PATH" export DYLD_LIBRARY_PATH PYTHONPATH="bin/darwin-4.2.1/debug" export PYTHONPATH "/usr/local/Cellar/python/2.7.3/Frameworks/Python.framework/Versions/2.7/bin/python" "test_extending.py" &gt; "bin/test_ext.test/darwin-4.2.1/debug/test_ext.output" 2&gt;&amp;1 status=$? echo &gt;&gt; "bin/test_ext.test/darwin-4.2.1/debug/test_ext.output" echo EXIT STATUS: $status &gt;&gt; "bin/test_ext.test/darwin-4.2.1/debug/test_ext.output" if test $status -eq 0 ; then cp "bin/test_ext.test/darwin-4.2.1/debug/test_ext.output" "bin/test_ext.test/darwin-4.2.1/debug/test_ext" fi verbose=1 if test $status -ne 0 ; then verbose=1 fi if test $verbose -eq 1 ; then echo ====== BEGIN OUTPUT ====== cat "bin/test_ext.test/darwin-4.2.1/debug/test_ext.output" echo ====== END OUTPUT ====== fi exit $status </pre><p> The result is that my terminal hangs--I have to close the window and open a new one. It does successfully run the tests, though, and outputs the results. </p> <p> If I omit the last line (<code>exit $status</code>), it runs fine and doesn't hang. So perhaps this is happening because the shell script is exiting out of the user's bash shell, never returning control to bjam? This doesn't explain why I didn't see the test.output file before, I guess. And I would guess that the exit status is good to know. But this might be the cause of the problem. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Fri, 28 Sep 2012 00:56:35 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:27 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:27</guid> <description> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/2185#comment:26" title="Comment 26">jamestwebber@…</a>: </p> <p> In hindsight, that is clearly a wrong explanation, because Python has already completed by the time the console hangs, and in the bug it is still running. So, uh, never mind... </p> </description> <category>Ticket</category> </item> <item> <author>jamestwebber@…</author> <pubDate>Tue, 19 Feb 2013 23:16:08 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:28 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:28</guid> <description> <p> Sweet Fancy Moses, I got it to work! </p> <p> (I've searched for answers to this for a long time, so I'm going to post my solution in multiple places for the sake of posterity) </p> <p> I was able to get all Boost Python tests (in /test and in /example/quickstart) by <strong>uninstalling</strong> the Homebrew-installed readline. This strongly suggests to me that a bug in readline is causing these tests to fail. </p> <p> While trying to figure this out, I noticed that only the tests using doctest were failing. doctest uses readline internally, and this might be causing an issue. As has been noted in other places, readline seems to have a bug in which it emits an extra character when first imported in python. At first this seemed unrelated but now I think it (or some other readline bug) is the cause of much headaches. </p> <p> This is rather unfortunate because uninstalling readline breaks the Python REPL (e.g. arrow keys no longer work). So obviously this is not a long-term fix, but it does answer some questions. Weirdly, readline is not necessarily for doctests to function. </p> <p> So, I don't have a patch or anything, but I think I have tracked down the bug to readline. </p> <p> They didn't seem all that interested in patching this bug, but maybe this will give them a good reason to do so (or look for the real bug?). </p> </description> <category>Ticket</category> </item> <item> <author>jamestwebber@…</author> <pubDate>Wed, 20 Feb 2013 00:29:11 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/2185#comment:29 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/2185#comment:29</guid> <description> <p> One quick update: I don't think the odd readline character is the cause of this problem (which is not terribly surprising, I don't know how it would be). But I do think <em>something</em> about readline is the issue. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Dave Abrahams</dc:creator> <pubDate>Wed, 20 Feb 2013 01:10:03 GMT</pubDate> <title>status changed; resolution set https://svn.boost.org/trac10/ticket/2185#comment:30 https://svn.boost.org/trac10/ticket/2185#comment:30 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">invalid</span> </li> </ul> <p> Thanks for tracking down that readline bug! </p> Ticket