* [bug#37912] [PATCH] gnu: elixir: Update to 1.9.2.
@ 2019-10-24 20:45 Oskar Köök
2019-10-25 12:16 ` Mathieu Othacehe
` (2 more replies)
0 siblings, 3 replies; 10+ messages in thread
From: Oskar Köök @ 2019-10-24 20:45 UTC (permalink / raw)
To: 37912
[-- Attachment #1.1: Type: text/plain, Size: 1 bytes --]
[-- Attachment #1.2: Type: text/html, Size: 153 bytes --]
[-- Attachment #2: 0001-gnu-elixir-Update-to-1.9.2.patch --]
[-- Type: text/x-patch, Size: 1109 bytes --]
From bfbd16af6aaf3d2685f01fa8059a220485e830ec Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Oskar=20K=C3=B6=C3=B6k?= <oskarkook@maatriks.ee>
Date: Thu, 24 Oct 2019 23:37:38 +0300
Subject: [PATCH] gnu: elixir: Update to 1.9.2.
* gnu/packages/elixir.scm (elixir): Update to 1.9.2.
---
gnu/packages/elixir.scm | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/gnu/packages/elixir.scm b/gnu/packages/elixir.scm
index 88ada71aea..d3f30c624e 100644
--- a/gnu/packages/elixir.scm
+++ b/gnu/packages/elixir.scm
@@ -33,7 +33,7 @@
(define-public elixir
(package
(name "elixir")
- (version "1.8.2")
+ (version "1.9.2")
(source
(origin
(method git-fetch)
@@ -42,7 +42,7 @@
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
- (base32 "1n77cpcl2b773gmj3m9s24akvj9gph9byqbmj2pvlsmby4aqwckq"))
+ (base32 "19yn6nx6r627f5zbyc7ckgr96d6b45sgwx95n2gp2imqwqvpj8wc"))
(patches (search-patches "elixir-path-length.patch"))))
(build-system gnu-build-system)
(arguments
--
2.21.0
^ permalink raw reply related [flat|nested] 10+ messages in thread
* [bug#37912] [PATCH] gnu: elixir: Update to 1.9.2.
2019-10-24 20:45 [bug#37912] [PATCH] gnu: elixir: Update to 1.9.2 Oskar Köök
@ 2019-10-25 12:16 ` Mathieu Othacehe
2019-10-31 14:35 ` Oskar Köök
2019-11-01 14:09 ` Oskar Köök
2 siblings, 0 replies; 10+ messages in thread
From: Mathieu Othacehe @ 2019-10-25 12:16 UTC (permalink / raw)
To: 37912
Hello,
When building elixir with this patch, I have the following error:
--8<---------------cut here---------------start------------->8---
Finished in 363.7 seconds (2.5s on load, 361.1s on tests)
9 doctests, 625 tests, 6 failures
Randomized with seed 237287
make: *** [Makefile:113: test_mix] Error 1
Test suite failed, dumping logs.
command "make" "test" "PREFIX=/gnu/store/q95v9n7c0nhrkqmn1xhr785zqi4mp81k-elixir-1.9.2" failed with status 2
builder for `/gnu/store/clqdccpnxbz4wg4c37shsn59d1y4b9wq-elixir-1.9.2.drv' failed with exit code 1
build of /gnu/store/clqdccpnxbz4wg4c37shsn59d1y4b9wq-elixir-1.9.2.drv failed
View build log at '/var/log/guix/drvs/cl/qdccpnxbz4wg4c37shsn59d1y4b9wq-elixir-1.9.2.drv.bz2'.
guix build: error: build of `/gnu/store/clqdccpnxbz4wg4c37shsn59d1y4b9wq-elixir-1.9.2.drv' failed
--8<---------------cut here---------------end--------------->8---
any idea why?
Thanks,
Mathieu
^ permalink raw reply [flat|nested] 10+ messages in thread
* [bug#37912] [PATCH] gnu: elixir: Update to 1.9.2.
2019-10-24 20:45 [bug#37912] [PATCH] gnu: elixir: Update to 1.9.2 Oskar Köök
2019-10-25 12:16 ` Mathieu Othacehe
@ 2019-10-31 14:35 ` Oskar Köök
2019-10-31 22:54 ` Marius Bakke
2019-11-01 14:09 ` Oskar Köök
2 siblings, 1 reply; 10+ messages in thread
From: Oskar Köök @ 2019-10-31 14:35 UTC (permalink / raw)
To: 37912
[-- Attachment #1: Type: text/plain, Size: 575 bytes --]
Sorry, first time using Guix.
Some Elixir tests are failing, caused by a new feature. I have locally fixed most of the issues related to this (I can now manually run the Makefile in the generated Guix folder without any tests failing), but I am stuck on a part where the tests spawn binaries and wait for a certain file to be created in a certain location. This does not work during the Guix build.
I will examine further over the weekend. If I can not fix these tests, is it acceptable to disable them? I can verify that the behaviour being tested works manually.
Oskar
[-- Attachment #2: Type: text/html, Size: 1060 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* [bug#37912] [PATCH] gnu: elixir: Update to 1.9.2.
2019-10-31 14:35 ` Oskar Köök
@ 2019-10-31 22:54 ` Marius Bakke
2019-11-01 13:45 ` Oskar Köök
0 siblings, 1 reply; 10+ messages in thread
From: Marius Bakke @ 2019-10-31 22:54 UTC (permalink / raw)
To: Oskar Köök, 37912
[-- Attachment #1: Type: text/plain, Size: 854 bytes --]
Oskar Köök <oskar@maatriks.ee> writes:
> Sorry, first time using Guix.
>
> Some Elixir tests are failing, caused by a new feature. I have locally fixed most of the issues related to this (I can now manually run the Makefile in the generated Guix folder without any tests failing), but I am stuck on a part where the tests spawn binaries and wait for a certain file to be created in a certain location. This does not work during the Guix build.
Perhaps it requires a network connection? Or /bin/sh? Those are the
most common sources of things failing in the build container but not on
a "regular" system.
> I will examine further over the weekend. If I can not fix these tests, is it acceptable to disable them? I can verify that the behaviour being tested works manually.
We should find out why they are failing in either case. :-)
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* [bug#37912] [PATCH] gnu: elixir: Update to 1.9.2.
2019-10-31 22:54 ` Marius Bakke
@ 2019-11-01 13:45 ` Oskar Köök
2019-11-16 16:34 ` bug#37912: " Ludovic Courtès
0 siblings, 1 reply; 10+ messages in thread
From: Oskar Köök @ 2019-11-01 13:45 UTC (permalink / raw)
To: Marius Bakke; +Cc: 37912
[-- Attachment #1.1: Type: text/plain, Size: 1294 bytes --]
Thank you for your response!
You were right, /bin/sh was the issue. I did some grepping and found Elixir was generating files that depend on /bin/sh. I am now able to build Elixir 1.9.2 on Guix.
I am attaching the patch to this e-mail. Please format/fix the code as necessary, I am not too familiar with Guile and other Scheme/Lisp languages.
Oskar
Nov 1, 2019, 00:54 by mbakke@fastmail.com:
> Oskar Köök <oskar@maatriks.ee> writes:
>
>> Sorry, first time using Guix.
>>
>> Some Elixir tests are failing, caused by a new feature. I have locally fixed most of the issues related to this (I can now manually run the Makefile in the generated Guix folder without any tests failing), but I am stuck on a part where the tests spawn binaries and wait for a certain file to be created in a certain location. This does not work during the Guix build.
>>
>
> Perhaps it requires a network connection? Or /bin/sh? Those are the
> most common sources of things failing in the build container but not on
> a "regular" system.
>
>> I will examine further over the weekend. If I can not fix these tests, is it acceptable to disable them? I can verify that the behaviour being tested works manually.
>>
>
> We should find out why they are failing in either case. :-)
>
[-- Attachment #1.2: Type: text/html, Size: 2492 bytes --]
[-- Attachment #2: 0001-gnu-elixir-Update-to-1.9.2.patch --]
[-- Type: text/x-patch, Size: 2419 bytes --]
From f2eb88f567f93e578e3c2df76046fed4f45645f8 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Oskar=20K=C3=B6=C3=B6k?= <oskarkook@maatriks.ee>
Date: Thu, 24 Oct 2019 23:37:38 +0300
Subject: [PATCH] gnu: elixir: Update to 1.9.2.
* gnu/packages/elixir.scm (elixir): Update to 1.9.2.
---
gnu/packages/elixir.scm | 20 ++++++++++++++++----
1 file changed, 16 insertions(+), 4 deletions(-)
diff --git a/gnu/packages/elixir.scm b/gnu/packages/elixir.scm
index 88ada71aea..144a8cc4e7 100644
--- a/gnu/packages/elixir.scm
+++ b/gnu/packages/elixir.scm
@@ -33,7 +33,7 @@
(define-public elixir
(package
(name "elixir")
- (version "1.8.2")
+ (version "1.9.2")
(source
(origin
(method git-fetch)
@@ -42,7 +42,7 @@
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
- (base32 "1n77cpcl2b773gmj3m9s24akvj9gph9byqbmj2pvlsmby4aqwckq"))
+ (base32 "19yn6nx6r627f5zbyc7ckgr96d6b45sgwx95n2gp2imqwqvpj8wc"))
(patches (search-patches "elixir-path-length.patch"))))
(build-system gnu-build-system)
(arguments
@@ -63,9 +63,21 @@
"lib/mix/lib/mix/scm/git.ex")
(("(cmd\\(['\"])git" _ prefix)
(string-append prefix (which "git"))))
+ (substitute* '("lib/mix/lib/mix/release.ex"
+ "lib/mix/lib/mix/tasks/release.init.ex")
+ (("#!/bin/sh")
+ (string-append "#!" (which "sh"))))
(substitute* "bin/elixir"
- (("ERL_EXEC=\"erl\"")
- (string-append "ERL_EXEC=" (which "erl"))))
+ (("ERTS_BIN=")
+ (string-append
+ "ERTS_BIN="
+ ;; Elixir Releases will prepend to ERTS_BIN the path of a copy of erl.
+ ;; We detect if a release is being generated by checking the initial ERTS_BIN
+ ;; value: if it's empty, we are not in release mode and can point to the actual
+ ;; erl binary in Guix store.
+ "\nif [ -z \"$ERTS_BIN\" ]; then ERTS_BIN="
+ (string-drop-right (which "erl") 3)
+ "; fi")))
(substitute* "bin/mix"
(("#!/usr/bin/env elixir")
(string-append "#!" out "/bin/elixir"))))
--
2.21.0
^ permalink raw reply related [flat|nested] 10+ messages in thread
* [bug#37912] [PATCH] gnu: elixir: Update to 1.9.2.
2019-10-24 20:45 [bug#37912] [PATCH] gnu: elixir: Update to 1.9.2 Oskar Köök
2019-10-25 12:16 ` Mathieu Othacehe
2019-10-31 14:35 ` Oskar Köök
@ 2019-11-01 14:09 ` Oskar Köök
2019-11-03 16:52 ` Marius Bakke
2 siblings, 1 reply; 10+ messages in thread
From: Oskar Köök @ 2019-11-01 14:09 UTC (permalink / raw)
To: 37912
[-- Attachment #1: Type: text/plain, Size: 762 bytes --]
Although I must note that the end-result ends up ruining the whole point of Elixir Releases.
The point of an Elixir release is that you can package an application into a stand-alone item. It will copy elixir & erlang (etc) as well as your application into a single package, so you can run it without having elixir & erlang installed on your system.
I guess the single dependency here is /bin/sh: as long as it exists, you can run the application from any system.
If you were to generate a release with Guix, you would end up with scripts that depend on the Guix store. So you can not run the stand-alone without Guix.
What is the solution to this? I would personally prefer to keep the actual behaviour (if possible) and if needed, disable the tests.
Oskar
[-- Attachment #2: Type: text/html, Size: 1397 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* [bug#37912] [PATCH] gnu: elixir: Update to 1.9.2.
2019-11-01 14:09 ` Oskar Köök
@ 2019-11-03 16:52 ` Marius Bakke
0 siblings, 0 replies; 10+ messages in thread
From: Marius Bakke @ 2019-11-03 16:52 UTC (permalink / raw)
To: Oskar Köök, 37912
[-- Attachment #1: Type: text/plain, Size: 1039 bytes --]
Oskar Köök <oskar@maatriks.ee> writes:
> Although I must note that the end-result ends up ruining the whole point of Elixir Releases.
>
> The point of an Elixir release is that you can package an application into a stand-alone item. It will copy elixir & erlang (etc) as well as your application into a single package, so you can run it without having elixir & erlang installed on your system.
>
> I guess the single dependency here is /bin/sh: as long as it exists, you can run the application from any system.
>
> If you were to generate a release with Guix, you would end up with scripts that depend on the Guix store. So you can not run the stand-alone without Guix.
>
> What is the solution to this? I would personally prefer to keep the actual behaviour (if possible) and if needed, disable the tests.
The typical solution here is to reset the shebang after running the
tests. I know there are a couple of packages doing this, but can't
recall which at the moment.
Can you try that? Thanks for working on it!
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* bug#37912: [PATCH] gnu: elixir: Update to 1.9.2.
2019-11-01 13:45 ` Oskar Köök
@ 2019-11-16 16:34 ` Ludovic Courtès
2019-11-16 19:01 ` [bug#37912] " Oskar Köök
2019-11-17 18:29 ` Marius Bakke
0 siblings, 2 replies; 10+ messages in thread
From: Ludovic Courtès @ 2019-11-16 16:34 UTC (permalink / raw)
To: Oskar Köök; +Cc: Marius Bakke, 37912
Hi Oskar,
Oskar Köök <oskar@maatriks.ee> skribis:
>>From f2eb88f567f93e578e3c2df76046fed4f45645f8 Mon Sep 17 00:00:00 2001
> From: =?UTF-8?q?Oskar=20K=C3=B6=C3=B6k?= <oskarkook@maatriks.ee>
> Date: Thu, 24 Oct 2019 23:37:38 +0300
> Subject: [PATCH] gnu: elixir: Update to 1.9.2.
>
> * gnu/packages/elixir.scm (elixir): Update to 1.9.2.
Thanks for the updated patch! I believe this addresses the comments
that Marius made, and it builds fine for me, so I went ahead and applied
it.
Thank you!
Ludo’.
^ permalink raw reply [flat|nested] 10+ messages in thread
* [bug#37912] [PATCH] gnu: elixir: Update to 1.9.2.
2019-11-16 16:34 ` bug#37912: " Ludovic Courtès
@ 2019-11-16 19:01 ` Oskar Köök
2019-11-17 18:29 ` Marius Bakke
1 sibling, 0 replies; 10+ messages in thread
From: Oskar Köök @ 2019-11-16 19:01 UTC (permalink / raw)
To: 37912; +Cc: Marius Bakke
[-- Attachment #1: Type: text/plain, Size: 1873 bytes --]
Hi
Thanks. I went ahead and did some further reading on the constraints of Elixir Releases and in the end it seems the current behaviour is actually just fine.
The documentation itself notes that there is already effectively a dependency on package managers:
> In addition to matching the target triple, it is also important that thetarget has all of the system packages that your application will need atruntime. A common one is the need for OpenSSL when building an applicationthat uses :crypto or :ssl, which is dynamically linked to ERTS. The othercommon source for native dependencies like this comes from dependenciescontaining NIFs (natively-implemented functions) which may expect todynamically link to libraries they use.
> These system packages are typically managed using the system package manager,but if necessary, you can also bundle the compiled object files in the release,as long as they were compiled for the same target.
This means that if you're creating an Elixir Release with Elixir built in Guix, you should also have the needed Guix packages installed on your target. Optionally the user can create a script that modifies the release to be compatible with the target (e.g. replace /gnu/store/* references with /bin/*).
Oskar
Nov 16, 2019, 18:34 by ludo@gnu.org:
> Hi Oskar,
>
> Oskar Köök <oskar@maatriks.ee> skribis:
>
> >>From f2eb88f567f93e578e3c2df76046fed4f45645f8 Mon Sep 17 00:00:00 2001
>
>> From: =?UTF-8?q?Oskar=20K=C3=B6=C3=B6k?= <oskarkook@maatriks.ee>
>> Date: Thu, 24 Oct 2019 23:37:38 +0300
>> Subject: [PATCH] gnu: elixir: Update to 1.9.2.
>>
>> * gnu/packages/elixir.scm (elixir): Update to 1.9.2.
>>
>
> Thanks for the updated patch! I believe this addresses the comments
> that Marius made, and it builds fine for me, so I went ahead and applied
> it.
>
> Thank you!
>
> Ludo’.
>
[-- Attachment #2: Type: text/html, Size: 3463 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* [bug#37912] [PATCH] gnu: elixir: Update to 1.9.2.
2019-11-16 16:34 ` bug#37912: " Ludovic Courtès
2019-11-16 19:01 ` [bug#37912] " Oskar Köök
@ 2019-11-17 18:29 ` Marius Bakke
1 sibling, 0 replies; 10+ messages in thread
From: Marius Bakke @ 2019-11-17 18:29 UTC (permalink / raw)
To: Ludovic Courtès, Oskar Köök; +Cc: 37912
[-- Attachment #1: Type: text/plain, Size: 657 bytes --]
Ludovic Courtès <ludo@gnu.org> writes:
> Hi Oskar,
>
> Oskar Köök <oskar@maatriks.ee> skribis:
>
>>>From f2eb88f567f93e578e3c2df76046fed4f45645f8 Mon Sep 17 00:00:00 2001
>> From: =?UTF-8?q?Oskar=20K=C3=B6=C3=B6k?= <oskarkook@maatriks.ee>
>> Date: Thu, 24 Oct 2019 23:37:38 +0300
>> Subject: [PATCH] gnu: elixir: Update to 1.9.2.
>>
>> * gnu/packages/elixir.scm (elixir): Update to 1.9.2.
>
> Thanks for the updated patch! I believe this addresses the comments
> that Marius made, and it builds fine for me, so I went ahead and applied
> it.
>
> Thank you!
Whoops, this patch fell through the cracks, thanks for taking care of it.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2019-11-17 18:30 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-10-24 20:45 [bug#37912] [PATCH] gnu: elixir: Update to 1.9.2 Oskar Köök
2019-10-25 12:16 ` Mathieu Othacehe
2019-10-31 14:35 ` Oskar Köök
2019-10-31 22:54 ` Marius Bakke
2019-11-01 13:45 ` Oskar Köök
2019-11-16 16:34 ` bug#37912: " Ludovic Courtès
2019-11-16 19:01 ` [bug#37912] " Oskar Köök
2019-11-17 18:29 ` Marius Bakke
2019-11-01 14:09 ` Oskar Köök
2019-11-03 16:52 ` Marius Bakke
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).