From 07d66da57b7829fca938d7e3c5c4b47a981b1d17 Mon Sep 17 00:00:00 2001 From: Lovell Fuller Date: Wed, 28 Sep 2016 21:40:30 +0100 Subject: [PATCH] Auto-detect C++11 ABI version, remove --sharp-cxx11 flag --- binding.gyp | 15 ++++++++++----- docs/changelog.md | 2 ++ docs/install.md | 19 +++++-------------- 3 files changed, 17 insertions(+), 19 deletions(-) diff --git a/binding.gyp b/binding.gyp index e96cc5b1..bc7e8e74 100644 --- a/binding.gyp +++ b/binding.gyp @@ -51,7 +51,6 @@ ], # Nested variables "pattern" borrowed from http://src.chromium.org/viewvc/chrome/trunk/src/build/common.gypi 'variables': { - 'sharp_cxx11%': '0', 'variables': { 'variables': { 'conditions': [ @@ -92,10 +91,6 @@ 'src/sharp.cc', 'src/utilities.cc' ], - 'defines': [ - '_GLIBCXX_USE_CXX11_ABI=<(sharp_cxx11)', - '_ALLOW_KEYWORD_MACROS' - ], 'include_dirs': [ '&1 || true)" node -e "require(\'./binding\').download_vips()")' }, + 'defines': [ + '_GLIBCXX_USE_CXX11_ABI=0' + ], 'libraries': [ '../lib/libvips-cpp.so', '../lib/libvips.so', diff --git a/docs/changelog.md b/docs/changelog.md index 2e709b2e..abe4f078 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -6,6 +6,8 @@ Requires libvips v8.3.3 #### v0.16.1 - TBD +* C++11 ABI version is now auto-detected, remove sharp-cxx11 installation flag. + * Ensure convolution kernel scale is clamped to a minimum value of 1. [#561](https://github.com/lovell/sharp/issues/561) [@abagshaw](https://github.com/abagshaw) diff --git a/docs/install.md b/docs/install.md index 1b1f3002..7b7947fc 100644 --- a/docs/install.md +++ b/docs/install.md @@ -22,24 +22,15 @@ Most recent Linux-based operating systems with glibc running on x64 and ARMv6+ C * Debian 7, 8 * Ubuntu 12.04, 14.04, 16.04 * Centos 7 -* Fedora 22, 23 +* Fedora 23, 24 * openSUSE 13.2 * Archlinux * Raspbian Jessie -* Amazon Linux 2016.03 +* Amazon Linux 2016.03, 2016.09 -To use your own version of libvips instead of the provided binaries, make sure it is -at least the version listed under `config.libvips` in the `package.json` file and -that it can be located using `pkg-config --modversion vips-cpp`. - -There are [changes in the C++11 ABI](https://gcc.gnu.org/onlinedocs/libstdc++/manual/using_dual_abi.html) -when using v5.1+ of the `g++` compiler. -If you have installed `libvips-dev` via package manager on an OS such as Debian testing/unstable, -you can pass the required value of the `_GLIBCXX_USE_CXX11_ABI` macro using the `--sharp-cxx11` flag. - -```sh -npm install --sharp-cxx11=1 -``` +To use a globally-installed version of libvips instead of the provided binaries, +make sure it is at least the version listed under `config.libvips` in the `package.json` file +and that it can be located using `pkg-config --modversion vips-cpp`. If you are using non-stadard paths (anything other than `/usr` or `/usr/local`), you might need to set `PKG_CONFIG_PATH` during `npm install`