Return-Path: X-Original-To: apmail-lucene-pylucene-dev-archive@minotaur.apache.org Delivered-To: apmail-lucene-pylucene-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 60DB810FBD for ; Tue, 29 Oct 2013 19:00:54 +0000 (UTC) Received: (qmail 86351 invoked by uid 500); 29 Oct 2013 19:00:54 -0000 Delivered-To: apmail-lucene-pylucene-dev-archive@lucene.apache.org Received: (qmail 86329 invoked by uid 500); 29 Oct 2013 19:00:54 -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 86313 invoked by uid 99); 29 Oct 2013 19:00:54 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 29 Oct 2013 19:00:54 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=5.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy includes SPF record at spf.trusted-forwarder.org) Received: from [50.0.193.30] (HELO ovaltofu.org) (50.0.193.30) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 29 Oct 2013 19:00:49 +0000 Received: from [192.168.0.101] (bd7a614d.virtua.com.br [189.122.97.77] (may be forged)) (authenticated bits=0) by ovaltofu.org (8.14.4/8.14.4) with ESMTP id r9TJ0EPo022270 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO) for ; Tue, 29 Oct 2013 12:00:25 -0700 (PDT) Subject: Re: Compilation of JCC fails: cannot find -lpython2.7 References: <0A8464E493FC554C9FFB58B7E3B0D92D26A69ECB@BYYNJN.DE.bayer.cnb> From: Andi Vajda Content-Type: text/plain; charset=us-ascii X-Mailer: iPhone Mail (11A501) In-Reply-To: <0A8464E493FC554C9FFB58B7E3B0D92D26A69ECB@BYYNJN.DE.bayer.cnb> Message-Id: Date: Tue, 29 Oct 2013 17:00:11 -0200 To: "pylucene-dev@lucene.apache.org" Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (1.0) X-Virus-Checked: Checked by ClamAV on apache.org > On Oct 29, 2013, at 15:09, Filip Nollet wrote: >=20 > Hi all >=20 > I have a problem compiling JCC for pylucene. > It does not find the shared Python library, while this seems to be availab= le. >=20 > The error is printed below. >=20 > My environment set the LD_LIBRARY_PATH for Python 2.7: > # set | grep LD_ > LD_LIBRARY_PATH=3D/tools/general/app/python-2.7.5-rhel6/lib:/tools/general= /app/sqlite-3.8.0.2/lib >=20 > Also, the contents of my Python setup seems fine: > # ll /tools/general/app/python-2.7.5-rhel6/lib > total 16512 > -r-xr-xr-x 1 root root 10355780 Oct 16 12:57 libpython2.7.a > lrwxrwxrwx 1 root root 19 Oct 24 17:27 libpython2.7.so -> libpytho= n2.7.so.1.0 > -rwxr-xr-x+ 1 root root 6053659 Oct 24 17:26 libpython2.7.so.1.0 > drwxr-xr-x+ 2 root root 65536 Oct 16 12:57 pkgconfig > drwxr-xr-x+ 27 root root 65536 Oct 16 12:57 python2.7 >=20 >=20 > Any ideas for this? Thanks in advance Did you edit jcc's setup.py to reflect your envirronment ? Once done you shouldn't need LD_LIBRARY_PATH either. Andi.. >=20 >=20 > Regards, >=20 >=20 > Filip >=20 >=20 > --------------------------------------------------------------------------= --- >=20 >=20 > Applied shared mode monkey patch to: > Loading source files for package org.apache.jcc... > Constructing Javadoc information... > Standard Doclet version 1.6.0_39 > Building tree for all the packages and classes... > Generating javadoc/org/apache/jcc//PythonException.html... > Generating javadoc/org/apache/jcc//PythonVM.html... > Generating javadoc/org/apache/jcc//package-frame.html... > Generating javadoc/org/apache/jcc//package-summary.html... > Generating javadoc/org/apache/jcc//package-tree.html... > Generating javadoc/constant-values.html... > Generating javadoc/serialized-form.html... > Building index for all the packages and classes... > Generating javadoc/overview-tree.html... > Generating javadoc/index-all.html... > Generating javadoc/deprecated-list.html... > Building index for all classes... > Generating javadoc/allclasses-frame.html... > Generating javadoc/allclasses-noframe.html... > Generating javadoc/index.html... > Generating javadoc/help-doc.html... > Generating javadoc/stylesheet.css... > running build > running build_py > writing /root/tmp/pylucene-4.4.0-1/jcc/jcc/config.py > copying jcc/config.py -> build/lib.linux-x86_64-2.7/jcc > copying jcc/classes/org/apache/jcc/PythonVM.class -> build/lib.linux-x86_6= 4-2.7/jcc/classes/org/apache/jcc > copying jcc/classes/org/apache/jcc/PythonException.class -> build/lib.linu= x-x86_64-2.7/jcc/classes/org/apache/jcc > running build_ext > building 'jcc' extension > gcc -pthread -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Ws= trict-prototypes -fPIC -D_jcc_lib -DJCC_VER=3D"2.17" -I/usr/java/jdk1.6.0_39= //include -I/usr/java/jdk1.6.0_39//include/linux -I_jcc -Ijcc/sources -I/too= ls/general/app/python-2.7.5-rhel6/include/python2.7 -c jcc/sources/jcc.cpp -= o build/temp.linux-x86_64-2.7/jcc/sources/jcc.o -DPYTHON -fno-strict-aliasin= g -Wno-write-strings > cc1plus: warning: command line option "-Wstrict-prototypes" is valid for A= da/C/ObjC but not for C++ > In file included from /tools/general/app/python-2.7.5-rhel6/include/python= 2.7/Python.h:8, > from jcc/sources/jcc.cpp:24: > /tools/general/app/python-2.7.5-rhel6/include/python2.7/pyconfig.h:1173:1:= warning: "_POSIX_C_SOURCE" redefined > In file included from /usr/include/stdio.h:28, > from jcc/sources/jcc.cpp:15: > /usr/include/features.h:162:1: warning: this is the location of the previo= us definition > In file included from /tools/general/app/python-2.7.5-rhel6/include/python= 2.7/Python.h:8, > from jcc/sources/jcc.cpp:24: > /tools/general/app/python-2.7.5-rhel6/include/python2.7/pyconfig.h:1195:1:= warning: "_XOPEN_SOURCE" redefined > In file included from /usr/include/stdio.h:28, > from jcc/sources/jcc.cpp:15: > /usr/include/features.h:164:1: warning: this is the location of the previo= us definition > gcc -pthread -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Ws= trict-prototypes -fPIC -D_jcc_lib -DJCC_VER=3D"2.17" -I/usr/java/jdk1.6.0_39= //include -I/usr/java/jdk1.6.0_39//include/linux -I_jcc -Ijcc/sources -I/too= ls/general/app/python-2.7.5-rhel6/include/python2.7 -c jcc/sources/JCCEnv.cp= p -o build/temp.linux-x86_64-2.7/jcc/sources/JCCEnv.o -DPYTHON -fno-strict-a= liasing -Wno-write-strings > cc1plus: warning: command line option "-Wstrict-prototypes" is valid for A= da/C/ObjC but not for C++ > In file included from /tools/general/app/python-2.7.5-rhel6/include/python= 2.7/Python.h:8, > from jcc/sources/JCCEnv.h:47, > from jcc/sources/JCCEnv.cpp:21: > /tools/general/app/python-2.7.5-rhel6/include/python2.7/pyconfig.h:1173:1:= warning: "_POSIX_C_SOURCE" redefined > In file included from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../i= nclude/c++/4.4.7/x86_64-redhat-linux/bits/os_defines.h:39, > from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../in= clude/c++/4.4.7/x86_64-redhat-linux/bits/c++config.h:1687, > from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../in= clude/c++/4.4.7/bits/stl_algobase.h:60, > from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../in= clude/c++/4.4.7/bits/stl_tree.h:62, > from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../in= clude/c++/4.4.7/map:60, > from jcc/sources/JCCEnv.cpp:15: > /usr/include/features.h:162:1: warning: this is the location of the previo= us definition > In file included from /tools/general/app/python-2.7.5-rhel6/include/python= 2.7/Python.h:8, > from jcc/sources/JCCEnv.h:47, > from jcc/sources/JCCEnv.cpp:21: > /tools/general/app/python-2.7.5-rhel6/include/python2.7/pyconfig.h:1195:1:= warning: "_XOPEN_SOURCE" redefined > In file included from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../i= nclude/c++/4.4.7/x86_64-redhat-linux/bits/os_defines.h:39, > from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../in= clude/c++/4.4.7/x86_64-redhat-linux/bits/c++config.h:1687, > from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../in= clude/c++/4.4.7/bits/stl_algobase.h:60, > from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../in= clude/c++/4.4.7/bits/stl_tree.h:62, > from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../in= clude/c++/4.4.7/map:60, > from jcc/sources/JCCEnv.cpp:15: > /usr/include/features.h:164:1: warning: this is the location of the previo= us definition > g++ -pthread -shared build/temp.linux-x86_64-2.7/jcc/sources/jcc.o build/t= emp.linux-x86_64-2.7/jcc/sources/JCCEnv.o -o build/lib.linux-x86_64-2.7/libj= cc.so -L/usr/java/jdk1.6.0_39//jre/lib/amd64 -ljava -L/usr/java/jdk1.6.0_39/= /jre/lib/amd64/server -ljvm -Wl,-rpath=3D/usr/java/jdk1.6.0_39//jre/lib/amd6= 4:/usr/java/jdk1.6.0_39//jre/lib/amd64/server -Wl,-S -lpython2.7 > /usr/bin/ld: cannot find -lpython2.7 > collect2: ld returned 1 exit status > error: command 'g++' failed with exit status 1 >=20 >=20 >=20 >=20 > ________________________________________________________________________ > The information contained in this e-mail is for the exclusive use of the=20= > intended recipient(s) and may be confidential, proprietary, and/or=20 > legally privileged. Inadvertent disclosure of this message does not=20 > constitute a waiver of any privilege. If you receive this message in=20 > error, please do not directly or indirectly use, print, copy, forward, > or disclose any part of this message. Please also delete this e-mail=20 > and all copies and notify the sender. Thank you.=20 >=20 > For alternate languages please go to http://bayerdisclaimer.bayerweb.com > ________________________________________________________________________