473,395 Members | 1,668 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Compiling PIL for Python 2.4

I'll post this to the image-sig as well, but the audience is a bit
wider here.

I've just upgraded to Python 2.4. I've installed the free microsoft
optimising compiler and hacked distutils to use it - following the
instructiosn from http://www.vrplumber.com/programming/mstoolkit/ . It
works great and I've built a windows installer for PyCrypto 2.0.

I'm attempting to compile PIL for python 2.4. The build instructions
for windows say :

If you're using Python 2.0 or later, you can use the setup.py
script
to build the library. The following commands should do the trick:

$ python setup.py build
$ python setup.py install

You may need to tweak the setup.py file somewhat in order to make
it
find certain external libraries; see comments in the file for
details.

Right - so you actually need to *get* the zlib and jpeg libraries,
which I've done. I've not yet got the right header/include files for
Tkinter, but it should work without them (just not build those files).
Except it bombs out :
C:\compile\Imaging-1.1.4\PIL>cd /D C:\compile\Imaging-1.1.4

C:\compile\Imaging-1.1.4>setup.py build
*** Cannot find Tcl/Tk headers and library files.
*** To build the Tkinter interface, set the TCLROOT
*** variable in the setup.py file.
running build
running build_py
running build_ext
building '_imaging' extension
C:\Program Files\Microsoft Visual C++ Toolkit 2003\bin\link.exe /DLL
/nologo /INCREMENTAL:NO /LIBPATH:libImaging /
LIBPATH:jpeg-6b /LIBPATH:zlib /LIBPATH:C:\Python24\libs
/LIBPATH:C:\Python24\PCBuild Imaging.lib jpeg.lib zlib.lib
kernel32.lib user32.lib gdi32.lib /EXPORT:init_imaging
build\temp.win32-2.4\Release\_imaging.obj build\temp.win32
-2.4\Release\decode.obj build\temp.win32-2.4\Release\encode.obj
build\temp.win32-2.4\Release\map.obj build\temp.wi
n32-2.4\Release\display.obj build\temp.win32-2.4\Release\outline.obj
build\temp.win32-2.4\Release\path.obj /OUT:bu
ild\lib.win32-2.4\_imaging.pyd
/IMPLIB:build\temp.win32-2.4\Release\_imaging.lib
LINK : fatal error LNK1181: cannot open input file 'Imaging.lib'
error: command '"C:\Program Files\Microsoft Visual C++ Toolkit
2003\bin\link.exe"' failed with exit status 1181

C:\compile\Imaging-1.1.4>

_imaging.obj is being created - but not linked. I can't find an
Imaging.lib file anywhere. Anyone got any clues for me ?

Regards,
Fuzzy
http://www.voidspace.org.uk/atlantib...thonutils.html

Jul 18 '05 #1
6 2344

Fuzzyman schrieb:
I'll post this to the image-sig as well, but the audience is a bit
wider here.


Sorry, can't help you on the rest (which seems to be rather MS and
compiler specific), but in general: cross-posting is not a good idea. Read
any of the many copies of the Netiquette on this topic. In short,
submitting a cross-post reads as: you haven't actually thought about your
problem but want to bug as many people as possible with it.

Stefan
Jul 18 '05 #2
Hmmm... disagree. Not eevryone who has experience of compilation (even
compiling PIL) will be on the sig. The sifg is probably the 'right'
place - but my experience is that a lot of htem are very low traffic.

This is also a topic of general interest to many pythoners. See the
number of questions regarding configuring distutils recently.

Regards,

Fuzzy
http://www.voidspace.org.uk/atlantib...thonutils.html

Jul 18 '05 #3
Hi !

Fredrik Lundh did what is necessary. PIL for P 2.4 is at :
http://effbot.org/downloads/#PIL
Michel Claveau


Jul 18 '05 #4
Blimey - there's a lot of typos in my last post... ugh....

Regards,
Fuzzy
http://www.voidspace.org.uk/atlantib...thonutils.html

Jul 18 '05 #5
Great - and thanks for the info.... it was interesting messing around
with the compiler.... but I'm not goign to do it for the heck of it !!
Thanks

Fuzzy
http://www.voidspace.org.uk/atlantib...thonutils.html

Jul 18 '05 #6
Stefan Behnel wrote:
Sorry, can't help you on the rest (which seems to be rather MS and compiler specific)
no, it's Python 2.4 specific. this is a python newsgroup.
In short, submitting a cross-post reads as: you haven't actually thought
about your problem but want to bug as many people as possible with it.


people who might have successfully compiled Python 2.4 extensions,
that is. they tend to visit this newsgroup from time to time.

</F>

Jul 18 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Joonas Paalasmaa | last post by:
Hi, When compiling Sketch's streamfilter C extension the errors below are raised during linking. What could cause the errors? (Python 2.3, MinGw 1.1 with GCC 2.95.3-6, Windows 98) Here are...
2
by: Giraud, Sebastien | last post by:
Ok I was still looking for a 'make like' software and found one : MacMillan Entreprise Just work fine even if it's not easy to handle it... -----Message d'origine----- De :...
0
by: Johnathan Doe | last post by:
I've been thinking about what the issues would be in compiling Python into native machine code, and since type information is important in Python, it seems possible that Python code can be...
29
by: Maurice LING | last post by:
Hi, I remembered reading a MSc thesis about compiling Perl to Java bytecodes (as in java class files). At least, it seems that someone had compiled scheme to java class files quite successfully....
6
by: Martin Bless | last post by:
The good news: Along with Python-2.4 comes really good news to Windows users. Yes, you now CAN build extension modules yourself using the SAME C++ compiler and linker Python is built with...
0
by: mmarkzon | last post by:
I have been struggling compiling linkchecker from http://linkchecker.sourceforge.net/. The last thing I get is "error: command 'gcc' failed with exit status 1" which is not very helpful. This is...
0
by: phoolimin | last post by:
Dear all, I am trying to embed python into another scripting language, to do this I need to solve a number of problems on importing or compiling python script. First let me state what exactly I...
2
by: metaperl | last post by:
I've tried both Python 2.4.4 and Python 2.5. I'm trying to build from source and install under a local directory Swarm since OpenSwarm requires builds of Postgres and Python under it's control. ...
11
by: ZMY | last post by:
Dear all, I am a real newbie for both python and QNX, but I am still trying to compile Numeric-24.2 under QNX4.25 with python 2.2. I got following error message: $ sudo python setup.py...
2
by: eliben | last post by:
On Jun 27, 3:10 pm, eliben <eli...@gmail.comwrote: Problem solved: http://eli.thegreenplace.net/2008/06/28/compiling-python-extensions-with-distutils-and-mingw/
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.