From c7f7fc52e828cd62fd8a470e2e76a625908f172f Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Tue, 15 Jun 2021 15:17:35 +0200 Subject: [PATCH 1/3] use /lib64 instead of /lib when needed --- libvips/iofuncs/init.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libvips/iofuncs/init.c b/libvips/iofuncs/init.c index 815c64c5..25ac27e2 100644 --- a/libvips/iofuncs/init.c +++ b/libvips/iofuncs/init.c @@ -1215,6 +1215,8 @@ vips_guess_libdir( const char *argv0, const char *env_name ) */ if( strcmp( prefix, VIPS_PREFIX ) == 0 ) libdir = VIPS_LIBDIR; + else if ( strstr(VIPS_LIBDIR, "/lib64") ) + libdir = g_strdup_printf( "%s/lib64", prefix ); else libdir = g_strdup_printf( "%s/lib", prefix ); From ad40d881dd30afb93d9ec8e124de8353fb1c51ae Mon Sep 17 00:00:00 2001 From: John Cupitt Date: Tue, 29 Jun 2021 17:41:08 +0100 Subject: [PATCH 2/3] remi's libdir patch, plus version bump to 8.11.2 --- ChangeLog | 3 +++ configure.ac | 6 +++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index eb54d284..8ea20633 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,6 @@ +14/8/20 started 8.11.2 +- better libdir guessing [remi] + 14/8/20 started 8.11.1 - add more example code to C docs - update libtool support in configure.ac diff --git a/configure.ac b/configure.ac index 42672880..aef42048 100644 --- a/configure.ac +++ b/configure.ac @@ -2,7 +2,7 @@ # also update the version number in the m4 macros below -AC_INIT([vips],[8.11.1],[vipsip@jiscmail.ac.uk]) +AC_INIT([vips],[8.11.2],[vipsip@jiscmail.ac.uk]) # required for gobject-introspection AC_PREREQ([2.69]) @@ -18,7 +18,7 @@ AC_CONFIG_MACRO_DIR([m4]) # user-visible library versioning m4_define([vips_major_version], [8]) m4_define([vips_minor_version], [11]) -m4_define([vips_micro_version], [1]) +m4_define([vips_micro_version], [2]) m4_define([vips_version], [vips_major_version.vips_minor_version.vips_micro_version]) @@ -43,7 +43,7 @@ VIPS_LIBS="" # binary interface changes not backwards compatible?: reset age to 0 LIBRARY_CURRENT=55 -LIBRARY_REVISION=0 +LIBRARY_REVISION=1 LIBRARY_AGE=13 # patched into include/vips/version.h From d07dee8b0c07978fc9da8bcf3cef8de4c50a4146 Mon Sep 17 00:00:00 2001 From: John Cupitt Date: Fri, 2 Jul 2021 11:50:34 +0100 Subject: [PATCH 3/3] better libdir guessing take the lib directory name (eg. "lib64" etc.) from the configure time libdir --- libvips/iofuncs/init.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/libvips/iofuncs/init.c b/libvips/iofuncs/init.c index 25ac27e2..34b705e8 100644 --- a/libvips/iofuncs/init.c +++ b/libvips/iofuncs/init.c @@ -1205,18 +1205,23 @@ const char * vips_guess_libdir( const char *argv0, const char *env_name ) { const char *prefix = vips_guess_prefix( argv0, env_name ); - static char *libdir = NULL; + static char *libdir = NULL; + + char *suffix; if( libdir ) return( libdir ); /* Have we been moved since configure? If not, use the configure-time - * libdir. + * libdir. + * + * The lib directory name can be eg. "lib", "lib64" etc. depending on + * the platform, so copy that from the configure-time libdir if we can. */ if( strcmp( prefix, VIPS_PREFIX ) == 0 ) libdir = VIPS_LIBDIR; - else if ( strstr(VIPS_LIBDIR, "/lib64") ) - libdir = g_strdup_printf( "%s/lib64", prefix ); + else if( (suffix = strrchr( VIPS_LIBDIR, G_DIR_SEPARATOR )) ) + libdir = g_strdup_printf( "%s%s", prefix, suffix ); else libdir = g_strdup_printf( "%s/lib", prefix );