Return-Path: Delivered-To: apmail-lucene-pylucene-dev-archive@minotaur.apache.org Received: (qmail 84270 invoked from network); 3 May 2010 19:01:27 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 3 May 2010 19:01:27 -0000 Received: (qmail 94253 invoked by uid 500); 3 May 2010 19:01:27 -0000 Delivered-To: apmail-lucene-pylucene-dev-archive@lucene.apache.org Received: (qmail 94190 invoked by uid 500); 3 May 2010 19:01:27 -0000 Mailing-List: contact pylucene-dev-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: pylucene-dev@lucene.apache.org Delivered-To: mailing list pylucene-dev@lucene.apache.org Received: (qmail 94182 invoked by uid 99); 3 May 2010 19:01:27 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 03 May 2010 19:01:27 +0000 X-ASF-Spam-Status: No, hits=2.2 required=10.0 tests=AWL,FREEMAIL_FROM,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of michael.manoochehri@gmail.com designates 209.85.212.48 as permitted sender) Received: from [209.85.212.48] (HELO mail-vw0-f48.google.com) (209.85.212.48) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 03 May 2010 19:01:22 +0000 Received: by vws13 with SMTP id 13so2177288vws.35 for ; Mon, 03 May 2010 12:01:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:mime-version:received:in-reply-to :references:from:date:message-id:subject:to:content-type; bh=GT8lPiSIBJBg4uUtH8WHlD+KTWL9N1oWTeKaY7DPlYI=; b=NH1mcU569tNWIzcXGmIVydZy0++aVPva94HtBvbSZ1t1WOfvDiRIO35ZZT11fA3j2V K+wzGLBVVZ7d0wuMOCmQtuDC7d00MzWPJNYdoWIlhT+3YfV4mOylVXa3Z3cJ9DGEHTWZ rikpl0ep9rnbPCU6iO3kG9hN9OjtnOjXnDvDg= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; b=KH0Prm0kh3ferViuMz4qkLanjxoHqkENC5r9FaKyNSiJkms7Y73YIFoslbKs6oKcWB 9764B88ggO8WqZkkU6gzjuggOWzvZ1vL8KPlkkvGom8GM4ZURClPL9X5gMp5sQ+rFpJT qIZrepy18T5dUPvGfv2YFBjF4kGGjOZWWri4Y= Received: by 10.220.126.166 with SMTP id c38mr10307241vcs.169.1272913261307; Mon, 03 May 2010 12:01:01 -0700 (PDT) MIME-Version: 1.0 Received: by 10.220.17.6 with HTTP; Mon, 3 May 2010 12:00:41 -0700 (PDT) In-Reply-To: References: From: Michael Manoochehri Date: Mon, 3 May 2010 12:00:41 -0700 Message-ID: Subject: Re: Question about building 64bit pylucene on Darwin To: pylucene-dev@lucene.apache.org, Andi Vajda Content-Type: multipart/alternative; boundary=0050450160f3c5270c0485b53615 --0050450160f3c5270c0485b53615 Content-Type: text/plain; charset=ISO-8859-1 Hi Andi: Thanks for that advice! Well, I checked my Makefile, and I don't *think* I have conflicting uncommented sections, but I will take another look. Hmm, well the gcc flag for x86_64 don't seem to be set in my make output. I will double check it. I hope you don't mind me pasting my make command output: macpro:pylucene-3.0.1-1 viallon$ vi Makefile macpro:pylucene-3.0.1-1 viallon$ make /usr/bin/python -m jcc.__main__ --shared --arch x86_64 --jar lucene-java-3.0.1/build/lucene-core-3.0.1.jar --jar lucene-java-3.0.1/build/contrib/snowball/lucene-snowball-3.0.1.jar --jar lucene-java-3.0.1/build/contrib/analyzers/common/lucene-analyzers-3.0.1.jar --jar lucene-java-3.0.1/build/contrib/regex/lucene-regex-3.0.1.jar --jar lucene-java-3.0.1/build/contrib/memory/lucene-memory-3.0.1.jar --jar lucene-java-3.0.1/build/contrib/highlighter/lucene-highlighter-3.0.1.jar --jar lucene-java-3.0.1/build/contrib/queries/lucene-queries-3.0.1.jar --jar build/jar/extensions.jar --package java.lang java.lang.System java.lang.Runtime --package java.util java.util.Arrays java.text.SimpleDateFormat java.text.DecimalFormat java.text.Collator --package java.io java.io.StringReader java.io.InputStreamReader java.io.FileInputStream --exclude org.apache.lucene.queryParser.Token --exclude org.apache.lucene.queryParser.TokenMgrError --exclude org.apache.lucene.queryParser.QueryParserTokenManager --exclude org.apache.lucene.queryParser.ParseException --exclude org.apache.lucene.search.regex.JakartaRegexpCapabilities --exclude org.apache.regexp.RegexpTunnel --python lucene --mapping org.apache.lucene.document.Document 'get:(Ljava/lang/String;)Ljava/lang/String;' --mapping java.util.Properties 'getProperty:(Ljava/lang/String;)Ljava/lang/String;' --rename org.apache.lucene.search.highlight.SpanScorer=HighlighterSpanScorer --version 3.0.1 --module python/collections.py --files 2 --build Warning: renaming static method 'getCommitUserData' on class org.apache.lucene.index.IndexReader to 'getCommitUserData_' since it is shadowed by non-static method of same name. Warning: renaming static method 'toString' on class java.lang.Long to 'toString_' since it is shadowed by non-static method of same name. Warning: renaming static method 'getCurrentSegmentFileName' on class org.apache.lucene.index.SegmentInfos to 'getCurrentSegmentFileName_' since it is shadowed by non-static method of same name. Warning: renaming static method 'fileModified' on class org.apache.lucene.store.FSDirectory to 'fileModified_' since it is shadowed by non-static method of same name. Warning: renaming static method 'listAll' on class org.apache.lucene.store.FSDirectory to 'listAll_' since it is shadowed by non-static method of same name. Warning: renaming static method 'isInfinite' on class java.lang.Double to 'isInfinite_' since it is shadowed by non-static method of same name. Warning: renaming static method 'isNaN' on class java.lang.Double to 'isNaN_' since it is shadowed by non-static method of same name. Warning: renaming static method 'toString' on class java.lang.Double to 'toString_' since it is shadowed by non-static method of same name. Warning: renaming static method 'toString' on class java.lang.Boolean to 'toString_' since it is shadowed by non-static method of same name. Warning: renaming static method 'toString' on class java.lang.Integer to 'toString_' since it is shadowed by non-static method of same name. Warning: renaming static method 'toString' on class java.lang.Character to 'toString_' since it is shadowed by non-static method of same name. Warning: renaming static method 'toString' on class java.lang.Byte to 'toString_' since it is shadowed by non-static method of same name. Warning: renaming static method 'isInfinite' on class java.lang.Float to 'isInfinite_' since it is shadowed by non-static method of same name. Warning: renaming static method 'isNaN' on class java.lang.Float to 'isNaN_' since it is shadowed by non-static method of same name. Warning: renaming static method 'toString' on class java.lang.Float to 'toString_' since it is shadowed by non-static method of same name. Warning: renaming static method 'toString' on class java.lang.Short to 'toString_' since it is shadowed by non-static method of same name. running build_ext building 'lucene._lucene' extension gcc -fno-strict-aliasing -Wno-long-double -no-cpp-precomp -mno-fused-madd -fno-common -dynamic -DNDEBUG -g -Os -Wall -Wstrict-prototypes -DMACOSX -I/usr/include/ffi -DENABLE_DTRACE -arch i386 -arch ppc -pipe -D_java_generics -DPYTHON=1 -D_jcc_shared=1 -I/System/Library/Frameworks/JavaVM.framework/Versions/Current/Headers -Ibuild/_lucene -I/Library/Python/2.5/site-packages/JCC-2.5.1-py2.5-macosx-10.5-i386.egg/jcc/sources -I/System/Library/Frameworks/Python.framework/Versions/2.5/include/python2.5 -c build/_lucene/__init__.cpp -o build/temp.macosx-10.5-i386-2.5/build/_lucene/__init__.o -fno-strict-aliasing -Wno-write-strings cc1plus: warning: command line option "-Wstrict-prototypes" is valid for C/ObjC but not for C++ cc1plus: warning: command line option "-Wstrict-prototypes" is valid for C/ObjC but not for C++ gcc -fno-strict-aliasing -Wno-long-double -no-cpp-precomp -mno-fused-madd -fno-common -dynamic -DNDEBUG -g -Os -Wall -Wstrict-prototypes -DMACOSX -I/usr/include/ffi -DENABLE_DTRACE -arch i386 -arch ppc -pipe -D_java_generics -DPYTHON=1 -D_jcc_shared=1 -I/System/Library/Frameworks/JavaVM.framework/Versions/Current/Headers -Ibuild/_lucene -I/Library/Python/2.5/site-packages/JCC-2.5.1-py2.5-macosx-10.5-i386.egg/jcc/sources -I/System/Library/Frameworks/Python.framework/Versions/2.5/include/python2.5 -c build/_lucene/__wrap01__.cpp -o build/temp.macosx-10.5-i386-2.5/build/_lucene/__wrap01__.o -fno-strict-aliasing -Wno-write-strings cc1plus: warning: command line option "-Wstrict-prototypes" is valid for C/ObjC but not for C++ cc1plus: warning: command line option "-Wstrict-prototypes" is valid for C/ObjC but not for C++ gcc -fno-strict-aliasing -Wno-long-double -no-cpp-precomp -mno-fused-madd -fno-common -dynamic -DNDEBUG -g -Os -Wall -Wstrict-prototypes -DMACOSX -I/usr/include/ffi -DENABLE_DTRACE -arch i386 -arch ppc -pipe -D_java_generics -DPYTHON=1 -D_jcc_shared=1 -I/System/Library/Frameworks/JavaVM.framework/Versions/Current/Headers -Ibuild/_lucene -I/Library/Python/2.5/site-packages/JCC-2.5.1-py2.5-macosx-10.5-i386.egg/jcc/sources -I/System/Library/Frameworks/Python.framework/Versions/2.5/include/python2.5 -c build/_lucene/__wrap02__.cpp -o build/temp.macosx-10.5-i386-2.5/build/_lucene/__wrap02__.o -fno-strict-aliasing -Wno-write-strings cc1plus: warning: command line option "-Wstrict-prototypes" is valid for C/ObjC but not for C++ cc1plus: warning: command line option "-Wstrict-prototypes" is valid for C/ObjC but not for C++ gcc -fno-strict-aliasing -Wno-long-double -no-cpp-precomp -mno-fused-madd -fno-common -dynamic -DNDEBUG -g -Os -Wall -Wstrict-prototypes -DMACOSX -I/usr/include/ffi -DENABLE_DTRACE -arch i386 -arch ppc -pipe -D_java_generics -DPYTHON=1 -D_jcc_shared=1 -I/System/Library/Frameworks/JavaVM.framework/Versions/Current/Headers -Ibuild/_lucene -I/Library/Python/2.5/site-packages/JCC-2.5.1-py2.5-macosx-10.5-i386.egg/jcc/sources -I/System/Library/Frameworks/Python.framework/Versions/2.5/include/python2.5 -c build/_lucene/__wrap03__.cpp -o build/temp.macosx-10.5-i386-2.5/build/_lucene/__wrap03__.o -fno-strict-aliasing -Wno-write-strings cc1plus: warning: command line option "-Wstrict-prototypes" is valid for C/ObjC but not for C++ cc1plus: warning: command line option "-Wstrict-prototypes" is valid for C/ObjC but not for C++ gcc -fno-strict-aliasing -Wno-long-double -no-cpp-precomp -mno-fused-madd -fno-common -dynamic -DNDEBUG -g -Os -Wall -Wstrict-prototypes -DMACOSX -I/usr/include/ffi -DENABLE_DTRACE -arch i386 -arch ppc -pipe -D_java_generics -DPYTHON=1 -D_jcc_shared=1 -I/System/Library/Frameworks/JavaVM.framework/Versions/Current/Headers -Ibuild/_lucene -I/Library/Python/2.5/site-packages/JCC-2.5.1-py2.5-macosx-10.5-i386.egg/jcc/sources -I/System/Library/Frameworks/Python.framework/Versions/2.5/include/python2.5 -c build/_lucene/lucene.cpp -o build/temp.macosx-10.5-i386-2.5/build/_lucene/lucene.o -fno-strict-aliasing -Wno-write-strings cc1plus: warning: command line option "-Wstrict-prototypes" is valid for C/ObjC but not for C++ cc1plus: warning: command line option "-Wstrict-prototypes" is valid for C/ObjC but not for C++ g++ -Wl,-F. -bundle -undefined dynamic_lookup -arch i386 -arch ppc build/temp.macosx-10.5-i386-2.5/build/_lucene/__init__.o build/temp.macosx-10.5-i386-2.5/build/_lucene/__wrap01__.o build/temp.macosx-10.5-i386-2.5/build/_lucene/__wrap02__.o build/temp.macosx-10.5-i386-2.5/build/_lucene/__wrap03__.o build/temp.macosx-10.5-i386-2.5/build/_lucene/functions.o build/temp.macosx-10.5-i386-2.5/build/_lucene/JArray.o build/temp.macosx-10.5-i386-2.5/build/_lucene/JObject.o build/temp.macosx-10.5-i386-2.5/build/_lucene/lucene.o build/temp.macosx-10.5-i386-2.5/build/_lucene/types.o -L/Library/Python/2.5/site-packages/JCC-2.5.1-py2.5-macosx-10.5-i386.egg -ljcc -o build/lib.macosx-10.5-i386-2.5/lucene/_lucene.so -framework JavaVM -Wl,-S -Wl,-rpath /Library/Python/2.5/site-packages/JCC-2.5.1-py2.5-macosx-10.5-i386.egg build of complete On Mon, May 3, 2010 at 11:37 AM, Andi Vajda wrote: > > On Mon, 3 May 2010, Michael Manoochehri wrote: > > I have a question about building a 64 bit binary of _lucene.so on Darwin. >> >> I am using (from uname): >> Darwin Kernel Version 9.8.0: Wed Jul 15 16:55:01 PDT 2009; >> root:xnu-1228.15.4~1/RELEASE_I386 i386 >> >> In my Makefile, I have uncommented: >> Mac OS X 10.6 (64-bit Python 2.6, Java 1.6) >> PREFIX_PYTHON=/usr >> ANT=ant >> PYTHON=$(PREFIX_PYTHON)/bin/python >> JCC=$(PYTHON) -m jcc.__main__ --shared --arch x86_64 >> NUM_FILES=2 >> >> But after building and installing, when I check the _lucene.so binary, it >> returns >> >>> file >>>>> >>>> >> /Library/Python/2.5/site-packages/lucene-3.0.1-py2.5-macosx-10.5-i386.egg/lucene/_lucene.so >> >> >> /Library/Python/2.5/site-packages/lucene-3.0.1-py2.5-macosx-10.5-i386.egg/lucene/_lucene.so: >> Mach-O universal binary with 2 architectures >> >> /Library/Python/2.5/site-packages/lucene-3.0.1-py2.5-macosx-10.5-i386.egg/lucene/_lucene.so >> (for architecture i386): Mach-O bundle i386 >> >> /Library/Python/2.5/site-packages/lucene-3.0.1-py2.5-macosx-10.5-i386.egg/lucene/_lucene.so >> (for architecture ppc7400): Mach-O bundle ppc >> >> Any suggestions for me to produce an x86_64 build (basically, I'm trying >> to >> use pylucene with 64bit apache2 + wsgi)? >> > > You're doing the right thing. The --arch x86_64 tells gcc to skip the > building of i386 and ppc binaries (and saves two thirds of compile time). > > You probably have another section of the PyLucene Makefile uncommented thus > overriding the one you actually want to run. > > When the build is going, verify that the jcc command output from 'make' > shows the --arch x86_64 parameter. > > Andi.. > -- Michael Manoochehri Masters of Information Management and Systems 2010 UC Berkeley School of Information I write for: programmableweb.com my blog: e.ntangled.net follow me: @nTangledMichael --0050450160f3c5270c0485b53615--