From f1ad1216cafcc648ccf570419a788e0e4b9ff0ad Mon Sep 17 00:00:00 2001 From: Lovell Fuller Date: Sun, 5 Apr 2015 22:42:14 +0100 Subject: [PATCH] Add support for Windows #19 Requires VIPS_HOME environment variable --- README.md | 9 +++++++++ binding.gyp | 53 ++++++++++++++++++++++++++++++++++++++++--------- test/unit/io.js | 2 +- 3 files changed, 54 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 56de7974..eecd87c1 100755 --- a/README.md +++ b/README.md @@ -83,6 +83,15 @@ The _gettext_ dependency of _libvips_ [can lead](https://github.com/lovell/sharp brew link gettext --force +### Windows + +Requires x86 32-bit Node.js or io.js (use `iojs.exe` rather than `node.exe`). +The WebP format is currently unsupported. + +1. [Download](http://www.vips.ecs.soton.ac.uk/supported/current/win32/) and unzip `vips-dev.x.y.z.zip`. +2. Set the `VIPS_HOME` environment variable to the full path of the `vips-dev-x.y.z` directory. +3. Add `vips-dev-x.y.z\bin` to `PATH`. + ### Heroku [Alessandro Tagliapietra](https://github.com/alex88) maintains an [Heroku buildpack for libvips](https://github.com/alex88/heroku-buildpack-vips) and its dependencies. diff --git a/binding.gyp b/binding.gyp index 207d1fb9..0764838c 100755 --- a/binding.gyp +++ b/binding.gyp @@ -8,15 +8,50 @@ 'src/resize.cc', 'src/sharp.cc' ], - 'variables': { - 'PKG_CONFIG_PATH': '/dev/null 2>&1 && eval $(brew --env) && echo $PKG_CONFIG_LIBDIR || true):$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig:/usr/lib/pkgconfig' - }, - 'libraries': [ - '/dev/null 2>&1 && eval $(brew --env) && echo $PKG_CONFIG_LIBDIR || true):$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig:/usr/lib/pkgconfig' + }, + 'libraries': [ + '