Tuesday, 15 June 2010

python - I can not compile Pillow in Windows XP -



python - I can not compile Pillow in Windows XP -

i installed mingw gcc, add together path path variable, create file in folder distutils.cfg lib / distutils in python installation. tried installing pip or download source code , run "python setup.py install". tried installing virtualenv , straight scheme well. log of pip:

------------------------------------------------------------ c:\entorno\scripts\pip-script.py run on 02/14/13 15:33:32 downloading/unpacking pillow running setup.py egg_info bundle pillow running egg_info writing pip-egg-info\pillow.egg-info\pkg-info writing top-level names pip-egg-info\pillow.egg-info\top_level.txt writing dependency_links pip-egg-info\pillow.egg-info\dependency_links.txt c:\python27\lib\distutils\dist.py:267: userwarning: unknown distribution option: 'use_2to3' warnings.warn(msg) warning: manifest_maker: standard file '-c' not found reading manifest file 'pip-egg-info\pillow.egg-info\sources.txt' reading manifest template 'manifest.in' warning: no previously-included files found matching '.hgignore' warning: no previously-included files found matching '.hgtags' warning: no previously-included files found matching 'buildme.bat' warning: no previously-included files found matching 'make-manifest.py' warning: no previously-included files found matching 'ship' warning: no previously-included files found matching 'ship.bat' warning: no previously-included files matching '*' found under directory 'tests' writing manifest file 'pip-egg-info\pillow.egg-info\sources.txt' source in c:\entorno\build\pillow has version 1.7.8, satisfies requirement pillow installing collected packages: pillow running setup.py install pillow running command c:\entorno\scripts\python.exe -c "import setuptools;__file__='c:\\entorno\\build\\pillow\\setup.py';exec(compile(open(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record c:\docume~1\aaa\config~1\temp\pip-8kdxpq-record\install-record.txt --single-version-externally-managed --install-headers c:\entorno\include\site\python2.7 running install running build running build_py running build_ext building '_imaging' extension creating build\temp.win32-2.7 creating build\temp.win32-2.7\release creating build\temp.win32-2.7\release\libimaging c:\mingw\bin\gcc.exe -mno-cygwin -mdll -o -wall -ilibimaging -ic:\entorno\include -ic:\python27\include -ic:\entorno\pc -c _imaging.c -o build\temp.win32-2.7\release\_imaging.o c:\mingw\bin\gcc.exe -mno-cygwin -mdll -o -wall -ilibimaging -ic:\entorno\include -ic:\python27\include -ic:\entorno\pc -c decode.c -o build\temp.win32-2.7\release\decode.o c:\mingw\bin\gcc.exe -mno-cygwin -mdll -o -wall -ilibimaging -ic:\entorno\include -ic:\python27\include -ic:\entorno\pc -c encode.c -o build\temp.win32-2.7\release\encode.o c:\mingw\bin\gcc.exe -mno-cygwin -mdll -o -wall -ilibimaging -ic:\entorno\include -ic:\python27\include -ic:\entorno\pc -c map.c -o build\temp.win32-2.7\release\map.o c:\mingw\bin\gcc.exe -mno-cygwin -mdll -o -wall -ilibimaging -ic:\entorno\include -ic:\python27\include -ic:\entorno\pc -c display.c -o build\temp.win32-2.7\release\display.o in file included display.c:40: libimaging/imdib.h:38: error: expected specifier-qualifier-list before 'uint8' display.c: in function '_fromstring': display.c:186: error: 'struct imagingdibinstance' has no fellow member named 'ysize' display.c:186: error: 'struct imagingdibinstance' has no fellow member named 'linesize' display.c:191: error: 'struct imagingdibinstance' has no fellow member named 'bits' display.c: in function '_tostring': display.c:204: error: 'struct imagingdibinstance' has no fellow member named 'bits' display.c:204: error: 'struct imagingdibinstance' has no fellow member named 'ysize' display.c:204: error: 'struct imagingdibinstance' has no fellow member named 'linesize' display.c: in function '_getattr': display.c:230: error: 'struct imagingdibinstance' has no fellow member named 'mode' display.c:232: error: 'struct imagingdibinstance' has no fellow member named 'xsize' display.c:232: error: 'struct imagingdibinstance' has no fellow member named 'ysize' display.c: in function 'pyimaging_drawwmf': display.c:761: warning: pointer targets in passing argument 2 of 'setwinmetafilebits' differ in signedness display.c:767: warning: pointer targets in passing argument 2 of 'setenhmetafilebits' differ in signedness display.c:793: warning: passing argument 4 of 'createdibsection' incompatible pointer type c:\python27\lib\distutils\dist.py:267: userwarning: unknown distribution option: 'use_2to3' warnings.warn(msg) error: command 'gcc' failed exit status 1 finish output command c:\entorno\scripts\python.exe -c "import setuptools;__file__='c:\\entorno\\build\\pillow\\setup.py';exec(compile(open(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record c:\docume~1\aaa\config~1\temp\pip-8kdxpq-record\install-record.txt --single-version-externally-managed --install-headers c:\entorno\include\site\python2.7: running install running build running build_py running build_ext building '_imaging' extension creating build\temp.win32-2.7 creating build\temp.win32-2.7\release creating build\temp.win32-2.7\release\libimaging c:\mingw\bin\gcc.exe -mno-cygwin -mdll -o -wall -ilibimaging -ic:\entorno\include -ic:\python27\include -ic:\entorno\pc -c _imaging.c -o build\temp.win32-2.7\release\_imaging.o c:\mingw\bin\gcc.exe -mno-cygwin -mdll -o -wall -ilibimaging -ic:\entorno\include -ic:\python27\include -ic:\entorno\pc -c decode.c -o build\temp.win32-2.7\release\decode.o c:\mingw\bin\gcc.exe -mno-cygwin -mdll -o -wall -ilibimaging -ic:\entorno\include -ic:\python27\include -ic:\entorno\pc -c encode.c -o build\temp.win32-2.7\release\encode.o c:\mingw\bin\gcc.exe -mno-cygwin -mdll -o -wall -ilibimaging -ic:\entorno\include -ic:\python27\include -ic:\entorno\pc -c map.c -o build\temp.win32-2.7\release\map.o c:\mingw\bin\gcc.exe -mno-cygwin -mdll -o -wall -ilibimaging -ic:\entorno\include -ic:\python27\include -ic:\entorno\pc -c display.c -o build\temp.win32-2.7\release\display.o in file included display.c:40: libimaging/imdib.h:38: error: expected specifier-qualifier-list before 'uint8' display.c: in function '_fromstring': display.c:186: error: 'struct imagingdibinstance' has no fellow member named 'ysize' display.c:186: error: 'struct imagingdibinstance' has no fellow member named 'linesize' display.c:191: error: 'struct imagingdibinstance' has no fellow member named 'bits' display.c: in function '_tostring': display.c:204: error: 'struct imagingdibinstance' has no fellow member named 'bits' display.c:204: error: 'struct imagingdibinstance' has no fellow member named 'ysize' display.c:204: error: 'struct imagingdibinstance' has no fellow member named 'linesize' display.c: in function '_getattr': display.c:230: error: 'struct imagingdibinstance' has no fellow member named 'mode' display.c:232: error: 'struct imagingdibinstance' has no fellow member named 'xsize' display.c:232: error: 'struct imagingdibinstance' has no fellow member named 'ysize' display.c: in function 'pyimaging_drawwmf': display.c:761: warning: pointer targets in passing argument 2 of 'setwinmetafilebits' differ in signedness display.c:767: warning: pointer targets in passing argument 2 of 'setenhmetafilebits' differ in signedness display.c:793: warning: passing argument 4 of 'createdibsection' incompatible pointer type c:\python27\lib\distutils\dist.py:267: userwarning: unknown distribution option: 'use_2to3' warnings.warn(msg) error: command 'gcc' failed exit status 1 ---------------------------------------- command c:\entorno\scripts\python.exe -c "import setuptools;__file__='c:\\entorno\\build\\pillow\\setup.py';exec(compile(open(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record c:\docume~1\aaa\config~1\temp\pip-8kdxpq-record\install-record.txt --single-version-externally-managed --install-headers c:\entorno\include\site\python2.7 failed error code 1 in c:\entorno\build\pillow exception information: traceback (most recent phone call last): file "c:\entorno\lib\site-packages\pip-1.2.1-py2.7.egg\pip\basecommand.py", line 107, in main status = self.run(options, args) file "c:\entorno\lib\site-packages\pip-1.2.1-py2.7.egg\pip\commands\install.py", line 261, in run requirement_set.install(install_options, global_options) file "c:\entorno\lib\site-packages\pip-1.2.1-py2.7.egg\pip\req.py", line 1166, in install requirement.install(install_options, global_options) file "c:\entorno\lib\site-packages\pip-1.2.1-py2.7.egg\pip\req.py", line 589, in install cwd=self.source_dir, filter_stdout=self._filter_install, show_stdout=false) file "c:\entorno\lib\site-packages\pip-1.2.1-py2.7.egg\pip\util.py", line 612, in call_subprocess % (command_desc, proc.returncode, cwd)) installationerror: command c:\entorno\scripts\python.exe -c "import setuptools;__file__='c:\\entorno\\build\\pillow\\setup.py';exec(compile(open(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record c:\docume~1\aaa\config~1\temp\pip-8kdxpq-record\install-record.txt --single-version-externally-managed --install-headers c:\entorno\include\site\python2.7 failed error code 1 in c:\entorno\build\pillow

it not library have problems, need install one.

thank you!

ps: google translation translatios, sorry.

when tried install pillow under windows, got similar gcc failure, , reason apparently outdated setuptools version.

installation docs say:

python wheel note: experimental. requires setuptools >=0.8 , pip >=1.4.1 $ pip install --use-wheel pillow

so, updated setuptools (making sure removed old version), , pip install started work flawlessly.

python mingw pip

No comments:

Post a Comment