* [PATCH] Update Julia to 0.4.2.
@ 2015-12-23 11:56 Ricardo Wurmus
2015-12-30 15:57 ` Ludovic Courtès
0 siblings, 1 reply; 3+ messages in thread
From: Ricardo Wurmus @ 2015-12-23 11:56 UTC (permalink / raw)
To: guix-devel
[-- Attachment #1: Type: text/plain, Size: 475 bytes --]
Hi Guix,
this patch series updates our “julia” package to version 0.4.2. An
update to version 1.3.1 of “utf8proc” was required. I also made the
dependency on a patched version of “libuv” explicit by creating a
separate “julia-libuv” package.
Unfortunately, the build for “julia” is not reproducible. I haven’t yet
investigated what might be the cause and I don’t know yet how large the
difference between two builds is.
~~ Ricardo
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-gnu-utf8proc-Update-to-1.3.1.patch --]
[-- Type: text/x-patch, Size: 2241 bytes --]
From 416b5a0ef40cd2dff304db55846a258210388bb3 Mon Sep 17 00:00:00 2001
From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
Date: Mon, 30 Nov 2015 14:31:02 +0100
Subject: [PATCH 1/3] gnu: utf8proc: Update to 1.3.1.
* gnu/packages/textutils.scm (utf8proc): Update to 1.3.1.
[arguments]: Remove custom "install" phase.
---
gnu/packages/textutils.scm | 20 ++++++--------------
1 file changed, 6 insertions(+), 14 deletions(-)
diff --git a/gnu/packages/textutils.scm b/gnu/packages/textutils.scm
index 537a840..f929023 100644
--- a/gnu/packages/textutils.scm
+++ b/gnu/packages/textutils.scm
@@ -95,7 +95,7 @@ libenca and several charset conversion libraries and tools.")
(define-public utf8proc
(package
(name "utf8proc")
- (version "1.1.6")
+ (version "1.3.1")
(source
(origin
(method url-fetch)
@@ -104,23 +104,15 @@ libenca and several charset conversion libraries and tools.")
version ".tar.gz"))
(file-name (string-append name "-" version ".tar.gz"))
(sha256
- (base32 "0wmsi672knii0q70wh6a3ll0gv7qk33c50zbpzasrs3b16bqy659"))))
+ (base32 "1k48as5kjkar4yj3dwxyll8ykj4k723ib5a6mnw1g86q3zi0zdl3"))))
(build-system gnu-build-system)
(arguments
'(#:tests? #f ;no "check" target
- #:make-flags '("CC=gcc")
+ #:make-flags (list "CC=gcc"
+ (string-append "prefix=" (assoc-ref %outputs "out")))
#:phases
- (alist-replace
- 'install
- (lambda* (#:key outputs #:allow-other-keys)
- (let ((lib (string-append (assoc-ref outputs "out") "/lib/"))
- (include (string-append (assoc-ref outputs "out") "/include/")))
- (install-file "utf8proc.h" include)
- (for-each (lambda (file)
- (install-file file lib))
- '("libutf8proc.a" "libutf8proc.so"))))
- ;; no configure script
- (alist-delete 'configure %standard-phases))))
+ (modify-phases %standard-phases
+ (delete 'configure))))
(home-page "http://julialang.org/utf8proc/")
(synopsis "C library for processing UTF-8 Unicode data")
(description "utf8proc is a small C library that provides Unicode
--
2.1.0
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #3: 0002-gnu-Add-libuv-julia.patch --]
[-- Type: text/x-patch, Size: 2215 bytes --]
From 034cdddd452c036d5155a56da35d20e97d0e9f28 Mon Sep 17 00:00:00 2001
From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
Date: Mon, 30 Nov 2015 14:22:18 +0100
Subject: [PATCH 2/3] gnu: Add libuv-julia.
* gnu/packages/julia.scm (libuv-julia): New variable.
---
gnu/packages/julia.scm | 26 ++++++++++++++++++++++++++
1 file changed, 26 insertions(+)
diff --git a/gnu/packages/julia.scm b/gnu/packages/julia.scm
index fc152c8..f5123aa 100644
--- a/gnu/packages/julia.scm
+++ b/gnu/packages/julia.scm
@@ -20,6 +20,8 @@
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix packages)
#:use-module (guix download)
+ #:use-module (guix utils)
+ #:use-module (guix git-download)
#:use-module (guix build-system gnu)
#:use-module (gnu packages)
#:use-module (gnu packages algebra)
@@ -27,6 +29,7 @@
#:use-module (gnu packages elf)
#:use-module (gnu packages gcc)
#:use-module (gnu packages llvm)
+ #:use-module (gnu packages libevent)
#:use-module (gnu packages libunwind)
#:use-module (gnu packages maths)
#:use-module (gnu packages multiprecision) ; mpfr
@@ -38,6 +41,29 @@
#:use-module (gnu packages version-control)
#:use-module (ice-9 match))
+(define-public libuv-julia
+ (let ((commit "030481e9d659fd46702ab747caf2cbbe19d537ba")
+ (revision "1"))
+ (package (inherit libuv)
+ (name "libuv-julia")
+ (version (string-append "0.11.26." revision "-" (string-take commit 8)))
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/JuliaLang/libuv.git")
+ (commit commit)))
+ (file-name (string-append name "-" version "-checkout"))
+ (sha256
+ (base32
+ "1ss63wfr2hghc8kb6ciry394gp6x58haz8vaj57l5mp80z04gd54"))))
+ (build-system gnu-build-system)
+ (arguments
+ (substitute-keyword-arguments (package-arguments libuv)
+ ((#:phases phases)
+ `(modify-phases ,phases
+ (delete 'autogen)))))
+ (home-page "https://github.com/JuliaLang/libuv"))))
+
(define-public julia
(package
(name "julia")
--
2.1.0
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #4: 0003-gnu-julia-Update-to-0.4.2.patch --]
[-- Type: text/x-patch, Size: 10833 bytes --]
From 22027c25fd92c5f9821539fcf0b63fe763104ac0 Mon Sep 17 00:00:00 2001
From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
Date: Mon, 30 Nov 2015 14:25:53 +0100
Subject: [PATCH 3/3] gnu: julia: Update to 0.4.2.
* gnu/packages/patches/julia-0.3.10-fix-empty-array.patch: Remove file.
* gnu-system.am (dist_patch_DATA): Remove it.
* gnu/packages/julia.scm (julia): Update to 0.4.2.
[arguments]: Remove phase "fix-building-with-mcjit-llvm"; replace phase
"patch-include-path" with "fix-include-and-link-paths"; add phase
"hardcode-paths"; add missing make-flags.
[inputs]: Replace "pcre" with "pcre2"; replace "git" with "libgit2"; add
"coreutils"; add "libuv-julia"; add "wget"; add "which".
[native-inputs]: Remove "which".
---
gnu-system.am | 1 -
gnu/packages/julia.scm | 101 ++++++++++++++-------
.../patches/julia-0.3.10-fix-empty-array.patch | 13 ---
3 files changed, 69 insertions(+), 46 deletions(-)
delete mode 100644 gnu/packages/patches/julia-0.3.10-fix-empty-array.patch
diff --git a/gnu-system.am b/gnu-system.am
index df177b6..1338925 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -533,7 +533,6 @@ dist_patch_DATA = \
gnu/packages/patches/irrlicht-mesa-10.patch \
gnu/packages/patches/jasper-CVE-2008-3522.patch \
gnu/packages/patches/jbig2dec-ignore-testtest.patch \
- gnu/packages/patches/julia-0.3.10-fix-empty-array.patch \
gnu/packages/patches/kmod-module-directory.patch \
gnu/packages/patches/lftp-dont-save-unknown-host-fingerprint.patch \
gnu/packages/patches/liba52-enable-pic.patch \
diff --git a/gnu/packages/julia.scm b/gnu/packages/julia.scm
index f5123aa..54e0116 100644
--- a/gnu/packages/julia.scm
+++ b/gnu/packages/julia.scm
@@ -39,6 +39,7 @@
#:use-module (gnu packages python)
#:use-module (gnu packages textutils)
#:use-module (gnu packages version-control)
+ #:use-module (gnu packages wget)
#:use-module (ice-9 match))
(define-public libuv-julia
@@ -67,16 +68,15 @@
(define-public julia
(package
(name "julia")
- (version "0.3.10")
+ (version "0.4.2")
(source (origin
(method url-fetch)
(uri (string-append
"https://github.com/JuliaLang/julia/releases/download/v"
- version "/julia-" version "_c8ceeefcc1.tar.gz"))
+ version "/julia-" version "-full.tar.gz"))
(sha256
(base32
- "0j6mw6wr35lxid10nh9gz7k6wck3a90ic92w99n1r052325gl9r7"))
- (patches (list (search-patch "julia-0.3.10-fix-empty-array.patch")))))
+ "0sikirixvryf8z3d0skig22fpip64jk001qsha98iwsrcfiqpyds"))))
(build-system gnu-build-system)
(arguments
`(#:test-target "test"
@@ -92,8 +92,7 @@
#:phases
(modify-phases %standard-phases
(delete 'configure)
- (add-after
- 'unpack 'hardcode-soname-map
+ (add-after 'unpack 'hardcode-soname-map
;; ./src/ccall.cpp creates a map from library names to paths using the
;; output of "/sbin/ldconfig -p". Since ldconfig is not used in Guix,
;; we patch ccall.cpp to contain a static map.
@@ -108,46 +107,70 @@
"sonameMap[\"" libname "\"] = "
"\"" (assoc-ref inputs input) "/lib/" soname "\";")))
'(("libc" "libc" "libc.so.6")
- ("pcre" "libpcre" "libpcre.so")
+ ("pcre2" "libpcre2-8" "libpcre2-8.so")
("mpfr" "libmpfr" "libmpfr.so")
("openblas" "libblas" "libopenblas.so")
("arpack-ng" "libarpack" "libarpack.so")
("lapack" "liblapack" "liblapack.so")
+ ("libgit2" "libgit2" "libgit2.so")
("gmp" "libgmp" "libgmp.so")
("openlibm" "libopenlibm" "libopenlibm.so")
("openspecfun" "libopenspecfun" "libopenspecfun.so")
("fftw" "libfftw3" "libfftw3.so")
("fftwf" "libfftw3f" "libfftw3f.so"))))))
#t))
- ;; This phase will no longer be necessary in 0.3.11; see
- ;; https://github.com/JuliaLang/julia/issues/12028
- (add-before
- 'build 'fix-building-with-mcjit-llvm
- (lambda _
- (substitute* "src/cgutils.cpp"
- (("addComdat\\(gv\\);") ""))
- #t))
- (add-before
- 'build 'patch-include-path
- (lambda _
+ (add-before 'build 'fix-include-and-link-paths
+ (lambda* (#:key inputs #:allow-other-keys)
+ ;; LIBUTF8PROC is a linker flag, not a build target. It is
+ ;; included in the LIBFILES_* variable which is used as a
+ ;; collection of build targets and a list of libraries to link
+ ;; against.
+ (substitute* "src/flisp/Makefile"
+ (("\\$\\(BUILDDIR\\)/\\$\\(EXENAME\\): \\$\\(OBJS\\) \\$\\(LIBFILES_release\\)")
+ "$(BUILDDIR)/$(EXENAME): $(OBJS) $(LLT_release)")
+ (("\\$\\(BUILDDIR\\)/\\$\\(EXENAME\\)-debug: \\$\\(DOBJS\\) \\$\\(LIBFILES_debug\\)")
+ "$(BUILDDIR)/$(EXENAME)-debug: $(DOBJS) $(LLT_debug)"))
+
+ ;; The REPL must be linked with libuv.
+ (substitute* "ui/Makefile"
+ (("JLDFLAGS \\+= ")
+ (string-append "JLDFLAGS += "
+ (assoc-ref %build-inputs "libuv")
+ "/lib/libuv.so ")))
+
(substitute* "deps/Makefile"
(("/usr/include/double-conversion")
(string-append (assoc-ref %build-inputs "double-conversion")
"/include/double-conversion")))
+ (substitute* "base/Makefile"
+ (("\\$\\(build_includedir\\)/uv-errno.h")
+ (string-append (assoc-ref inputs "libuv")
+ "/include/uv-errno.h")))
#t))
- (add-before
- 'build 'replace-default-shell
+ (add-before 'build 'replace-default-shell
(lambda _
(substitute* "base/client.jl"
(("/bin/sh") (which "sh")))
#t))
- (add-before
- 'check 'disable-broken-test
- ;; One test fails because it produces slightly different output.
- (lambda _
- (substitute* "test/repl.jl"
- (("@test output") "# @test output"))
- #t)))
+ (add-after 'unpack 'hardcode-paths
+ (lambda _
+ (substitute* "base/interactiveutil.jl"
+ (("`which") (string-append "`" (which "which")))
+ (("`wget") (string-append "`" (which "wget"))))
+ #t))
+ (add-before 'check 'disable-broken-tests
+ (lambda _
+ (substitute* "test/choosetests.jl"
+ ;; These tests time out. See
+ ;; https://github.com/JuliaLang/julia/issues/14374 for ongoing
+ ;; discussion.
+ (("\"replcompletions\",") "")
+ (("\"repl\",") ""))
+ (substitute* "test/repl.jl"
+ ;; This test fails because we cannot escape the build
+ ;; directory.
+ (("@test pwd\\(\\) == homedir\\(\\)") "#"))
+ #t)))
#:make-flags
(list
(string-append "prefix=" (assoc-ref %outputs "out"))
@@ -163,7 +186,6 @@
(_ "MARCH=UNSUPPORTED"))
"CONFIG_SHELL=bash" ;needed to build bundled libraries
- "USE_SYSTEM_LIBUV=0" ;Julia expects a modified libuv
"USE_SYSTEM_DSFMT=0" ;not packaged for Guix and upstream has no
;build system for a shared library.
"USE_SYSTEM_RMATH=0" ;Julia uses a bundled version of R's math
@@ -184,10 +206,22 @@
;; (assoc-ref %build-inputs "suitesparse")
;; "/include")
+ "USE_GPL_LIBS=1" ;proudly
"USE_SYSTEM_GRISU=1" ;for double-conversion
"USE_SYSTEM_UTF8PROC=1"
+ (string-append "UTF8PROC_INC="
+ (assoc-ref %build-inputs "utf8proc")
+ "/include")
"USE_SYSTEM_LLVM=1"
"USE_SYSTEM_LIBUNWIND=1"
+ "USE_SYSTEM_LIBUV=1"
+ (string-append "LIBUV="
+ (assoc-ref %build-inputs "libuv")
+ "/lib/libuv.so")
+ (string-append "LIBUV_INC="
+ (assoc-ref %build-inputs "libuv")
+ "/include")
+ "USE_SYSTEM_PATCHELF=1"
"USE_SYSTEM_PCRE=1"
"USE_SYSTEM_OPENLIBM=1"
"USE_SYSTEM_GMP=1"
@@ -198,26 +232,29 @@
(inputs
`(("llvm" ,llvm-3.5)
("arpack-ng" ,arpack-ng)
+ ("coreutils" ,coreutils) ;for bindings to "mkdir" and the like
("lapack" ,lapack)
("openblas" ,openblas) ;Julia does not build with Atlas
("libunwind" ,libunwind)
("openlibm" ,openlibm)
("openspecfun" ,openspecfun)
("double-conversion" ,double-conversion)
+ ("libgit2" ,libgit2)
("fftw" ,fftw)
("fftwf" ,fftwf)
("fortran" ,gfortran)
- ("pcre" ,pcre)
+ ("libuv" ,libuv-julia)
+ ("pcre2" ,pcre2)
("utf8proc" ,utf8proc)
- ("git" ,git)
("mpfr" ,mpfr)
+ ("wget" ,wget)
+ ("which" ,which)
("gmp" ,gmp)))
(native-inputs
`(("perl" ,perl)
("patchelf" ,patchelf)
("pkg-config" ,pkg-config)
- ("python" ,python-2)
- ("which" ,which)))
+ ("python" ,python-2)))
;; Julia is not officially released for ARM and MIPS.
;; See https://github.com/JuliaLang/julia/issues/10639
(supported-systems '("i686-linux" "x86_64-linux"))
diff --git a/gnu/packages/patches/julia-0.3.10-fix-empty-array.patch b/gnu/packages/patches/julia-0.3.10-fix-empty-array.patch
deleted file mode 100644
index b00f654..0000000
--- a/gnu/packages/patches/julia-0.3.10-fix-empty-array.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-See https://github.com/JuliaLang/julia/issues/11817
-
---- a/src/codegen.cpp 2015-06-24 12:44:31.218674066 +0200
-+++ b/src/codegen.cpp 2015-04-23 11:19:50.000000000 +0200
-@@ -4551,7 +4551,7 @@
- #ifdef V128_BUG
- "-avx",
- #endif
-- };
-+ ""};
- SmallVector<std::string, 4> MAttrs(mattr, mattr+sizeof(mattr)/sizeof(mattr[0]));
- EngineBuilder eb = EngineBuilder(engine_module)
- .setEngineKind(EngineKind::JIT)
--
2.1.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] Update Julia to 0.4.2.
2015-12-23 11:56 [PATCH] Update Julia to 0.4.2 Ricardo Wurmus
@ 2015-12-30 15:57 ` Ludovic Courtès
2016-01-04 11:54 ` Ricardo Wurmus
0 siblings, 1 reply; 3+ messages in thread
From: Ludovic Courtès @ 2015-12-30 15:57 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: guix-devel
Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de> skribis:
> this patch series updates our “julia” package to version 0.4.2. An
> update to version 1.3.1 of “utf8proc” was required. I also made the
> dependency on a patched version of “libuv” explicit by creating a
> separate “julia-libuv” package.
Sounds good.
> Unfortunately, the build for “julia” is not reproducible. I haven’t yet
> investigated what might be the cause and I don’t know yet how large the
> difference between two builds is.
Julia is not mentioned in packages.yml in
<git://git.debian.org/git/reproducible/notes.git>, so I guess nobody has
looked at it yet.
When you have diff or Diffoscope info about the differences, please open
a bug.
> From 416b5a0ef40cd2dff304db55846a258210388bb3 Mon Sep 17 00:00:00 2001
> From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
> Date: Mon, 30 Nov 2015 14:31:02 +0100
> Subject: [PATCH 1/3] gnu: utf8proc: Update to 1.3.1.
>
> * gnu/packages/textutils.scm (utf8proc): Update to 1.3.1.
> [arguments]: Remove custom "install" phase.
OK.
> From 034cdddd452c036d5155a56da35d20e97d0e9f28 Mon Sep 17 00:00:00 2001
> From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
> Date: Mon, 30 Nov 2015 14:22:18 +0100
> Subject: [PATCH 2/3] gnu: Add libuv-julia.
>
> * gnu/packages/julia.scm (libuv-julia): New variable.
[...]
> +(define-public libuv-julia
Perhaps this can be kept private? If not, I would suggest changing the
‘synopsis’ field as well.
Otherwise LGTM.
> From 22027c25fd92c5f9821539fcf0b63fe763104ac0 Mon Sep 17 00:00:00 2001
> From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
> Date: Mon, 30 Nov 2015 14:25:53 +0100
> Subject: [PATCH 3/3] gnu: julia: Update to 0.4.2.
>
> * gnu/packages/patches/julia-0.3.10-fix-empty-array.patch: Remove file.
> * gnu-system.am (dist_patch_DATA): Remove it.
> * gnu/packages/julia.scm (julia): Update to 0.4.2.
> [arguments]: Remove phase "fix-building-with-mcjit-llvm"; replace phase
> "patch-include-path" with "fix-include-and-link-paths"; add phase
> "hardcode-paths"; add missing make-flags.
> [inputs]: Replace "pcre" with "pcre2"; replace "git" with "libgit2"; add
> "coreutils"; add "libuv-julia"; add "wget"; add "which".
> [native-inputs]: Remove "which".
LGTM.
Thanks, and sorry for the delay!
Ludo’.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] Update Julia to 0.4.2.
2015-12-30 15:57 ` Ludovic Courtès
@ 2016-01-04 11:54 ` Ricardo Wurmus
0 siblings, 0 replies; 3+ messages in thread
From: Ricardo Wurmus @ 2016-01-04 11:54 UTC (permalink / raw)
To: Ludovic Courtès; +Cc: guix-devel
Ludovic Courtès <ludo@gnu.org> writes:
> Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de> skribis:
>
>> Unfortunately, the build for “julia” is not reproducible. I haven’t yet
>> investigated what might be the cause and I don’t know yet how large the
>> difference between two builds is.
>
> Julia is not mentioned in packages.yml in
> <git://git.debian.org/git/reproducible/notes.git>, so I guess nobody has
> looked at it yet.
>
> When you have diff or Diffoscope info about the differences, please open
> a bug.
There are some obvious things (such as embedding a timestamp in a
version string). Maybe changing those things would be sufficient
already. I’ll play with this first. If I cannot find anything else
I’ll report a bug as soon as I have something to share.
>> From 034cdddd452c036d5155a56da35d20e97d0e9f28 Mon Sep 17 00:00:00 2001
>> From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
>> Date: Mon, 30 Nov 2015 14:22:18 +0100
>> Subject: [PATCH 2/3] gnu: Add libuv-julia.
>>
>> * gnu/packages/julia.scm (libuv-julia): New variable.
>
> [...]
>
>> +(define-public libuv-julia
>
> Perhaps this can be kept private? If not, I would suggest changing the
> ‘synopsis’ field as well.
I made it private.
> Thanks, and sorry for the delay!
No problem. (There’s no urgency.) Thanks for the review!
~~ Ricardo
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-01-04 11:54 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-12-23 11:56 [PATCH] Update Julia to 0.4.2 Ricardo Wurmus
2015-12-30 15:57 ` Ludovic Courtès
2016-01-04 11:54 ` Ricardo Wurmus
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.