[bug#33549,5/6] gnu: Add php-with-bcmath.

Message ID 20181129185042.6050-5-go.wigust@gmail.com
State Accepted
Headers show
Series Add Zabbix services. | expand

Checks

Context Check Description
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied

Commit Message

Oleg Pykhalov Nov. 29, 2018, 6:50 p.m. UTC
* gnu/packages/php.scm (php-with-bcmath): New variable.
---
 gnu/packages/php.scm | 10 ++++++++++
 1 file changed, 10 insertions(+)

Comments

Ludovic Courtès Dec. 19, 2018, 3:20 p.m. UTC | #1
Hi Oleg,

Sorry for the late reply!

Oleg Pykhalov <go.wigust@gmail.com> skribis:

> * gnu/packages/php.scm (php-with-bcmath): New variable.

[...]

> +(define-public php-with-bcmath
> +  (package
> +    (inherit php)
> +    (name "php-with-bcmath")
> +    (arguments
> +     (substitute-keyword-arguments (package-arguments php)
> +       ((#:configure-flags flags)
> +        `(cons "--enable-bcmath" ,flags))))))

Any reason not to make it the default ‘php’ package?

Ludo’.

Patch

diff --git a/gnu/packages/php.scm b/gnu/packages/php.scm
index a22591d377..07246b0833 100644
--- a/gnu/packages/php.scm
+++ b/gnu/packages/php.scm
@@ -48,6 +48,7 @@ 
   #:use-module (guix packages)
   #:use-module (guix download)
   #:use-module (guix build-system gnu)
+  #:use-module (guix utils)
   #:use-module ((guix licenses) #:prefix license:))
 
 (define gd-for-php
@@ -360,3 +361,12 @@  systems, web content management systems and web frameworks." )
               license:lgpl2.1+                              ; ext/bcmath/libbcmath
               license:bsd-2                                 ; ext/fileinfo/libmagic
               license:expat))))                             ; ext/date/lib
+
+(define-public php-with-bcmath
+  (package
+    (inherit php)
+    (name "php-with-bcmath")
+    (arguments
+     (substitute-keyword-arguments (package-arguments php)
+       ((#:configure-flags flags)
+        `(cons "--enable-bcmath" ,flags))))))