Note that there are some explanatory texts on larger screens.

plurals
  1. POPython Build Problem on Mac OS 10.6 / Snow Leopard
    text
    copied!<p>I'm encountering a build problem for Python 2.6.4 on Snow Leopard.</p> <ul> <li>Mac OS X 10.6</li> <li>Yonah CPU, <strong>32-bit</strong></li> <li>gcc-4.2.1</li> </ul> <hr> <p><strong>Update I</strong></p> <p>Solved by removing all non-standard includes and libraries from CFLAGS (there happened to be a <code>uuid/uuid.h</code> in there ...). Still, it compiled <em>despite</em> the error describe below, with <code>/usr/include/hfs/hfs_format.h:765</code> being a hot spot. For the curious or resourceful, the source file in question:</p> <pre><code>$ cat /usr/include/hfs/hfs_format.h ... 748 #include &lt;uuid/uuid.h&gt; 749 750 /* JournalInfoBlock - Structure that describes where our journal lives */ 751 752 // the original size of the reserved field in the JournalInfoBlock was 753 // 32*sizeof(u_int32_t). To keep the total size of the structure the 754 // same we subtract the size of new fields (currently: ext_jnl_uuid and 755 // machine_uuid). If you add additional fields, place them before the 756 // reserved field and subtract their size in this macro. 757 // 758 #define JIB_RESERVED_SIZE ((32*sizeof(u_int32_t)) - sizeof(uuid_string_t) - 48) 759 760 struct JournalInfoBlock { 761 u_int32_t flags; 762 u_int32_t device_signature[8]; // signature used to locate device. 763 u_int64_t offset; // byte offset to the journal on the device 764 u_int64_t size; // size in bytes of the journal 765 uuid_string_t ext_jnl_uuid; 766 char machine_serial_num[48]; 767 char reserved[JIB_RESERVED_SIZE]; 768 } __attribute__((aligned(2), packed)); 769 typedef struct JournalInfoBlock JournalInfoBlock; ... </code></pre> <p>I'm leaving the question open, since the build yielded too much warnings and this error and still puzzles me a bit ...</p> <p><strong>Update II</strong></p> <p>To get rid of the warnings regarding the deployment target, I edited the <code>Makefile</code> before compilation:</p> <pre><code>$ cat Makefile ... 126 MACOSX_DEPLOYMENT_TARGET=10.3 # =&gt; 10.6 ... </code></pre> <hr> <p><strong>Original Question</strong></p> <p>When trying to build Python 2.6.4 from source, I run into an error:</p> <pre><code>$ uname -v $ Darwin Kernel Version 10.2.0: Tue Nov 3 10:37:10 PST 2009; \ root:xnu-1486.2.11~1/RELEASE_I386 $ cd ~/src/Python-2.6.4 $ ./configure --enable-universalsdk=/ --prefix=$HOME checking for --with-universal-archs... 32-bit ... checking machine type as reported by uname -m... i386 ... checking for OSX 10.5 SDK or later... no // &lt;- But I have XCode + the SDKs installed? ... $ make ... ... /usr/include/hfs/hfs_format.h:765: error: \ expected specifier-qualifier-list before ‘uuid_string_t’ </code></pre> <p>It seems to root in <code>Python/mactoolboxglue.c</code>. Hints welcome!</p> <hr> <p>Also I get a lot of warnings of these kinds:</p> <pre><code>/usr/include/AvailabilityMacros.h:108:14: warning: #warning Building for \ Intel with Mac OS X Deployment Target &lt; 10.4 is invalid. gcc -c -arch ppc -arch i386 -isysroot / -fno-strict-aliasing -DNDEBUG -g \ -fwrapv -O3 -Wall -Wstrict-prototypes -I. -IInclude -I./Include \ -DPy_BUILD_CORE -o Objects/structseq.o Objects/structseq.c In file included from /usr/include/architecture/i386/math.h:626, from /usr/include/math.h:28, from Include/pyport.h:235, from Include/Python.h:58, from Objects/structseq.c:4: </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload