From e55a94567a6017ae104cae5773f275da2fb78823 Mon Sep 17 00:00:00 2001 From: Eric Soroos Date: Mon, 18 Mar 2013 22:39:30 -0700 Subject: [PATCH 1/6] Starting to integrate README --- README.rst | 64 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) diff --git a/README.rst b/README.rst index a61e4cb1d..1f7269764 100644 --- a/README.rst +++ b/README.rst @@ -79,6 +79,70 @@ Current platform support for Pillow. Binary distributions are contributed for ea .. [1] x86 only .. [2] In some cases, x86 support may indicate 32-bit compilation on 64-bit architecture (vs. compilation on 32-bit hardware). +Installation +============ + +If there is a binary package for your system, that is the preferred way of obtaining Pillow. + +Building from Source +-------------------- + +Some of Pillow's features require external libraries. + +* libjpeg provides JPEG functionality. Pillow has been tested with libjpev versions 6b and 8 +* zlib provides access to compressed PNGs +* libtiff provides group4 tiff functionality. Pillow has been tested with versions 3.x and 4.0 +* libfreetype provides type related services +* littlecms provides color management +* libwebp provides the Webp format. + +If the prerequisites are installed in the standard library locations for your machine, no configuration shoule be required. If they are installed in a non-standard location, you may need to configure setuptools to use those locations. See [[url here]] for more information. + +Once you have assembed the prerequisites, run: + +

+    $ pip install pillow
+
+ +Platform Specific Instructions +------------------------------ + +** Ubuntu ** + +If you didn't build Python from sources, make sure you have Python's build support files on your machine. + +

+sudo apt-get install python-dev python-setuptools
+# or for python 3
+sudo apt-get install python3-dev python3-setuptools
+
+ +The library prerequisites are installed with: + +

+# Ubuntu 10.04 LTS
+sudo apt-get install libtiff4-dev libjpeg62-dev zlib1g-dev libfreetype6-dev liblcms1-dev
+# Ubuntu 12.04 LTS
+sudo apt-get install libtiff4-dev libjpeg8-dev zlib1g-dev libfreetype6-dev liblcms1-dev libwebp-dev
+
+ + +Porting +======= + +Pillow is a functional dropin for the Python Imaging Library. To run under Pillow, existing code needs to be modified to import the Imaging modules from the PIL namespace instead of the global namespace. + +Change: +

+import Image
+
+to +

+from PIL import Image
+
+ + + Python Imaging Library ====================== From eb4db1c951fa4d81da44e322de1e31069e2599ec Mon Sep 17 00:00:00 2001 From: Eric Soroos Date: Mon, 18 Mar 2013 22:51:37 -0700 Subject: [PATCH 2/6] Rst, not gfm. --- README.rst | 59 +++++++++++++++++++++++++++++++----------------------- 1 file changed, 34 insertions(+), 25 deletions(-) diff --git a/README.rst b/README.rst index 1f7269764..b817e2220 100644 --- a/README.rst +++ b/README.rst @@ -89,42 +89,53 @@ Building from Source Some of Pillow's features require external libraries. -* libjpeg provides JPEG functionality. Pillow has been tested with libjpev versions 6b and 8 +* libjpeg provides JPEG functionality. + + * Pillow has been tested with libjpev versions 6b and 8 + * zlib provides access to compressed PNGs -* libtiff provides group4 tiff functionality. Pillow has been tested with versions 3.x and 4.0 + +* libtiff provides group4 tiff functionality. + + * Pillow has been tested with versions 3.x and 4.0 + * libfreetype provides type related services + * littlecms provides color management + * libwebp provides the Webp format. If the prerequisites are installed in the standard library locations for your machine, no configuration shoule be required. If they are installed in a non-standard location, you may need to configure setuptools to use those locations. See [[url here]] for more information. Once you have assembed the prerequisites, run: -

+::
     $ pip install pillow
-
Platform Specific Instructions ------------------------------ -** Ubuntu ** +Mac OSX +******* +Ubuntu or Debian +****** If you didn't build Python from sources, make sure you have Python's build support files on your machine. -

-sudo apt-get install python-dev python-setuptools
-# or for python 3
-sudo apt-get install python3-dev python3-setuptools
-
+:: + sudo apt-get install python-dev python-setuptools + # or for python 3 + sudo apt-get install python3-dev python3-setuptools -The library prerequisites are installed with: -

-# Ubuntu 10.04 LTS
-sudo apt-get install libtiff4-dev libjpeg62-dev zlib1g-dev libfreetype6-dev liblcms1-dev
-# Ubuntu 12.04 LTS
-sudo apt-get install libtiff4-dev libjpeg8-dev zlib1g-dev libfreetype6-dev liblcms1-dev libwebp-dev
-
+The library prerequisites are installed with:: + # Ubuntu 10.04 LTS + sudo apt-get install libtiff4-dev libjpeg62-dev zlib1g-dev libfreetype6-dev liblcms1-dev + # Ubuntu 12.04 LTS + sudo apt-get install libtiff4-dev libjpeg8-dev zlib1g-dev libfreetype6-dev liblcms1-dev libwebp-dev + +##Undone## Debian library versions. + Porting @@ -132,14 +143,12 @@ Porting Pillow is a functional dropin for the Python Imaging Library. To run under Pillow, existing code needs to be modified to import the Imaging modules from the PIL namespace instead of the global namespace. -Change: -

-import Image
-
-to -

-from PIL import Image
-
+Change:: + import Image + +to:: + from PIL import Image + From 6471b5899917d95c9a31204616ab7dbef3d37c39 Mon Sep 17 00:00:00 2001 From: Eric Soroos Date: Mon, 18 Mar 2013 22:53:41 -0700 Subject: [PATCH 3/6] ::block formatting --- README.rst | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.rst b/README.rst index b817e2220..73b97f983 100644 --- a/README.rst +++ b/README.rst @@ -110,6 +110,7 @@ If the prerequisites are installed in the standard library locations for your ma Once you have assembed the prerequisites, run: :: + $ pip install pillow Platform Specific Instructions @@ -123,12 +124,14 @@ Ubuntu or Debian If you didn't build Python from sources, make sure you have Python's build support files on your machine. :: + sudo apt-get install python-dev python-setuptools # or for python 3 sudo apt-get install python3-dev python3-setuptools The library prerequisites are installed with:: + # Ubuntu 10.04 LTS sudo apt-get install libtiff4-dev libjpeg62-dev zlib1g-dev libfreetype6-dev liblcms1-dev # Ubuntu 12.04 LTS @@ -144,9 +147,11 @@ Porting Pillow is a functional dropin for the Python Imaging Library. To run under Pillow, existing code needs to be modified to import the Imaging modules from the PIL namespace instead of the global namespace. Change:: + import Image to:: + from PIL import Image From 2838015c8492c428ca48df347c2235330b5992c1 Mon Sep 17 00:00:00 2001 From: wiredfool Date: Tue, 9 Apr 2013 12:25:55 -0700 Subject: [PATCH 4/6] header formating --- README.rst | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/README.rst b/README.rst index f7e559f76..e3b0e161b 100644 --- a/README.rst +++ b/README.rst @@ -24,7 +24,7 @@ Why a fork? PIL is not setuptools compatible. Please see http://mail.python.org/pipermail/image-sig/2010-August/006480.html for a more detailed explanation. Also, PIL's current bi-yearly (or greater) release schedule is too infrequent to accomodate the large number and frequency of issues reported. Porting -======= +------- Pillow is a functional dropin for the Python Imaging Library. To run under Pillow, existing code needs to be modified to import the Imaging @@ -101,12 +101,12 @@ Current platform support for Pillow. Binary distributions are contributed for ea .. [2] In some cases, x86 support may indicate 32-bit compilation on 64-bit architecture (vs. compilation on 32-bit hardware). Installation -============ +------------ If there is a binary package for your system, that is the preferred way of obtaining Pillow. Building from Source --------------------- ++++++++++ Some of Pillow's features require external libraries. @@ -135,7 +135,7 @@ Once you have assembed the prerequisites, run: $ pip install pillow Platform Specific Instructions ------------------------------- ++++++++++ Mac OSX ******* @@ -158,6 +158,8 @@ The library prerequisites are installed with:: # Ubuntu 12.04 LTS sudo apt-get install libtiff4-dev libjpeg8-dev zlib1g-dev libfreetype6-dev liblcms1-dev libwebp-dev +Windows +******* Donations --------- From 88d38e80b486b5871d80ce63d9c6251e12d59dfb Mon Sep 17 00:00:00 2001 From: wiredfool Date: Tue, 9 Apr 2013 12:43:23 -0700 Subject: [PATCH 5/6] OSX instructions --- README.rst | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/README.rst b/README.rst index e3b0e161b..59300a650 100644 --- a/README.rst +++ b/README.rst @@ -139,6 +139,19 @@ Platform Specific Instructions Mac OSX ******* +We don't currently have official binary builds for OSX. You'll need Xcode to build the package. Xcode 4.2 on 10.6 will work for the Official Python binary distribution, otherwise, use whatever Xcode compiled your python. + +The easiest way to install the prerequisites is to use homebrew: http://mxcl.github.com/homebrew/ . Then run: + +:: + +$ brew install libtiff lbjpeg webp littlecms + +If you've built your own python, then you should be able to install Pillow using + +:: + +$ pip install pillow Ubuntu or Debian ****** From ce3b7231b45e3dcaddb3a0020dc5d09f00dd838a Mon Sep 17 00:00:00 2001 From: wiredfool Date: Tue, 9 Apr 2013 13:08:45 -0700 Subject: [PATCH 6/6] wording, undone --- README.rst | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.rst b/README.rst index 59300a650..6d7a52fcb 100644 --- a/README.rst +++ b/README.rst @@ -38,7 +38,9 @@ to:: from PIL import Image -Note that if your code imports _imaging, that will also be hosted in the PIL namespace. The preferred method of importing _imaging is:: +Note that if your code imports _imaging, that will also be hosted in +the PIL namespace. The preferred, future proof method of importing the +private _imaging module is:: from PIL import Image _imaging = Image.core @@ -103,7 +105,7 @@ Current platform support for Pillow. Binary distributions are contributed for ea Installation ------------ -If there is a binary package for your system, that is the preferred way of obtaining Pillow. +If there is a binary package for your system, that is the preferred way of obtaining Pillow. [[UNDONE: Binary links]] Building from Source +++++++++