On Wed, Jan 2, 2013 at 7:58 PM, Andi Vajda <va...@apache.org> wrote:

>> I tested on OS X 10.8.2, and was able to install & run my usual smoke
>> test (index & search first 100K Wikipedia docs).
>>
>> But I hit a few strange things ... first, lots of compilation warnings
>> when compiling jcc and pylucene, eg:
>>
>> In file included from build/_lucene/JArray.cpp:21:
>>
>> /Library/Python/2.7/site-packages/JCC-2.15-py2.7-macosx-10.8-intel.egg/jcc/sources/JArray.h:104:102:
>> warning: implicit conversion loses integer precision: 'Py_ssize_t'
>> (aka 'long') to 'jsize'
>>      (aka 'int') [-Wshorten-64-to-32]
>>    JArray<jobject>(jclass cls, Py_ssize_t n) :
>> java::lang::Object(env->get_vm_env()->NewObjectArray(n, cls, NULL)) {
>>                                                                   ~~~
>>                              ^
>
>
> This could be a mismatch between 32-bit Python and 64-bit Java ?
> I don't know for sure, I've not seen this error but it's clearly complaining
> about losing 32 out of 64 bits somewhere.

Hmm my Python seems to be 64 bit (at least sys.maxint is 64 bits).

>> and:
>>
>> #define PySequence_Length PySequence_Size
>>                          ^
>> build/_lucene/__wrap05__.cpp:294:16: warning: implicit conversion
>> loses integer precision: 'Py_ssize_t' (aka 'long') to 'unsigned int'
>> [-Wshorten-64-to-32]
>>          if (!parseArgs(args, "s", &a0))
>>               ^~~~~~~~~~~~~~~~~~~~~~~~~
>>
>> /Library/Python/2.7/site-packages/JCC-2.15-py2.7-macosx-10.8-intel.egg/jcc/sources/functions.h:63:43:
>> note: expanded from macro 'parseArgs'
>>
>> They are all warnings and the compilation succeeded ...
>>
>> This could easily be user error ... I didn't change anything in jcc's
>> setup.py ... just ran it as was.  And I just uncommented the top "Mac
>> OS X 10.6" section in the Makefile ... Python is 2.7.2, java is
>> 1.6.0_35.
>>
>> The second strange problem I hit was during "make install" in
>> pylucene: it installed lots of stuff but then hit this odd error:
>
>
> Did you run 'make' first, then 'make install' or just 'make install'
> straight from scratch ?

I just ran 'make' alone, first.

> Both of these issues could be because you're using the stock Python 2.7 on
> Mac OS X 10.8.2 ? I've got a custom install for each and every PyLucene
> branch I maintain and these seem new enough to be correlated to 10.8.2 ? (I
> just upgraded to that myself two weeks ago).

I'm pretty sure this is stock Python but not certain ... when I launch
"python" I get:

Python 2.7.2 (default, Jun 20 2012, 16:23:33)
[GCC 4.2.1 Compatible Apple Clang 4.0 (tags/Apple/clang-418.0.60)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>>

And "file /usr/bin/python":

/usr/bin/python: Mach-O universal binary with 2 architectures
/usr/bin/python (for architecture i386):        Mach-O executable i386
/usr/bin/python (for architecture x86_64):      Mach-O 64-bit executable x86_64

> Thanks for checking !

Thank you!

Mike McCandless

http://blog.mikemccandless.com

Reply via email to