From 5a1ddd146bfd6cd874d0617872fe45148832113b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 14 Sep 2021 20:45:41 -0400 Subject: gnu: ldc: Update to 1.27.1. * gnu/packages/dlang.scm (ldc-bootstrap): Rename to... (ldc-bootstrap-0.17): ... this. Fix indentation. Disable tests. [phases]: Remove test related patching. {patch-phobos}: Rename to ... {patch-paths}: ... this. [inputs]: Remove llvm-6, which is propagated by clang-6. (ldc-bootstrap-1.12): New variable, based on the previous ldc. [source]: Use the official release tarball. [build-type]: Set the build type to Release. [configure-flags]: Pass the -GNinja configure flag. [phases]{patch-paths}: Override to adjust for changed paths. {build, install}: Override to use ninja. [native-inputs]: Add ld-gold-wrapper. Update llvm to version 11 and use ldc-bootstrap-0.17 as the bootstrapping D compiler. Add ninja. Remove the phobos-src, druntime-src and dmd-testsuite-src source inputs, now included in the official release. (ldc-bootstrap-1.24): Other intermediate variant for bootstrapping purposes. (ldc): Update to 1.27.1. [make-flags]: New argument. [configure-flags]: Adjust. [phases]{fix-compiler-rt-library-discovery}: New phase. {patch-paths-in-tests}: Likewise. {disable-problematic-tests}: Likewise. Compared to before, many GDB tests are reinstated. {set-cc-and-cxx-to-use-clang}: New phase. {tests}: Override. [inputs]: Update clang to version 11. Bootstrap from a stage 1 version of itself. * gnu/packages/patches/ldc-bootstrap-disable-tests.patch: Delete file. * gnu/packages/patches/ldc-disable-phobos-tests.patch: Likewise. * gnu/local.mk: De-register them. --- .../patches/ldc-bootstrap-disable-tests.patch | 72 ---------------------- .../patches/ldc-disable-phobos-tests.patch | 22 ------- 2 files changed, 94 deletions(-) delete mode 100644 gnu/packages/patches/ldc-bootstrap-disable-tests.patch delete mode 100644 gnu/packages/patches/ldc-disable-phobos-tests.patch (limited to 'gnu/packages/patches') diff --git a/gnu/packages/patches/ldc-bootstrap-disable-tests.patch b/gnu/packages/patches/ldc-bootstrap-disable-tests.patch deleted file mode 100644 index d2e40b8016..0000000000 --- a/gnu/packages/patches/ldc-bootstrap-disable-tests.patch +++ /dev/null @@ -1,72 +0,0 @@ -This patch fixes a failing unit test by feeding buildNormalizedPath to the -tzdata properly. Three other tests are disabled, one assumes /root and the -two others use networking. Not bad out of almost 700 tests! - -by Pjotr Prins - ---- a/std/datetime.d.orig 2016-11-24 01:13:52.584495545 +0100 -+++ b/std/datetime.d 2016-11-24 01:17:09.655306728 +0100 -@@ -28081,22 +28081,24 @@ - import std.range : retro; - import std.format : format; - -- name = strip(name); -- - enforce(tzDatabaseDir.exists(), new DateTimeException(format("Directory %s does not exist.", tzDatabaseDir))); - enforce(tzDatabaseDir.isDir, new DateTimeException(format("%s is not a directory.", tzDatabaseDir))); - - version(Android) - { -+ name = strip(name); - auto tzfileOffset = name in tzdataIndex(tzDatabaseDir); - enforce(tzfileOffset, new DateTimeException(format("The time zone %s is not listed.", name))); - string tzFilename = separate_index ? "zoneinfo.dat" : "tzdata"; - immutable file = buildNormalizedPath(tzDatabaseDir, tzFilename); - } - else -- immutable file = buildNormalizedPath(tzDatabaseDir, name); -+ { -+ auto filename = "./" ~ strip(name); // make sure the prefix is not stripped -+ immutable file = buildNormalizedPath(tzDatabaseDir, filename); -+ } - -- enforce(file.exists(), new DateTimeException(format("File %s does not exist.", file))); -+ enforce(file.exists(), new DateTimeException(format("File %s does not exist in %s.", file, tzDatabaseDir))); - enforce(file.isFile, new DateTimeException(format("%s is not a file.", file))); - - auto tzFile = File(file); -diff --git a/std/path.d b/std/path.d -index 254d8f0..b0fc04d 100644 ---- a/std/path.d -+++ b/std/path.d -@@ -3080,8 +3080,11 @@ unittest - } - else - { -+ pragma(msg, "test disabled on GNU Guix"); -+/* - assert(expandTilde("~root") == "/root", expandTilde("~root")); - assert(expandTilde("~root/") == "/root/", expandTilde("~root/")); -+*/ - } - assert(expandTilde("~Idontexist/hey") == "~Idontexist/hey"); - } -diff --git a/std/socket.d b/std/socket.d -index b85d1c9..7fbf346 100644 ---- a/std/socket.d -+++ b/std/socket.d -@@ -859,6 +862,8 @@ class InternetHost - - unittest - { -+ pragma(msg, "test disabled on GNU Guix"); -+ /* - InternetHost ih = new InternetHost; - - ih.getHostByAddr(0x7F_00_00_01); -@@ -889,6 +894,7 @@ unittest - // writefln("aliases[%d] = %s", i, s); - // } - }); -+ */ - } diff --git a/gnu/packages/patches/ldc-disable-phobos-tests.patch b/gnu/packages/patches/ldc-disable-phobos-tests.patch deleted file mode 100644 index f8a9743d59..0000000000 --- a/gnu/packages/patches/ldc-disable-phobos-tests.patch +++ /dev/null @@ -1,22 +0,0 @@ -diff --git a/std/socket.d b/std/socket.d -index 111cd17..6d23da9 100644 ---- a/std/socket.d -+++ b/std/socket.d -@@ -448,7 +448,7 @@ class Protocol - // Skip this test on Android because getprotobyname/number are - // unimplemented in bionic. - version(CRuntime_Bionic) {} else --@safe unittest -+@safe version(hasNetwork) unittest - { - // import std.stdio : writefln; - softUnittest({ -@@ -770,7 +770,7 @@ class InternetHost - } - - /// --@safe unittest -+@safe version(hasNetwork) unittest - { - InternetHost ih = new InternetHost; - -- cgit v1.2.3