all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#55253: nginx-rtmp-module not compatible with nginx
@ 2022-05-04  4:19 Jack Hill
  2022-05-17  5:32 ` Jack Hill
  2022-05-22  5:50 ` [bug#55253] [PATCH 0/2] nginx-rtmp-module use nginx's #:configure-flags and update to gexps in phases Jack Hill
  0 siblings, 2 replies; 12+ messages in thread
From: Jack Hill @ 2022-05-04  4:19 UTC (permalink / raw)
  To: 55253; +Cc: mail

X-Debbugs-CC: mail@cbaines.net

Hi Guix,

nginx currently (Guix commit b80ca672de936a76368de6e6ea0b28505e74d420) 
fails to load the nginx-rtmp-module build from the same Guix commit with 
the following message:

[emerg] 3823#0: module "/gnu/store/qnk6k7wa25w0bk5v8fb6iv524imlm58s-nginx-rtmp-module-1.2.2/etc/nginx/modules/ngx_rtmp_module.so" is not binary compatible in /gnu/store/mz0bck7ha0iqgi1bv4k14b36ycs3bz6k-nginx.conf:1

I wonder if this problem was introduced with the recent nginx changes 
(e.g. a14c6352662bfa6715ec70b3d280a6d1d599ad0c)

Best,
Jack




^ permalink raw reply	[flat|nested] 12+ messages in thread

* bug#55253: nginx-rtmp-module not compatible with nginx
  2022-05-04  4:19 bug#55253: nginx-rtmp-module not compatible with nginx Jack Hill
@ 2022-05-17  5:32 ` Jack Hill
  2022-05-22  5:50 ` [bug#55253] [PATCH 0/2] nginx-rtmp-module use nginx's #:configure-flags and update to gexps in phases Jack Hill
  1 sibling, 0 replies; 12+ messages in thread
From: Jack Hill @ 2022-05-17  5:32 UTC (permalink / raw)
  To: 55253; +Cc: Marius Bakke

On Wed, 4 May 2022, Jack Hill wrote:

> X-Debbugs-CC: mail@cbaines.net
>
> Hi Guix,
>
> nginx currently (Guix commit b80ca672de936a76368de6e6ea0b28505e74d420) fails 
> to load the nginx-rtmp-module build from the same Guix commit with the 
> following message:
>
> [emerg] 3823#0: module 
> "/gnu/store/qnk6k7wa25w0bk5v8fb6iv524imlm58s-nginx-rtmp-module-1.2.2/etc/nginx/modules/ngx_rtmp_module.so" 
> is not binary compatible in 
> /gnu/store/mz0bck7ha0iqgi1bv4k14b36ycs3bz6k-nginx.conf:1
>
> I wonder if this problem was introduced with the recent nginx changes (e.g. 
> a14c6352662bfa6715ec70b3d280a6d1d599ad0c)
>
> Best,
> Jack

The problem seems to actually have been introduced with 
c9ce02ecff769449bb79f9f0db33c69e2c7564f0 "nginx: Respect 
#:configure-flags". I suspect that now that the #:configure-flags are 
being respected they've gotten out of sync with nginx-rtmp-module (which 
probably only worked by change before). The likely solution is to find a 
way to re-use the #:configure-flags from the nginx package.

Best,
Jack




^ permalink raw reply	[flat|nested] 12+ messages in thread

* [bug#55253] [PATCH 0/2] nginx-rtmp-module use nginx's #:configure-flags and update to gexps in phases
  2022-05-04  4:19 bug#55253: nginx-rtmp-module not compatible with nginx Jack Hill
  2022-05-17  5:32 ` Jack Hill
@ 2022-05-22  5:50 ` Jack Hill
  2022-05-22  5:51   ` [bug#55253] [PATCH 1/2] gnu: nginx-rtmp-module: Use #:configure-flags from nginx Jack Hill
  1 sibling, 1 reply; 12+ messages in thread
From: Jack Hill @ 2022-05-22  5:50 UTC (permalink / raw)
  To: 55253

These patches buils the nginx-rtmp-module with the same #:configure-flags 
as the nginx package, which fixes the incompatible module problem, and 
update the #:phases to use gexps instead of `assoc-ref`

Jack Hill (2):
   gnu: nginx-rtmp-module: Use #:configure-flags from nginx.
   gnu: nginx-rtmp-module: Use gexps in phases.

  gnu/packages/web.scm | 23 +++++++++--------------
  1 file changed, 9 insertions(+), 14 deletions(-)

-- 
2.36.1





^ permalink raw reply	[flat|nested] 12+ messages in thread

* [bug#55253] [PATCH 1/2] gnu: nginx-rtmp-module: Use #:configure-flags from nginx.
  2022-05-22  5:50 ` [bug#55253] [PATCH 0/2] nginx-rtmp-module use nginx's #:configure-flags and update to gexps in phases Jack Hill
@ 2022-05-22  5:51   ` Jack Hill
  2022-05-22  5:51     ` [bug#55253] [PATCH 2/2] gnu: nginx-rtmp-module: Use gexps in phases Jack Hill
  2022-05-23 12:57     ` [bug#55253] nginx-rtmp-module not compatible with nginx Ludovic Courtès
  0 siblings, 2 replies; 12+ messages in thread
From: Jack Hill @ 2022-05-22  5:51 UTC (permalink / raw)
  To: 55253

* gnu/packages/web.scm (nginx-rtmp-module)[arguments]: Simplify copying
of arguments from nginx and augment #:configure-flags from nginx
rather than overwriting.
---
 gnu/packages/web.scm | 9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)

diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index 600ef0c895..50401c07e1 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -785,12 +785,9 @@ (define-public nginx-rtmp-module
      `(("nginx-sources" ,(package-source nginx))
        ,@(package-inputs nginx)))
     (arguments
-     (substitute-keyword-arguments
-         `(#:make-flags '("modules")
-           #:modules ((guix build utils)
-                      (guix build gnu-build-system))
-           ,@(package-arguments nginx)
-           #:configure-flags '("--add-dynamic-module=."))
+     (substitute-keyword-arguments (package-arguments nginx)
+       ((#:configure-flags flags)
+        #~(cons "--add-dynamic-module=." #$flags))
        ((#:phases phases)
         #~(modify-phases #$phases
             (add-after 'unpack 'unpack-nginx-sources
-- 
2.36.1





^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [bug#55253] [PATCH 2/2] gnu: nginx-rtmp-module: Use gexps in phases.
  2022-05-22  5:51   ` [bug#55253] [PATCH 1/2] gnu: nginx-rtmp-module: Use #:configure-flags from nginx Jack Hill
@ 2022-05-22  5:51     ` Jack Hill
  2022-05-23 12:57     ` [bug#55253] nginx-rtmp-module not compatible with nginx Ludovic Courtès
  1 sibling, 0 replies; 12+ messages in thread
From: Jack Hill @ 2022-05-22  5:51 UTC (permalink / raw)
  To: 55253

* gnu/packages/web.scm (nginx-rtmp-module)[#:phases]: Use gexps and
remove trailing #t.
---
 gnu/packages/web.scm | 14 ++++++--------
 1 file changed, 6 insertions(+), 8 deletions(-)

diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index 50401c07e1..c93af29a93 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -791,24 +791,22 @@ (define-public nginx-rtmp-module
        ((#:phases phases)
         #~(modify-phases #$phases
             (add-after 'unpack 'unpack-nginx-sources
-              (lambda* (#:key inputs native-inputs #:allow-other-keys)
+              (lambda _
                 (begin
                   ;; The nginx source code is part of the module’s source.
                   (format #t "decompressing nginx source code~%")
-                  (invoke "tar" "xvf" (assoc-ref inputs "nginx-sources")
+                  (invoke "tar" "xvf" #$(this-package-input "nginx-sources")
                           ;; This package's LICENSE file would be
                           ;; overwritten with the one from nginx when
                           ;; unpacking the nginx source, so rename the nginx
                           ;; one when unpacking.
                           "--transform=s,/LICENSE$,/LICENSE.nginx,"
-                          "--strip-components=1")
-                  #t)))
+                          "--strip-components=1"))))
             (replace 'install
-              (lambda* (#:key outputs #:allow-other-keys)
-                (let ((modules-dir (string-append (assoc-ref outputs "out")
+              (lambda _
+                (let ((modules-dir (string-append #$output
                                                   "/etc/nginx/modules")))
-                  (install-file "objs/ngx_rtmp_module.so" modules-dir)
-                  #t)))
+                  (install-file "objs/ngx_rtmp_module.so" modules-dir))))
             (delete 'fix-root-dirs)
             (delete 'install-man-page)))))
     (home-page "https://github.com/arut/nginx-rtmp-module")
-- 
2.36.1





^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [bug#55253] nginx-rtmp-module not compatible with nginx
  2022-05-22  5:51   ` [bug#55253] [PATCH 1/2] gnu: nginx-rtmp-module: Use #:configure-flags from nginx Jack Hill
  2022-05-22  5:51     ` [bug#55253] [PATCH 2/2] gnu: nginx-rtmp-module: Use gexps in phases Jack Hill
@ 2022-05-23 12:57     ` Ludovic Courtès
  2022-05-23 14:11       ` Jack Hill
  1 sibling, 1 reply; 12+ messages in thread
From: Ludovic Courtès @ 2022-05-23 12:57 UTC (permalink / raw)
  To: Jack Hill; +Cc: 55253

Hi Jack,

Jack Hill <jackhill@jackhill.us> skribis:

> * gnu/packages/web.scm (nginx-rtmp-module)[arguments]: Simplify copying
> of arguments from nginx and augment #:configure-flags from nginx
> rather than overwriting.
> ---
>  gnu/packages/web.scm | 9 +++------
>  1 file changed, 3 insertions(+), 6 deletions(-)
>
> diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
> index 600ef0c895..50401c07e1 100644
> --- a/gnu/packages/web.scm
> +++ b/gnu/packages/web.scm
> @@ -785,12 +785,9 @@ (define-public nginx-rtmp-module
>       `(("nginx-sources" ,(package-source nginx))
>         ,@(package-inputs nginx)))
>      (arguments
> -     (substitute-keyword-arguments
> -         `(#:make-flags '("modules")
> -           #:modules ((guix build utils)
> -                      (guix build gnu-build-system))
> -           ,@(package-arguments nginx)
> -           #:configure-flags '("--add-dynamic-module=."))
> +     (substitute-keyword-arguments (package-arguments nginx)
> +       ((#:configure-flags flags)
> +        #~(cons "--add-dynamic-module=." #$flags))

If I’m not mistaken, #:make-flags and #:modules are lost here, no?
Or were they unnecessary in the first place?

Thanks,
Ludo’.




^ permalink raw reply	[flat|nested] 12+ messages in thread

* [bug#55253] nginx-rtmp-module not compatible with nginx
  2022-05-23 12:57     ` [bug#55253] nginx-rtmp-module not compatible with nginx Ludovic Courtès
@ 2022-05-23 14:11       ` Jack Hill
  2022-05-27  2:02         ` Jack Hill
  0 siblings, 1 reply; 12+ messages in thread
From: Jack Hill @ 2022-05-23 14:11 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: 55253

[-- Attachment #1: Type: text/plain, Size: 1136 bytes --]

On Mon, 23 May 2022, Ludovic Courtès wrote:

> Jack Hill <jackhill@jackhill.us> skribis:
>>
>> diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
>> index 600ef0c895..50401c07e1 100644
>> --- a/gnu/packages/web.scm
>> +++ b/gnu/packages/web.scm
>> @@ -785,12 +785,9 @@ (define-public nginx-rtmp-module
>>       `(("nginx-sources" ,(package-source nginx))
>>         ,@(package-inputs nginx)))
>>      (arguments
>> -     (substitute-keyword-arguments
>> -         `(#:make-flags '("modules")
>> -           #:modules ((guix build utils)
>> -                      (guix build gnu-build-system))
>> -           ,@(package-arguments nginx)
>> -           #:configure-flags '("--add-dynamic-module=."))
>> +     (substitute-keyword-arguments (package-arguments nginx)
>> +       ((#:configure-flags flags)
>> +        #~(cons "--add-dynamic-module=." #$flags))
>
> If I’m not mistaken, #:make-flags and #:modules are lost here, no?
> Or were they unnecessary in the first place?

You are not mistaken, they are lost. They do seem to be unnecessary 
though. nginx is able to load and make use of the module without them.

Best,
Jack

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [bug#55253] nginx-rtmp-module not compatible with nginx
  2022-05-23 14:11       ` Jack Hill
@ 2022-05-27  2:02         ` Jack Hill
  2022-05-27  2:04           ` [bug#55253] [PATCH v2 1/2] gnu: nginx-rtmp-module: Use #:configure-flags from nginx Jack Hill
  0 siblings, 1 reply; 12+ messages in thread
From: Jack Hill @ 2022-05-27  2:02 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: 55253

[-- Attachment #1: Type: text/plain, Size: 1441 bytes --]

On Mon, 23 May 2022, Jack Hill wrote:

> On Mon, 23 May 2022, Ludovic Courtès wrote:
>
>> Jack Hill <jackhill@jackhill.us> skribis:
>>> 
>>> diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
>>> index 600ef0c895..50401c07e1 100644
>>> --- a/gnu/packages/web.scm
>>> +++ b/gnu/packages/web.scm
>>> @@ -785,12 +785,9 @@ (define-public nginx-rtmp-module
>>>       `(("nginx-sources" ,(package-source nginx))
>>>         ,@(package-inputs nginx)))
>>>      (arguments
>>> -     (substitute-keyword-arguments
>>> -         `(#:make-flags '("modules")
>>> -           #:modules ((guix build utils)
>>> -                      (guix build gnu-build-system))
>>> -           ,@(package-arguments nginx)
>>> -           #:configure-flags '("--add-dynamic-module=."))
>>> +     (substitute-keyword-arguments (package-arguments nginx)
>>> +       ((#:configure-flags flags)
>>> +        #~(cons "--add-dynamic-module=." #$flags))
>> 
>> If I’m not mistaken, #:make-flags and #:modules are lost here, no?
>> Or were they unnecessary in the first place?
>
> You are not mistaken, they are lost. They do seem to be unnecessary though. 
> nginx is able to load and make use of the module without them.

I realized the value of the make-flags. It saves effort when building, as 
only the module is build not all of nginx again. The output is identical. 
I'll send a v2 with those added back. I still don't see the value of the 
modules.

Best,
Jack

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [bug#55253] [PATCH v2 1/2] gnu: nginx-rtmp-module: Use #:configure-flags from nginx.
  2022-05-27  2:02         ` Jack Hill
@ 2022-05-27  2:04           ` Jack Hill
  2022-05-27  2:04             ` [bug#55253] [PATCH v2 2/2] gnu: nginx-rtmp-module: Use gexps in phases Jack Hill
  0 siblings, 1 reply; 12+ messages in thread
From: Jack Hill @ 2022-05-27  2:04 UTC (permalink / raw)
  To: 55253

* gnu/packages/web.scm (nginx-rtmp-module)[arguments]: Simplify copying
of arguments from nginx and augment #:configure-flags from nginx
rather than overwriting.
---
 gnu/packages/web.scm | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index ffcb709e82..e349a863d5 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -793,11 +793,10 @@ (define-public nginx-rtmp-module
        ,@(package-inputs nginx)))
     (arguments
      (substitute-keyword-arguments
-         `(#:make-flags '("modules")
-           #:modules ((guix build utils)
-                      (guix build gnu-build-system))
-           ,@(package-arguments nginx)
-           #:configure-flags '("--add-dynamic-module=."))
+         `(#:make-flags '("modules") ;Only build this module not all of nginx.
+           ,@(package-arguments nginx))
+       ((#:configure-flags flags)
+        #~(cons "--add-dynamic-module=." #$flags))
        ((#:phases phases)
         #~(modify-phases #$phases
             (add-after 'unpack 'unpack-nginx-sources
-- 
2.36.1





^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [bug#55253] [PATCH v2 2/2] gnu: nginx-rtmp-module: Use gexps in phases.
  2022-05-27  2:04           ` [bug#55253] [PATCH v2 1/2] gnu: nginx-rtmp-module: Use #:configure-flags from nginx Jack Hill
@ 2022-05-27  2:04             ` Jack Hill
  2022-05-27 13:01               ` Christopher Baines
  0 siblings, 1 reply; 12+ messages in thread
From: Jack Hill @ 2022-05-27  2:04 UTC (permalink / raw)
  To: 55253

* gnu/packages/web.scm (nginx-rtmp-module)[#:phases]: Use gexps and
remove trailing #t.
---
 gnu/packages/web.scm | 14 ++++++--------
 1 file changed, 6 insertions(+), 8 deletions(-)

diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index e349a863d5..d321348eed 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -800,24 +800,22 @@ (define-public nginx-rtmp-module
        ((#:phases phases)
         #~(modify-phases #$phases
             (add-after 'unpack 'unpack-nginx-sources
-              (lambda* (#:key inputs native-inputs #:allow-other-keys)
+              (lambda _
                 (begin
                   ;; The nginx source code is part of the module’s source.
                   (format #t "decompressing nginx source code~%")
-                  (invoke "tar" "xvf" (assoc-ref inputs "nginx-sources")
+                  (invoke "tar" "xvf" #$(this-package-input "nginx-sources")
                           ;; This package's LICENSE file would be
                           ;; overwritten with the one from nginx when
                           ;; unpacking the nginx source, so rename the nginx
                           ;; one when unpacking.
                           "--transform=s,/LICENSE$,/LICENSE.nginx,"
-                          "--strip-components=1")
-                  #t)))
+                          "--strip-components=1"))))
             (replace 'install
-              (lambda* (#:key outputs #:allow-other-keys)
-                (let ((modules-dir (string-append (assoc-ref outputs "out")
+              (lambda _
+                (let ((modules-dir (string-append #$output
                                                   "/etc/nginx/modules")))
-                  (install-file "objs/ngx_rtmp_module.so" modules-dir)
-                  #t)))
+                  (install-file "objs/ngx_rtmp_module.so" modules-dir))))
             (delete 'fix-root-dirs)
             (delete 'install-man-page)))))
     (home-page "https://github.com/arut/nginx-rtmp-module")
-- 
2.36.1





^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [bug#55253] [PATCH v2 2/2] gnu: nginx-rtmp-module: Use gexps in phases.
  2022-05-27  2:04             ` [bug#55253] [PATCH v2 2/2] gnu: nginx-rtmp-module: Use gexps in phases Jack Hill
@ 2022-05-27 13:01               ` Christopher Baines
  2022-05-27 21:47                 ` bug#55253: " Jack Hill
  0 siblings, 1 reply; 12+ messages in thread
From: Christopher Baines @ 2022-05-27 13:01 UTC (permalink / raw)
  To: Jack Hill; +Cc: 55253

[-- Attachment #1: Type: text/plain, Size: 141 bytes --]


I've pushed these two patches as
0e953f3332cc862b08ecb2342bdac9976dd6d08c and
0e953f3332cc862b08ecb2342bdac9976dd6d08c now.

Thanks,

Chris

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 987 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* bug#55253: [PATCH v2 2/2] gnu: nginx-rtmp-module: Use gexps in phases.
  2022-05-27 13:01               ` Christopher Baines
@ 2022-05-27 21:47                 ` Jack Hill
  0 siblings, 0 replies; 12+ messages in thread
From: Jack Hill @ 2022-05-27 21:47 UTC (permalink / raw)
  To: Christopher Baines; +Cc: 55253-done

On Fri, 27 May 2022, Christopher Baines wrote:

> I've pushed these two patches as
> 0e953f3332cc862b08ecb2342bdac9976dd6d08c and
> 0e953f3332cc862b08ecb2342bdac9976dd6d08c now.
>
> Thanks,
>
> Chris

Thanks, and closing!
Jack




^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2022-05-27 21:48 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-04  4:19 bug#55253: nginx-rtmp-module not compatible with nginx Jack Hill
2022-05-17  5:32 ` Jack Hill
2022-05-22  5:50 ` [bug#55253] [PATCH 0/2] nginx-rtmp-module use nginx's #:configure-flags and update to gexps in phases Jack Hill
2022-05-22  5:51   ` [bug#55253] [PATCH 1/2] gnu: nginx-rtmp-module: Use #:configure-flags from nginx Jack Hill
2022-05-22  5:51     ` [bug#55253] [PATCH 2/2] gnu: nginx-rtmp-module: Use gexps in phases Jack Hill
2022-05-23 12:57     ` [bug#55253] nginx-rtmp-module not compatible with nginx Ludovic Courtès
2022-05-23 14:11       ` Jack Hill
2022-05-27  2:02         ` Jack Hill
2022-05-27  2:04           ` [bug#55253] [PATCH v2 1/2] gnu: nginx-rtmp-module: Use #:configure-flags from nginx Jack Hill
2022-05-27  2:04             ` [bug#55253] [PATCH v2 2/2] gnu: nginx-rtmp-module: Use gexps in phases Jack Hill
2022-05-27 13:01               ` Christopher Baines
2022-05-27 21:47                 ` bug#55253: " Jack Hill

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.