From: Igor Goryachev via Guix-patches via <guix-patches@gnu.org>
To: 73367@debbugs.gnu.org
Cc: Igor Goryachev <igor@goryachev.org>, Andrew Tropin <andrew@trop.in>
Subject: [bug#73367] [PATCH 3/4] gnu: rebar3: Update to 3.24.0, make reproducible.
Date: Thu, 19 Sep 2024 19:39:12 +0300 [thread overview]
Message-ID: <2541ae31df2001548d1ebd91ecb3b34155408fdf.1726763309.git.igor@goryachev.org> (raw)
In-Reply-To: <cover.1726763309.git.igor@goryachev.org>
* gnu/packages/erlang.scm (rebar3): Update to 3.24.0.
[arguments]<#:phases>: Modify 'make-escriptize-reproducible phase.
Change-Id: I264515753f1ed0bdabdc4042a1c850d738c27738
---
gnu/packages/erlang.scm | 31 ++++++++-----------------------
1 file changed, 8 insertions(+), 23 deletions(-)
diff --git a/gnu/packages/erlang.scm b/gnu/packages/erlang.scm
index 5d8516f311..026a7dd32e 100644
--- a/gnu/packages/erlang.scm
+++ b/gnu/packages/erlang.scm
@@ -637,7 +637,7 @@ (define-public erlang-ssl-verify-fun
(define-public rebar3
(package
(name "rebar3")
- (version "3.23.0")
+ (version "3.24.0")
(source
(origin
(method git-fetch)
@@ -646,7 +646,7 @@ (define-public rebar3
(commit version)))
(file-name (git-file-name name version))
(sha256
- (base32 "0jinjx3mk5j1kczxmblixbvhf24q0yfwih2ggs11x5ykmrqpbckl"))))
+ (base32 "1l73csyzxwinhrcsyb8hg2003v35yz6pv98inl3wg1j5587f071s"))))
(build-system gnu-build-system)
;; TODO: remove vendored modules, install man-page, install lib(?)
(arguments
@@ -672,29 +672,14 @@ (define-public rebar3
"eunit_formatters" "getopt" "hex_core" "erlware_commons"
"parse_trans" "relx" "ssl_verify_fun" "providers"))))
(delete 'configure)
- ;; By default rebar3 produces escripts with embedded ZIP archives
- ;; with files with current timestamps which is not suitable for
- ;; reproducible builds. We fix it by setting predefined timestamps.
+ ;; Due to changes in Erlang 27.1 related to handling ZIP-archives
+ ;; we still need to patch rebar to make it generate reproducible
+ ;; escripts.
(add-before 'build 'make-escriptize-reproducible
(lambda _
- (let ((escriptize "apps/rebar/src/rebar_prv_escriptize.erl"))
- (substitute* escriptize
- (("\\[dir_entries\\(filename:dirname\\(Filename1\\)\\),")
- (string-append "FilePath = filename:join(Dir, Filename),"
- "{ok, FileInfo0} = file:read_file_info(FilePath),"
- "DateTime = {{1970, 1, 1}, {0, 0, 1}},"
- "FileInfo = FileInfo0#file_info{mtime = DateTime},"
- "[dir_entries(filename:dirname(Filename1)),")))
- (substitute* escriptize
- (((string-append
- "\\{Filename1, file_contents\\(filename:join\\(Dir, "
- "Filename\\)\\)\\}\\]."))
- "{Filename1, file_contents(FilePath), FileInfo}]."))
- (substitute* escriptize
- (((string-append "\\[\\{FName,FBin\\} \\|\\| \\{FName,FBin\\} <- "
- "Files, FBin =/= <<>>\\]\\."))
- (string-append "[{FName,FBin,FInfo} || {FName,FBin,FInfo} <- "
- "Files, FBin =/= <<>>]."))))))
+ (substitute* "apps/rebar/src/rebar_prv_escriptize.erl"
+ (("mtime = DateTime")
+ "atime = DateTime,ctime = DateTime,mtime = DateTime"))))
(replace 'build
(lambda _
(setenv "HOME" (getcwd))
--
2.46.0
next prev parent reply other threads:[~2024-09-19 16:41 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-19 16:28 [bug#73367] [PATCH 0/4] Update erlang, elixir and rebar3 Igor Goryachev via Guix-patches via
2024-09-19 16:39 ` [bug#73367] [PATCH 1/4] gnu: erlang: Update to 27.1 Igor Goryachev via Guix-patches via
2024-09-19 16:39 ` [bug#73367] [PATCH 2/4] gnu: erlang: Fix build Igor Goryachev via Guix-patches via
2024-09-19 16:39 ` Igor Goryachev via Guix-patches via [this message]
2024-09-19 16:39 ` [bug#73367] [PATCH 4/4] gnu: elixir: Update to 1.17.3 Igor Goryachev via Guix-patches via
2024-09-24 12:28 ` bug#73367: [PATCH 0/4] Update erlang, elixir and rebar3 Andrew Tropin via Guix-patches via
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2541ae31df2001548d1ebd91ecb3b34155408fdf.1726763309.git.igor@goryachev.org \
--to=guix-patches@gnu.org \
--cc=73367@debbugs.gnu.org \
--cc=andrew@trop.in \
--cc=igor@goryachev.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).