Path: csiph.com!usenet.pasdenom.info!aioe.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.000 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'anyway.': 0.05; 'importing': 0.05; 'subject:Python': 0.06; 'odd': 0.07; 'paths': 0.07; 'skip:` 10': 0.07; 'statically': 0.07; 'subject:installation': 0.07; 'tkinter': 0.07; 'failed:': 0.09; 'permissions': 0.09; 'setup.py': 0.09; 'skip:/ 10': 0.09; 'skip:b 70': 0.09; 'variant': 0.09; 'cc:addr:python-list': 0.11; 'python': 0.11; 'gui': 0.12; 'thread': 0.14; '-o2': 0.16; 'cc:name:python list': 0.16; 'compute': 0.16; 'luck,': 0.16; 'renaming': 0.16; 'run:': 0.16; 'skip:b 80': 0.16; 'skip:t 110': 0.16; 'subject: \n ': 0.16; 'sudo': 0.16; 'uploading': 0.16; 'for?': 0.16; 'thanks,': 0.17; 'wrote:': 0.18; 'library': 0.18; 'app': 0.19; 'ticket': 0.19; 'basically': 0.19; 'thu,': 0.19; '8bit%:5': 0.22; 'machine': 0.22; '>>>': 0.22; 'cc:addr:gmail.com': 0.22; 'email addr:gmail.com>': 0.22; 'tests': 0.22; 'cc:addr:python.org': 0.22; 'install': 0.23; 'cc:2**1': 0.23; 'error': 0.23; 'compilation': 0.24; 'skip': 0.24; 'skip:l 30': 0.24; 'skip:\xa0 20': 0.24; 'login': 0.25; 'options': 0.25; 'extension': 0.26; 'certain': 0.27; 'header:In-Reply-To:1': 0.27; 'specifically': 0.29; '(this': 0.29; 'am,': 0.29; '8bit%:3': 0.30; 'said,': 0.30; 'specified': 0.30; 'message-id:@mail.gmail.com': 0.30; "i'm": 0.30; 'faster,': 0.31; 'file:': 0.31; 'gcc': 0.31; 'loading': 0.31; 'requesting': 0.31; 'file': 0.32; 'there.': 0.32; 'probably': 0.32; 'skip:- 30': 0.32; 'run': 0.32; 'quite': 0.32; 'open': 0.33; 'linux': 0.33; 'running': 0.33; 'skip:b 30': 0.33; 'updated': 0.34; 'problem': 0.35; 'subject: (': 0.35; 'info': 0.35; 'skip:- 50': 0.35; 'problem.': 0.35; 'but': 0.35; 'received:google.com': 0.35; 'add': 0.35; 'building': 0.35; 'there': 0.35; 'really': 0.36; '(e.g.,': 0.36; 'installing': 0.36; 'doing': 0.36; 'thanks': 0.36; 'similar': 0.36; 'should': 0.36; 'skip:- 20': 0.37; 'level': 0.37; 'architecture': 0.38; '8bit%:4': 0.38; 'hat': 0.38; 'jason': 0.38; 'machines': 0.38; 'files': 0.38; 'skip:- 10': 0.38; 'pm,': 0.38; 'rather': 0.38; 'anything': 0.39; 'skip:& 20': 0.39; 'received:74.125': 0.39; 'though,': 0.39; 'either': 0.39; 'easy': 0.60; 'most': 0.60; 'identify': 0.61; 'staff': 0.61; 'such': 0.63; 'afraid': 0.65; 'finally': 0.65; 'to:addr:gmail.com': 0.65; 'export': 0.74; 'you:': 0.81; './configure': 0.84; 'answer:': 0.84; 'hassle': 0.84; 'skip:/ 30': 0.84; 'understand,': 0.84; 'was:': 0.91; '\xa0there': 0.91; '***': 0.95; '2013': 0.98 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=FD3wvhgDaetHyupH87HmN4SkydqQVoNvBkgxaMxlfj8=; b=Few3RcMCSrLDzdr1FvTyOfGnxiinbofITIuPLi/RBxk7hDJ3jGhq4nN+rZMxmY1pL1 5F6/p/Xb4Syj/EQtYnxRApLF3FwR1EBlpG/+61vcFLOMPKeTRwXRedwg9vPyIRe06lCh Pq/OEnNJS+sHKxJixHLDb8AMWiLUQrYbf/nNofC5+Kln3CNo0KSrZ/9aa7J4Eih7Zzf0 /oYsXrD00H287gWX3S0UwI6xzcUcjqe5UnyDqUjPAyYVn8P1Hcmv9maWdkWsHBBpHwbE p/zmbHubyepiG7BArX7IQ33CgC+952bKhxPc64V1zTT2maARYLiEbuiLkvlBM8EQDERF qR/w== MIME-Version: 1.0 X-Received: by 10.15.43.73 with SMTP id w49mr32861416eev.12.1366308577031; Thu, 18 Apr 2013 11:09:37 -0700 (PDT) In-Reply-To: References: <1366122614066-5014440.post@n6.nabble.com> Date: Thu, 18 Apr 2013 14:09:36 -0400 Subject: Re: Preparing sqlite, dl and tkinter for Python installation (no admin rights) From: James Jong To: Jason Swails Content-Type: multipart/alternative; boundary=089e016813106358c404daa68196 Cc: python list X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 319 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1366308578 news.xs4all.nl 2255 [2001:888:2000:d::a6]:59611 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:43848 --089e016813106358c404daa68196 Content-Type: text/plain; charset=ISO-8859-1 All I finally solved the problem. The problem was that setup.py tests loading the dynamic library libtk (this I don't understand, since I though Python would statically link against TCL, TK and SQLITE. Either way, I have updated the thread at StackOverflow with the answer: http://stackoverflow.com/questions/16026348/preparing-tkinter-and-sqlite3-for-python-installation-no-admin-rights/16090051#16090051 but basically the answer was: Add the following include paths through `CPPFLAGS` * /path_to/sqlite3/include * /path_to/tcl/include * /path_to/tk/include the following lib paths through `LDFLAGS` * /path_to/sqlite3/lib * /path_to/tcl/lib * /path_to/tk/lib and the following lib paths through `LD_LIBRARY_PATH`: * /path_to/sqlite/lib * /path_to/tcl/lib * /path_to/tk/lib Thanks, James On Thu, Apr 18, 2013 at 12:24 PM, James Jong wrote: > Thanks Jason. I have pinpointed the location of the error to a very > specific gcc line. I am reproducing the error below (very easy to read): > > I run: > > ================================================================== > export CPPFLAGS='-I/opt/sqlite-3.7.16.2/include -I/opt/tk8.6.0/include > -I/opt/tcl8.6.0/include/' > > export LDFLAGS='-L/opt/sqlite-3.7.16.2/lib -L/opt/tk8.6.0/lib/ > -L/opt/tcl8.6.0/lib/ ./configure --prefix=/path_to_python-2.7.4 > --enable-shared > ================================================================== > > and then I run make and I got the following: > > ================================================================== > .... > building '_tkinter' extension > > gcc -pthread -fPIC -fno-strict-aliasing > -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -DWITH_APPINIT=1 > -I/usr/X11/include -I. -IInclude -I./Include > -I/opt/sqlite/sqlite-3.7.16.2/include -I/opt/tk8.6.0/include > -I/opt/tcl8.6.0/include -I/usr/local/include > -I/opt/python/src/Python-2.7.4/Include -I/opt/python/src/Python-2.7.4 -c > /opt/python/src/Python-2.7.4/Modules/_tkinter.c -o > build/temp.linux-x86_64-2.7/opt/python/src/Python-2.7.4/Modules/_tkinter.o > > gcc -pthread -fPIC -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 > -Wall -Wstrict-prototypes -DWITH_APPINIT=1 -I/usr/X11/include -I. > -IInclude -I./Include -I/opt/sqlite/sqlite-3.7.16.2/include > -I/opt/tk8.6.0/include -I/opt/tcl8.6.0/include -I/usr/local/include > -I/opt/python/src/Python-2.7.4/Include -I/opt/python/src/Python-2.7.4 -c > /opt/python/src/Python-2.7.4/Modules/tkappinit.c -o > build/temp.linux-x86_64-2.7/opt/python/src/Python-2.7.4/Modules/tkappinit.o > > gcc -pthread -shared -L/opt/sqlite/sqlite-3.7.16.2/lib > -L/opt/tk8.6.0/lib/ -L/opt/tcl8.6.0/lib/ -L/opt/sqlite/sqlite-3.7.16.2/lib > -L/opt/tk8.6.0/lib/ -L/opt/tcl8.6.0/lib/ -I. -IInclude -I./Include > -I/opt/sqlite/sqlite-3.7.16.2/include -I/opt/tk8.6.0/include > -I/opt/tcl8.6.0/include > build/temp.linux-x86_64-2.7/opt/python/src/Python-2.7.4/Modules/_tkinter.o > build/temp.linux-x86_64-2.7/opt/python/src/Python-2.7.4/Modules/tkappinit.o > -L/usr/X11/lib -L/opt/sqlite/sqlite-3.7.16.2/lib -L/opt/tk8.6.0/lib/ > -L/opt/tcl8.6.0/lib/ -L/usr/local/lib -L. -ltk8.6 -ltcl8.6 -lX11 > -lpython2.7 -o build/lib.linux-x86_64-2.7/_tkinter.so > > *** WARNING: renaming "_tkinter" since importing it failed: libtk8.6.so: > cannot open shared object file: No such file or directory > ... > ================================================================== > > The odd thing is that I can see `libtk8.6.so` under /opt/tcl8.6.0/lib, > as I specified with `LDFLAGS`: > > ================================================================== > cd /opt/tcl8.6.0/lib > ls > . > ../ > pkgconfig > tk8.6 > libtkstub8.6.a > tkConfig.sh > libtk8.6.so > ================================================================== > > The file libtk8.6.so has 1.5M and is definitely there. > > So why did that compilation fail? > > James > > > > On Thu, Apr 18, 2013 at 11:05 AM, Jason Swails wrote: > >> >> >> >> On Thu, Apr 18, 2013 at 10:37 AM, James Jong wrote: >> >>> Thanks so much Chris. This is part of a super computer and I am afraid I >>> don't have access to a machine with sudo permissions and similar >>> architecture & OS. >>> >>> Is there any way to active higher level of verbosity during the build >>> process to identify what is failing? Or anything specifically I should >>> watch for? >>> >> >> Most supercomputers I'm familiar with have some variant of Linux running >> (e.g., SUSE or Red Hat are quite common). Some of these machines only have >> barebone kernels on the compute nodes, though, and have a fully-fledged >> Linux OS only on the login nodes... This info is typically on the website >> for that supercomputer (if it has one), or any other available >> documentation. >> >> That said, there are other options available that are probably less of a >> hassle for you: >> >> 1) Skip tkinter unless you _know_ you really need it. Do you plan on >> doing X-forwarding when you log in? Can you run the GUI app on your local >> machine before uploading the files you need for computation? Running GUIs >> locally rather than over the network is typically much faster, anyway. >> >> 2) Submit a ticket to the supercomputer staff requesting that they >> install the software you need. There may be other 'gotchas' associated >> with installing certain software on supercomputers that the staff would >> know best. >> >> Good luck, >> Jason >> > > --089e016813106358c404daa68196 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
All

I finally solved the problem. The p= roblem was that setup.py tests loading the dynamic library libtk (this I do= n't understand, since I though Python would statically link against TCL= , TK and SQLITE.=A0

Either way, I have updated the thread at StackOverflow = with the answer:

but basically the answer was:

Add the following include paths through `CPPFLAGS`
* /path_to/sqlite3/include
* /path_to/tcl/include
* /path_to/tk/include

the following lib paths= through `LDFLAGS`=A0

* /path_to/sqlite3/lib
=
* /path_to/tcl/lib
* /path_to/tk/lib

and the following lib paths through `LD_LIBRARY_PATH`:

=
* /path_to/sqlite/lib
* /path_to/tcl/lib
* /path_t= o/tk/lib

Thanks,

James


On Thu, Apr 18, 2013 at 12:24 PM, James Jong <ri= bonucleico@gmail.com> wrote:
Thanks Jason. I have pinpoi= nted the location of the error to a very specific gcc line. I am reproducin= g the error below (very easy to read):

I run:

=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
export CPPFLAGS=3D'-I/opt/sqlite-3.7.16.2/include -I/opt/tk8= .6.0/include =A0-I/opt/tcl8.6.0/include/'

expo= rt LDFLAGS=3D'-L/opt/sqlite-3.7.16.2/lib -L/opt/tk8.6.0/lib/ =A0-L/opt/= tcl8.6.0/lib/ =A0./configure --prefix=3D/path_to_python-2.7.4 --enable-shar= ed
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D

and then I run make and I got =A0the following:

=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
....
building '_tkinter' extension=A0

=
gcc -pthread -fPIC -fno-strict-aliasing
-g -O2 -DNDEBU= G -g -fwrapv -O3 -Wall -Wstrict-prototypes -DWITH_APPINIT=3D1 -I/usr/X11/in= clude -I. -IInclude -I./Include -I/opt/sqlite/sqlite-3.7.16.2/include -I/op= t/tk8.6.0/include -I/opt/tcl8.6.0/include -I/usr/local/include -I/opt/pytho= n/src/Python-2.7.4/Include -I/opt/python/src/Python-2.7.4 -c /opt/python/sr= c/Python-2.7.4/Modules/_tkinter.c -o build/temp.linux-x86_64-2.7/opt/python= /src/Python-2.7.4/Modules/_tkinter.o

gcc -pthread -fPIC -fno-strict-aliasing -g -O2 -DNDEBUG= -g -fwrapv -O3
-Wall -Wstrict-prototypes -DWITH_APPINIT=3D1 -I/u= sr/X11/include -I. -IInclude -I./Include -I/opt/sqlite/sqlite-3.7.16.2/incl= ude -I/opt/tk8.6.0/include -I/opt/tcl8.6.0/include -I/usr/local/include -I/= opt/python/src/Python-2.7.4/Include -I/opt/python/src/Python-2.7.4 -c /opt/= python/src/Python-2.7.4/Modules/tkappinit.c -o build/temp.linux-x86_64-2.7/= opt/python/src/Python-2.7.4/Modules/tkappinit.o

gcc -pthread -shared -L/opt/sqlite/sqlite-3.7.16.2/lib<= /div>
-L/opt/tk8.6.0/lib/ -L/opt/tcl8.6.0/lib/ -L/opt/sqlite/sqlite-3.7= .16.2/lib -L/opt/tk8.6.0/lib/ -L/opt/tcl8.6.0/lib/ -I. -IInclude -I./Includ= e -I/opt/sqlite/sqlite-3.7.16.2/include -I/opt/tk8.6.0/include -I/opt/tcl8.= 6.0/include build/temp.linux-x86_64-2.7/opt/python/src/Python-2.7.4/Modules= /_tkinter.o
build/temp.linux-x86_64-2.7/opt/python/src/Python-2.7.4/Modules/tkappi= nit.o
-L/usr/X11/lib -L/opt/sqlite/sqlite-3.7.16.2/lib -L/opt/tk8= .6.0/lib/ -L/opt/tcl8.6.0/lib/ -L/usr/local/lib -L. -ltk8.6 -ltcl8.6 -lX11 = -lpython2.7 -o build/lib.linux-x86_64-2.7/_tkinter.so

*** WARNING: renaming "_tkinter" since import= ing it failed: libtk8.6.so= : cannot open shared object file: No such file or directory
...
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D

The odd thing is that I can see `libtk8.6.so` under /opt/tcl8.6.0/lib, =A0as I specified wit= h `LDFLAGS`:

=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
cd /opt/tcl8.6.0/lib
ls
.=A0
.= ./=A0
pkgconfig=A0
tk8.6=A0
libtkstub8.6.a=A0
tkConfig.sh=A0
libtk8.6.so
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D

The file libtk8.6.so =A0has 1.5M and is definitely there.

So why did that compilation fail?

James



On Thu, Apr 18, 2013 = at 11:05 AM, Jason Swails <jason.swails@gmail.com> wrot= e:



<= div> On Thu, Apr 18, 2013 at 10:37 AM, James Jong <ribonucleico@gmail.com= > wrote:
Thanks so much Chris. This = is part of a super computer and I am afraid I don't have access to a ma= chine with sudo permissions and similar architecture & OS.

Is there any way to active higher level of verbosity during = the build process to identify what is failing? Or anything specifically I s= hould watch for?

Most supercomputers I'm familiar with have some variant of Linux runnin= g (e.g., SUSE or Red Hat are quite common). =A0Some of these machines only = have barebone kernels on the compute nodes, though, and have a fully-fledge= d Linux OS only on the login nodes... This info is typically on the website= for that supercomputer (if it has one), or any other available documentati= on.

That sa= id, there are other options available that are probably less of a hassle fo= r you:

1) Skip tkinter unless you _know_ yo= u really need it. =A0Do you plan on doing X-forwarding when you log in? =A0= Can you run the GUI app on your local machine before uploading the files yo= u need for computation? =A0Running GUIs locally rather than over the networ= k is typically much faster, anyway.

2) Subm= it a ticket to the supercomputer staff requesting that they install the sof= tware you need. =A0There may be other 'gotchas' associated with ins= talling certain software on supercomputers that the staff would know best.<= /div>

Good lu= ck,
Jason


--089e016813106358c404daa68196--