473,842 Members | 1,601 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

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
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
find certain external libraries; see comments in the file for

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\Imag ing-1.1.4\PIL>cd /D C:\compile\Imag ing-1.1.4

C:\compile\Imag ing-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.e xe /DLL
/nologo /INCREMENTAL:NO /LIBPATH:libImag ing /
LIBPATH:jpeg-6b /LIBPATH:zlib /LIBPATH:C:\Pyth on24\libs
/LIBPATH:C:\Pyth on24\PCBuild Imaging.lib jpeg.lib zlib.lib
kernel32.lib user32.lib gdi32.lib /EXPORT:init_ima ging
build\temp.win3 2-2.4\Release\_im aging.obj build\temp.win3 2
-2.4\Release\dec ode.obj build\temp.win3 2-2.4\Release\enc ode.obj
build\temp.win3 2-2.4\Release\map .obj build\temp.wi
n32-2.4\Release\dis play.obj build\temp.win3 2-2.4\Release\out line.obj
build\temp.win3 2-2.4\Release\pat h.obj /OUT:bu
ild\lib.win32-2.4\_imaging.py d
/IMPLIB:build\te mp.win32-2.4\Release\_im aging.lib
LINK : fatal error LNK1181: cannot open input file 'Imaging.lib'
error: command '"C:\Program Files\Microsoft Visual C++ Toolkit
2003\bin\link.e xe"' failed with exit status 1181

C:\compile\Imag ing-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 ?


Jul 18 '05 #1
6 2379

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.

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.



Jul 18 '05 #3
Hi !

Fredrik Lundh did what is necessary. PIL for P 2.4 is at :
Michel Claveau

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


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 !!


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.


Jul 18 '05 #7

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

Similar topics

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 the occurrences of FilterType that may be relevant: ------- C:\sketch\sketch-0.7.12\Filter\filterobj.c: 949: PyTypeObject FilterType = {
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 : python-list-bounces+sebastien.giraud=eds.com@python.org De la part de Giraud, Sebastien Envoyé : mercredi 17 décembre 2003 17:21
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 compiled into native machine code (albeit with a lot of extra effort). For instance, type information is discovered when something is assigned to a variable or an anonymous piece of data is used in a program. Compiling Python bytecode into native...
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. I'm wondering if something of such had been attempted in python, as in compiling X language into .pyc. I do not understand the schematics of .pyc files but I assume that they are the so called python bytecode files. Or is there any...
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 itself. Everything you need is available at no costs (except download hassle and installation time). Once your system is set up properly its just a matter of running 'python setup.py build'. No longer waiting for someone else to build binaries and a...
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 with Python 2.4.1 on Solaris 2.8. Can anyone help? Thank you. -> python setup.py build creating /home/kzvbq3/linkchecker-3.2/_linkchecker_configdata.py running build running build_py
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 want to do, that is, I want the following syntax to be supported in the host language which I am developing: ###################################################### # scripts in the host language
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. Ok, so I did ../configure --prefix=/Users/tbrannon/Documents/Python/Swarm/Python-2.5 but during make install I get this:
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 install Password: running install
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/
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.