From 9894beb5c1864d3aa5c6e351a0051a08b8ae80ef Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Fri, 25 Aug 2017 08:50:14 +0200 Subject: minor --- ImageMagick7.spec | 26 +++++++++++++++++--------- 1 file changed, 17 insertions(+), 9 deletions(-) (limited to 'ImageMagick7.spec') diff --git a/ImageMagick7.spec b/ImageMagick7.spec index 16fc8b7..5ea09ee 100644 --- a/ImageMagick7.spec +++ b/ImageMagick7.spec @@ -50,13 +50,8 @@ %global with_gvc 1 -%ifarch x86_64 -%{!?__isa_bits: %global __isa_bits 64} -%else -%{!?__isa_bits: %global __isa_bits 32} -%endif - %global libname ImageMagick + # No need to relocate for now, as ImageMagick-7 is not ImageMagick-6 %global move 0 @@ -449,12 +444,25 @@ make %{?_smp_mflags} check %endif -%post -p /sbin/ldconfig +%pre libs +LIB=%{_libdir}/%{libname}-%{VER} +%if %{move} +ETC=%{_sysconfdir}/%{name} +%else +ETC=%{_sysconfdir}/%{libname}%{?incsuffixe} +%endif +if [ -d $ETC -a ! -d $LIB ]; then cat << EOF -%post c++ -p /sbin/ldconfig +WARNING : %{name} modules directory have changed. +You need to restart some services to take care of +the new location (e.g. httpd, php-fpm). -%postun -p /sbin/ldconfig +EOF +fi +%post -p /sbin/ldconfig +%post c++ -p /sbin/ldconfig +%postun -p /sbin/ldconfig %postun c++ -p /sbin/ldconfig -- cgit