From 45d6687a60955f9784b5ac4d56e9a7a1b8813900 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Elan=20Ruusam=C3=A4e?= Date: Tue, 4 Oct 2016 15:38:32 +0300 Subject: [PATCH] setup timezone in %posttrans, not %post this ensures that php.ini timezone is actually set if php and tzdata pacakge are installed in same transaction --- php.spec | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/php.spec b/php.spec index 0fa1988..67adacc 100644 --- a/php.spec +++ b/php.spec @@ -124,7 +124,7 @@ ERROR: You need to select at least one Apache SAPI to build shared modules. %undefine with_filter %endif -%define rel 9 +%define rel 10 %define orgname php %define ver_suffix 54 %define php_suffix %{!?with_default_php:%{ver_suffix}} @@ -2606,7 +2606,7 @@ fi %post embedded -p /sbin/ldconfig %postun embedded -p /sbin/ldconfig -%post common +%posttrans common # PHP 5.3 requires timezone being setup, try setup it from tzdata if ! grep -q '^date.timezone[[:space:]]*=' %{_sysconfdir}/php.ini && [ -f /etc/sysconfig/timezone ]; then TIMEZONE= @@ -2616,7 +2616,6 @@ if ! grep -q '^date.timezone[[:space:]]*=' %{_sysconfdir}/php.ini && [ -f /etc/s fi fi -%posttrans common # minimizing apache restarts logics. we restart webserver: # # 1. at the end of transaction. (posttrans, feature from rpm 4.4.2) -- 2.43.0