From: Efraim Flashner <efraim@flashner.co.il>
To: Akira Kyle <akira@akirakyle.com>
Cc: 56807@debbugs.gnu.org
Subject: [bug#56807] [PATCH] [WIP] Update Julia to 1.8.0
Date: Sun, 7 Aug 2022 05:47:09 +0300 [thread overview]
Message-ID: <Yu8nrbgv/gN0+YTu@pbp> (raw)
In-Reply-To: <87y1wd6f1z.fsf@akirakyle.com>
[-- Attachment #1.1: Type: text/plain, Size: 329 bytes --]
I started with your patch and made a few changes on top of it. I haven't
started looking into the test suite yet.
--
Efraim Flashner <efraim@flashner.co.il> אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
[-- Attachment #1.2: julia-1.8.0-updates.diff --]
[-- Type: text/plain, Size: 13202 bytes --]
diff --git a/gnu/packages/julia.scm b/gnu/packages/julia.scm
index 68d6d7316d..738a4389b1 100644
--- a/gnu/packages/julia.scm
+++ b/gnu/packages/julia.scm
@@ -179,10 +179,10 @@ (define-public julia
"/lib"))
'("curl" "dsfmt"
"gmp" "lapack"
+ "libblastrampoline"
"libssh2" "libnghttp2" "libgit2"
- "mbedtls" "mpfr"
- "openblas" "openblas" "libblastrampoline"
- "openlibm" "pcre2"
+ "mbedtls-apache" "mpfr"
+ "openblas" "openlibm" "pcre2"
"suitesparse" "gfortran:lib"))
":"))))
;; FIXME: Building the documentation requires Julia packages that
@@ -211,12 +211,11 @@ (define-public julia
"base/Makefile")
((".*libquadmath.*") ""))
(substitute* "Makefile"
- (("libquadmath ") ""))
- #t)))
+ (("libquadmath ") "")))))
'())
(add-before 'check 'set-home
;; Some tests require a home directory to be set.
- (lambda _ (setenv "HOME" "/tmp") #t))
+ (lambda _ (setenv "HOME" "/tmp")))
(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
@@ -273,9 +272,9 @@ (define-public julia
(substitute* (jlpath "MPFR")
(((from "libmpfr")) (to "mpfr" "libmpfr")))
(substitute* (jlpath "MbedTLS")
- (((from "libmbedcrypto")) (to "mbedtls" "libmbedcrypto"))
- (((from "libmbedtls")) (to "mbedtls" "libmbedtls"))
- (((from "libmbedx509")) (to "mbedtls" "libmbedx509")))
+ (((from "libmbedcrypto")) (to "mbedtls-apache" "libmbedcrypto"))
+ (((from "libmbedtls")) (to "mbedtls-apache" "libmbedtls"))
+ (((from "libmbedx509")) (to "mbedtls-apache" "libmbedx509")))
(substitute* (jlpath "nghttp2")
(((from "libnghttp2")) (to "libnghttp2" "libnghttp2")))
(substitute* (jlpath "OpenBLAS")
@@ -313,27 +312,22 @@ (define-public julia
(getenv "JULIA_CPU_THREADS"))))
(add-after 'unpack 'adjust-test-suite
(lambda* (#:key inputs #:allow-other-keys)
- (let ((pcre2 (assoc-ref inputs "pcre2"))
- (mbedtls-julia (assoc-ref inputs "mbedtls"))
- (mpfr (assoc-ref inputs "mpfr"))
- (gmp (assoc-ref inputs "gmp"))
- (nghttp2 (assoc-ref inputs "libnghttp2"))
- (suitesparse (assoc-ref inputs "suitesparse")))
- ;; Some tests only check to see if the input is the correct version.
- (substitute* "stdlib/PCRE2_jll/test/runtests.jl"
- (("10.36.0") ,(package-version pcre2)))
- (substitute* "stdlib/MbedTLS_jll/test/runtests.jl"
- (("2.28.0") ,(package-version mbedtls-apache)))
- (substitute* "stdlib/MPFR_jll/test/runtests.jl"
- (("4.1.0") ,(package-version mpfr)))
- (substitute* "stdlib/GMP_jll/test/runtests.jl"
- (("6.2.0") ,(package-version gmp)))
- (substitute* "stdlib/nghttp2_jll/test/runtests.jl"
- (("1.41.0") ,(package-version nghttp2)))
- (substitute* "stdlib/SuiteSparse_jll/test/runtests.jl"
- (("5004") ,(string-replace-substring
- (version-major+minor
- (package-version suitesparse)) "." "0"))))))
+ ;; Some tests only check to see if the input is the correct version.
+ (substitute* "stdlib/PCRE2_jll/test/runtests.jl"
+ (("10.40.0") ,(package-version (this-package-input "pcre2"))))
+ (substitute* "stdlib/MbedTLS_jll/test/runtests.jl"
+ (("2.28.0") ,(package-version (this-package-input "mbedtls-apache"))))
+ (substitute* "stdlib/MPFR_jll/test/runtests.jl"
+ (("4.1.0") ,(package-version (this-package-input "mpfr"))))
+ (substitute* "stdlib/GMP_jll/test/runtests.jl"
+ (("6.2.1") ,(package-version (this-package-input "gmp"))))
+ (substitute* "stdlib/nghttp2_jll/test/runtests.jl"
+ (("1.47.0") ,(package-version (this-package-input "libnghttp2"))))
+ (substitute* "stdlib/SuiteSparse_jll/test/runtests.jl"
+ (("5010") ,(string-replace-substring
+ (version-major+minor
+ (package-version
+ (this-package-input "suitesparse"))) "." "0")))))
; (add-before 'check 'disable-broken-tests
; (lambda _
; ;; disabling REPL tests because they require a stdin
@@ -418,7 +412,7 @@ (define-public julia
(basename file)))))
(find-files (string-append (assoc-ref inputs pkgname)
"/lib") pred)))))
- (link "llvm" "libLLVM-11jl\\.so")
+ (link "llvm" "libLLVM-13jl\\.so")
(link "utf8proc" "libutf8proc\\.so"))))
(add-after 'install 'make-wrapper
(lambda* (#:key inputs outputs #:allow-other-keys)
@@ -465,7 +459,7 @@ (define-public julia
"USE_SYSTEM_LAPACK=1"
"USE_SYSTEM_GMP=1"
"USE_SYSTEM_MPFR=1"
- "USE_SYSTEM_LIBBLASTRAMPOLINE:=1"
+ "USE_SYSTEM_LIBBLASTRAMPOLINE=1"
"USE_SYSTEM_LIBSUITESPARSE=1"
"USE_SYSTEM_LIBUV=1"
"USE_SYSTEM_UTF8PROC=1"
@@ -475,7 +469,7 @@ (define-public julia
"USE_SYSTEM_CURL=1"
"USE_SYSTEM_LIBGIT2=1"
"USE_SYSTEM_PATCHELF=1"
- "USE_SYSTEM_LIBWHICH:=1"
+ "USE_SYSTEM_LIBWHICH=1"
"USE_SYSTEM_ZLIB=1"
"USE_SYSTEM_P7ZIP=1"
"VERBOSE=1"
@@ -508,21 +502,23 @@ (define-public julia
("gfortran:lib" ,gfortran "lib")
("gmp" ,gmp)
("lapack" ,lapack)
- ("libgit2" ,libgit2-1.1)
+ ("libblastrampoline" ,libblastrampoline)
+ ;("libgit2" ,libgit2-1.1)
+ ("libgit2" ,libgit2)
("libnghttp2" ,nghttp2 "lib")
("libssh2" ,libssh2)
("libunwind" ,libunwind-julia)
("libuv" ,libuv-julia)
- ("llvm" ,llvm-13)
- ("mbedtls" ,mbedtls-apache)
+ ("llvm" ,llvm-julia)
+ ("mbedtls-apache" ,mbedtls-apache)
("mpfr" ,mpfr)
("openblas" ,openblas)
- ("libblastrampoline" ,libblastrampoline)
("openlibm" ,openlibm)
("p7zip" ,p7zip)
("pcre2" ,pcre2)
("suitesparse" ,suitesparse)
- ("utf8proc" ,utf8proc-2.6.1)
+ ;("utf8proc" ,utf8proc-2.6.1)
+ ("utf8proc" ,utf8proc)
("wget" ,wget)
("which" ,which)
("zlib" ,zlib)
diff --git a/gnu/packages/llvm.scm b/gnu/packages/llvm.scm
index 2d6274b33a..b7cdcc03f5 100644
--- a/gnu/packages/llvm.scm
+++ b/gnu/packages/llvm.scm
@@ -60,7 +60,6 @@ (define-module (gnu packages llvm)
#:use-module (gnu packages bootstrap) ;glibc-dynamic-linker
#:use-module (gnu packages check) ;python-lit
#:use-module (gnu packages compression)
- #:use-module (gnu packages julia) ;julia-patch
#:use-module (gnu packages libedit)
#:use-module (gnu packages libffi)
#:use-module (gnu packages lua)
@@ -591,9 +590,8 @@ (define-public llvm-14
'())
"-DCMAKE_SKIP_BUILD_RPATH=FALSE"
"-DCMAKE_BUILD_WITH_INSTALL_RPATH=FALSE"
+ "-DBUILD_SHARED_LIBS:BOOL=TRUE"
"-DLLVM_ENABLE_FFI:BOOL=TRUE"
- "-DLLVM_BUILD_LLVM_DYLIB=ON"
- "-DLLVM_LINK_LLVM_DYLIB=ON"
"-DLLVM_REQUIRES_RTTI=1" ;for some third-party utilities
"-DLLVM_INSTALL_UTILS=ON") ;needed for rustc
;; Don't use '-g' during the build, to save space.
@@ -1925,6 +1923,23 @@ (define-public ocaml-llvm-9 (make-ocaml-llvm llvm-9))
(define-public ocaml-llvm-10 (make-ocaml-llvm llvm-10))
(define-public ocaml-llvm-11 (make-ocaml-llvm llvm-11))
+(define-public llvm-julia
+ (package
+ (inherit llvm-13)
+ (arguments
+ (substitute-keyword-arguments (package-arguments llvm-13)
+ ((#:configure-flags flags ''())
+ #~(cons* "-DLLVM_BUILD_LLVM_DYLIB=ON"
+ "-DLLVM_LINK_LLVM_DYLIB=ON"
+ ;; "-DLLVM_EXPERIMENTAL_TARGETS_TO_BUILD=NVPTX"
+ "-DLLVM_VERSION_SUFFIX:STRING=jl" ; Perhaps not needed.
+ #$(string-append "-DLLVM_TARGETS_TO_BUILD="
+ (system->llvm-target))
+ (delete "-DBUILD_SHARED_LIBS:BOOL=TRUE" #$flags)))
+ ((#:build-type _) "Release")))
+ (properties `((hidden? . #t)
+ ,@(package-properties llvm-13)))))
+
(define %cling-version "0.9")
(define llvm-cling ;LLVM 9 with approximately 10 patches for cling
diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index 745c908cfd..e04897de1d 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -4651,35 +4651,6 @@ (define-public openblas
"OpenBLAS is a BLAS library forked from the GotoBLAS2-1.13 BSD version.")
(license license:bsd-3)))
-(define-public libblastrampoline
- (package
- (name "libblastrampoline")
- (version "5.1.1")
- (source
- (origin
- (method git-fetch)
- (uri (git-reference
- (url "https://github.com/JuliaLinearAlgebra/libblastrampoline")
- (commit (string-append "v" version))))
- (file-name (git-file-name name version))
- (sha256
- (base32
- "0mf79zw11kxyil72y2ly5x8bbz3ng3nsqmp0zcps16b69wvfs19c"))))
- (build-system gnu-build-system)
- (arguments
- '(#:make-flags (list "-C" "src"
- (string-append "prefix=" (assoc-ref %outputs "out"))
- "CC=gcc")
- #:tests? #f ;no check target
- #:phases
- (modify-phases %standard-phases
- (delete 'configure))))
- (home-page "https://github.com/JuliaLinearAlgebra/libblastrampoline")
- (synopsis "Using PLT trampolines to provide a BLAS and LAPACK demuxing library. ")
- (description
- "Using PLT trampolines to provide a BLAS and LAPACK demuxing library. ")
- (license license:expat)))
-
(define-public openblas-ilp64
(package/inherit openblas
(name "openblas-ilp64")
@@ -4692,6 +4663,35 @@ (define-public openblas-ilp64
(synopsis "Optimized BLAS library based on GotoBLAS (ILP64 version)")
(license license:bsd-3)))
+(define-public libblastrampoline
+ (package
+ (name "libblastrampoline")
+ (version "5.1.1")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/JuliaLinearAlgebra/libblastrampoline")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0mf79zw11kxyil72y2ly5x8bbz3ng3nsqmp0zcps16b69wvfs19c"))))
+ (build-system gnu-build-system)
+ (arguments
+ `(#:make-flags (list "-C" "src"
+ (string-append "prefix=" (assoc-ref %outputs "out"))
+ (string-append "CC=" ,(cc-for-target)))
+ #:tests? #f ;no check target
+ #:phases
+ (modify-phases %standard-phases
+ (delete 'configure))))
+ (home-page "https://github.com/JuliaLinearAlgebra/libblastrampoline")
+ (synopsis "Using PLT trampolines to provide a BLAS and LAPACK demuxing library.")
+ (description
+ "Using PLT trampolines to provide a BLAS and LAPACK demuxing library.")
+ (license license:expat)))
+
(define-public blis
(package
(name "blis")
diff --git a/gnu/packages/tls.scm b/gnu/packages/tls.scm
index 7eb6f03f5c..d8123864fc 100644
--- a/gnu/packages/tls.scm
+++ b/gnu/packages/tls.scm
@@ -1007,8 +1007,7 @@ (define-public mbedtls-apache
(modify-phases %standard-phases
(add-after 'unpack 'make-source-writable
(lambda _
- (for-each make-file-writable (find-files "."))
- #t)))))
+ (for-each make-file-writable (find-files ".")))))))
(native-inputs
(list perl python))
(synopsis "Small TLS library")
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2022-08-07 2:48 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-28 2:22 [bug#56807] [PATCH] [WIP] Update Julia to 1.8.0 Akira Kyle
2022-08-07 2:47 ` Efraim Flashner [this message]
2022-08-23 8:37 ` Jean-Baptiste Volatier via Guix-patches via
2022-12-12 13:13 ` bug#56807: " Efraim Flashner
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Yu8nrbgv/gN0+YTu@pbp \
--to=efraim@flashner.co.il \
--cc=56807@debbugs.gnu.org \
--cc=akira@akirakyle.com \
/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 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.