From 828ca92aac998c76693e63db8805e49fdcead10d Mon Sep 17 00:00:00 2001 From: oreo639 Date: Sat, 17 Dec 2022 18:58:59 -0800 Subject: [PATCH 1/9] dmd: update to 2.101.1. --- srcpkgs/dmd/files/musl.patch | 4 ++-- srcpkgs/dmd/template | 29 +++++++++++------------------ 2 files changed, 13 insertions(+), 20 deletions(-) diff --git a/srcpkgs/dmd/files/musl.patch b/srcpkgs/dmd/files/musl.patch index bf41a3e49619..79b7bcd7e6d6 100644 --- a/srcpkgs/dmd/files/musl.patch +++ b/srcpkgs/dmd/files/musl.patch @@ -1,5 +1,5 @@ ---- dmd/src/dmd/link.d -+++ dmd/src/dmd/link.d +--- dmd/compiler/src/dmd/link.d ++++ dmd/compiler/src/dmd/link.d @@ -759,8 +759,7 @@ perror("unable to create pipe to linker"); return -1; diff --git a/srcpkgs/dmd/template b/srcpkgs/dmd/template index 0f6801ad1fef..fc75ca12b918 100644 --- a/srcpkgs/dmd/template +++ b/srcpkgs/dmd/template @@ -1,8 +1,7 @@ # Template file for 'dmd' pkgname=dmd -version=2.098.0 -revision=3 -reverts="2.100.0_1" +version=2.101.1 +revision=1 create_wrksrc=yes hostmakedepends="dmd2.091 which" makedepends="git" @@ -12,14 +11,12 @@ maintainer="streaks " license="BSL-1.0" homepage="http://www.digitalmars.com/d/2.0/" distfiles=" - https://github.com/dlang/dmd/archive/v${version}.tar.gz>dmd-${version}.tar.gz - https://github.com/dlang/druntime/archive/v${version}.tar.gz>druntime-${version}.tar.gz + https://github.com/dlang/dmd/archive/refs/tags/v${version}.tar.gz>dmd-${version}.tar.gz https://github.com/dlang/phobos/archive/v${version}.tar.gz>phobos-${version}.tar.gz http://downloads.dlang.org/releases/2.x/${version}/dmd.${version}.linux.tar.xz" -checksum="437e7abae7f747ce8a027e512d2f98f0c27badd623347141c3f6fb0834d85ad0 - f150400756c7940bc9d67a3ed7f89777e49b42a1ef2dff6f40727f83b3cea6f4 - f91c6c7f2d5683af2804a183c287bf6991b99c49692759d7844e1919ca59e974 - 1104e5e59fd47828b798d77a72be547bf086bba1d374a1855c6b5814c4db0145" +checksum="e369396dbbe4eec9311122fa24c975688b209a000bf2062a9f86b49ab2e4a7b0 + 8a275b3f46d921be87744ec80d3094421a979d6f607dbd43e88e251bbb3f503a + 58333e57ed3812077dc2f8cc8759998b3b59c9ea3dbe01571eab4b2944a84bfe" conf_files="/etc/dmd.conf" provides="d-compiler-${version}_${revision}" conflicts="dmd-bootstrap dmd2.081 dmd2.091" @@ -38,7 +35,6 @@ esac post_extract() { mv dmd-${version} dmd - mv druntime-${version} druntime mv phobos-${version} phobos } @@ -55,10 +51,7 @@ do_build() { make ${makejobs} -f posix.mak MODEL=${_archbits} TARGET_CPU=X86 ENABLE_RELEASE=1 PIC=1 dmd=${wrksrc}/dmd/generated/linux/release/$_archbits/dmd - make ${makejobs} -C docs - - cd ../druntime - make ${makejobs} -f posix.mak MODEL=${_archbits} DMD=$dmd ENABLE_RELEASE=1 PIC=1 + make ${makejobs} -C compiler/docs cd ../phobos make ${makejobs} -f posix.mak MODEL=${_archbits} DMD=$dmd ENABLE_RELEASE=1 PIC=1 @@ -94,17 +87,17 @@ dmd-doc_package() { libphobos_package() { short_desc+=" - standard library" license="BSL-1.0" - conflicts="dmd-bootstrap" + conflicts="dmd-bootstrap dmd2.081 dmd2.091" pkg_install() { - vinstall ${wrksrc}/druntime/generated/linux/release/$_archbits/libdruntime.a 644 usr/lib libdruntime.a + vinstall ${wrksrc}/dmd/generated/linux/release/$_archbits/libdruntime.a 644 usr/lib libdruntime.a vinstall ${wrksrc}/phobos/generated/linux/release/$_archbits/libphobos2.a 644 usr/lib libphobos2.a vmkdir usr/include/d cp -r ${wrksrc}/phobos/{*.d,etc,std} ${PKGDESTDIR}/usr/include/d vmkdir usr/include/d/druntime - cp -r ${wrksrc}/druntime/import ${PKGDESTDIR}/usr/include/d/druntime + cp -r ${wrksrc}/dmd/druntime/import ${PKGDESTDIR}/usr/include/d/druntime - vlicense ${wrksrc}/druntime/LICENSE.txt + vlicense ${wrksrc}/dmd/LICENSE.txt } } From 8fe145971f7efbce04a87ee526abe5a78740660f Mon Sep 17 00:00:00 2001 From: oreo639 Date: Sat, 17 Dec 2022 19:11:27 -0800 Subject: [PATCH 2/9] dtools: update to 2.101.1. --- srcpkgs/dtools/template | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/srcpkgs/dtools/template b/srcpkgs/dtools/template index 36bd9b41532b..f8bc5b41e19a 100644 --- a/srcpkgs/dtools/template +++ b/srcpkgs/dtools/template @@ -1,9 +1,8 @@ # Template file for 'dtools' pkgname=dtools -reverts="2.100.0_1" # keep this synchronized with libphobos and dmd -version=2.098.0 -revision=2 +version=2.101.1 +revision=1 hostmakedepends="dmd" makedepends="libcurl-devel" depends="libphobos>=${version}" @@ -12,7 +11,7 @@ maintainer="Auri " license="BSL-1.0" homepage="http://www.digitalmars.com/d/2.0/" distfiles="https://github.com/dlang/tools/archive/v${version}.tar.gz" -checksum=9466e62ed2cf80802158524fc4e7ff80cbefc0fadff23a8933f6f2892b42cb56 +checksum=0e6892084f95f87fa330579a1f6131dec8cfa8e254aabb3cb73a5bf2a673d2ac do_build() { # rdmd can't be built normally, is used to build others From 254ce46a772994fda14d85cd90cb3c71a97af681 Mon Sep 17 00:00:00 2001 From: oreo639 Date: Sat, 17 Dec 2022 20:14:11 -0800 Subject: [PATCH 3/9] dmd2.081: fix conflicts --- srcpkgs/dmd2.081/template | 46 +++++++++++++++------------------------ 1 file changed, 17 insertions(+), 29 deletions(-) diff --git a/srcpkgs/dmd2.081/template b/srcpkgs/dmd2.081/template index 79aad0940085..793de3fc3793 100644 --- a/srcpkgs/dmd2.081/template +++ b/srcpkgs/dmd2.081/template @@ -1,11 +1,11 @@ # Template file for 'dmd2.081' pkgname=dmd2.081 version=2.081.1 -revision=3 +revision=4 create_wrksrc=yes hostmakedepends="which" makedepends="dmd-bootstrap" -depends="libphobos2.081>=${version} gcc" +depends="gcc" short_desc="Digital Mars D compiler, 2.081" maintainer="Orphaned " license="BSL-1.0" @@ -68,40 +68,28 @@ do_install() { vbin generated/linux/release/$_archbits/dmd vinstall ${FILESDIR}/dmd.conf 644 etc + # note: dmd, druntime and phobos all share the same license + vlicense LICENSE.txt + vman generated/docs/man/man1/dmd.1 vman generated/docs/man/man5/dmd.conf.5 -} -dmd2.081-doc_package() { - short_desc="Documentation and sample code for D programming language" - replaces="dmd-docs>=0" + vmkdir usr/include/d - pkg_install() { - cd dmd2 + cp -r ${wrksrc}/phobos/{*.d,etc,std} ${PKGDESTDIR}/usr/include/d + vinstall ${wrksrc}/phobos/generated/linux/release/$_archbits/libphobos2.a 644 usr/lib libphobos2.a - vmkdir usr/share/doc/d - vcopy samples usr/share/doc/d - vcopy html usr/share/doc/d - - find ${PKGDESTDIR}/usr/share/doc/d -type f | xargs chmod 0644 + vmkdir usr/include/d/druntime + cp -r ${wrksrc}/druntime/import ${PKGDESTDIR}/usr/include/d/druntime + vinstall ${wrksrc}/druntime/generated/linux/release/$_archbits/libdruntime.a 644 usr/lib libdruntime.a +} - vlicense license.txt - } +dmd2.081-doc_package() { + short_desc="Documentation for D programming language (dummy package)" + build_style="meta" } libphobos2.081_package() { - short_desc+=" - standard library" - conflicts="dmd-bootstrap libphobos" - pkg_install() { - vinstall ${wrksrc}/druntime/generated/linux/release/$_archbits/libdruntime.a 644 usr/lib libdruntime.a - vinstall ${wrksrc}/phobos/generated/linux/release/$_archbits/libphobos2.a 644 usr/lib libphobos2.a - - vmkdir usr/include/d - cp -r ${wrksrc}/phobos/{*.d,etc,std} ${PKGDESTDIR}/usr/include/d - - vmkdir usr/include/d/druntime - cp -r ${wrksrc}/druntime/import ${PKGDESTDIR}/usr/include/d/druntime - - vlicense ${wrksrc}/druntime/LICENSE.txt - } + short_desc+=" - standard library (dummy package)" + build_style="meta" } From efbec0f200f030d2cc642a06ad5912dd9fa7f412 Mon Sep 17 00:00:00 2001 From: oreo639 Date: Sat, 17 Dec 2022 18:59:53 -0800 Subject: [PATCH 4/9] ldc: update to 1.30.0. --- common/shlibs | 9 ++- ...4260a848c8ebad5582e27ac1e09627cdfb17.patch | 57 +++++++++++++++++++ srcpkgs/ldc/template | 8 +-- 3 files changed, 65 insertions(+), 9 deletions(-) create mode 100644 srcpkgs/ldc/patches/54544260a848c8ebad5582e27ac1e09627cdfb17.patch diff --git a/common/shlibs b/common/shlibs index ba5c89ee3bad..11ef64e0cc7f 100644 --- a/common/shlibs +++ b/common/shlibs @@ -2189,11 +2189,10 @@ libFcitx5Config.so.6 libfcitx5-5.0.5_1 libFcitx5GClient.so.2 fcitx5-gtk-5.0.4_1 libFcitx5Qt5DBusAddons.so.1 fcitx5-qt5-5.0.3_1 libFcitx5Qt5WidgetsAddons.so.2 fcitx5-qt5-5.0.3_1 -libdruntime-ldc-debug-shared.so.98 ldc-runtime-1.28.0_1 -libdruntime-ldc-shared.so.98 ldc-runtime-1.28.0_1 -libphobos2-ldc-shared.so.98 ldc-runtime-1.28.0_1 -libphobos2-ldc-debug-shared.so.98 ldc-runtime-1.28.0_1 -libldc-jit.so.99 ldc-runtime-1.29.0_1 +libdruntime-ldc-debug-shared.so.100 ldc-runtime-1.30.0_1 +libdruntime-ldc-shared.so.100 ldc-runtime-1.30.0_1 +libphobos2-ldc-shared.so.100 ldc-runtime-1.30.0_1 +libphobos2-ldc-debug-shared.so.100 ldc-runtime-1.30.0_1 libmarblewidget-qt5.so.28 marble5-17.12.2_1 libastro.so.2 marble5-17.12.2_1 libparrot.so.6.9.0 parrot-6.9.0_1 diff --git a/srcpkgs/ldc/patches/54544260a848c8ebad5582e27ac1e09627cdfb17.patch b/srcpkgs/ldc/patches/54544260a848c8ebad5582e27ac1e09627cdfb17.patch new file mode 100644 index 000000000000..79694372bfaa --- /dev/null +++ b/srcpkgs/ldc/patches/54544260a848c8ebad5582e27ac1e09627cdfb17.patch @@ -0,0 +1,57 @@ +From 54544260a848c8ebad5582e27ac1e09627cdfb17 Mon Sep 17 00:00:00 2001 +From: Razvan Nitu +Date: Wed, 24 Aug 2022 13:54:15 +0300 +Subject: [PATCH] Port the fix for issue 23157 (#14378) + +--- + druntime/src/core/sys/posix/sys/socket.d | 36 ++++++++++++++++++++++-- + 1 file changed, 33 insertions(+), 3 deletions(-) + +diff --git a/druntime/src/core/sys/posix/sys/socket.d b/druntime/src/core/sys/posix/sys/socket.d +index 3a7b753adff..fc5dc5d1684 100644 +--- a/runtime/druntime/src/core/sys/posix/sys/socket.d ++++ b/runtime/druntime/src/core/sys/posix/sys/socket.d +@@ -188,10 +188,40 @@ version (linux) + + extern (D) inout(ubyte)* CMSG_DATA( return scope inout(cmsghdr)* cmsg ) pure nothrow @nogc { return cast(ubyte*)( cmsg + 1 ); } + +- private inout(cmsghdr)* __cmsg_nxthdr(inout(msghdr)*, inout(cmsghdr)*) pure nothrow @nogc; +- extern (D) inout(cmsghdr)* CMSG_NXTHDR(inout(msghdr)* msg, inout(cmsghdr)* cmsg) pure nothrow @nogc ++ version (CRuntime_Musl) + { +- return __cmsg_nxthdr(msg, cmsg); ++ extern (D) ++ { ++ private size_t __CMSG_LEN(inout(cmsghdr)* cmsg) pure nothrow @nogc ++ { ++ return (cmsg.cmsg_len + size_t.sizeof -1) & cast(size_t)(~(size_t.sizeof - 1)); ++ } ++ ++ private inout(cmsghdr)* __CMSG_NEXT(inout(cmsghdr)* cmsg) pure nothrow @nogc ++ { ++ return cmsg + __CMSG_LEN(cmsg); ++ } ++ ++ private inout(msghdr)* __MHDR_END(inout(msghdr)* mhdr) pure nothrow @nogc ++ { ++ return cast(inout(msghdr)*)(mhdr.msg_control + mhdr.msg_controllen); ++ } ++ ++ inout(cmsghdr)* CMSG_NXTHDR(inout(msghdr)* msg, inout(cmsghdr)* cmsg) pure nothrow @nogc ++ { ++ return cmsg.cmsg_len < cmsghdr.sizeof || ++ __CMSG_LEN(cmsg) + cmsghdr.sizeof >= __MHDR_END(msg) - cast(inout(msghdr)*)(cmsg) ++ ? cast(inout(cmsghdr)*) null : cast(inout(cmsghdr)*) __CMSG_NEXT(cmsg); ++ } ++ } ++ } ++ else ++ { ++ private inout(cmsghdr)* __cmsg_nxthdr(inout(msghdr)*, inout(cmsghdr)*) pure nothrow @nogc; ++ extern (D) inout(cmsghdr)* CMSG_NXTHDR(inout(msghdr)* msg, inout(cmsghdr)* cmsg) pure nothrow @nogc ++ { ++ return __cmsg_nxthdr(msg, cmsg); ++ } + } + + extern (D) inout(cmsghdr)* CMSG_FIRSTHDR( inout(msghdr)* mhdr ) pure nothrow @nogc diff --git a/srcpkgs/ldc/template b/srcpkgs/ldc/template index fec8a9c80452..99d22682ce7a 100644 --- a/srcpkgs/ldc/template +++ b/srcpkgs/ldc/template @@ -1,14 +1,14 @@ # Template file for 'ldc' pkgname=ldc -version=1.28.0 -revision=2 -reverts="1.29.0_1" +version=1.30.0 +revision=1 build_style=cmake configure_args=" -DINCLUDE_INSTALL_DIR=/usr/include/dlang/ldc -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=RelWithDebInfo -DBASH_COMPLETION_COMPLETIONSDIR=/usr/share/bash-completion + -DCOMPILE_D_MODULES_SEPARATELY=ON -DC_SYSTEM_LIBS='unwind;m;pthread;rt;dl'" conf_files="/etc/ldc2.conf" hostmakedepends="dmd llvm12 perl pkg-config" @@ -22,7 +22,7 @@ license="BSD-3-Clause, BSL-1.0" homepage="https://wiki.dlang.org/LDC" changelog="https://raw.githubusercontent.com/ldc-developers/ldc/master/CHANGELOG.md" distfiles="https://github.com/ldc-developers/ldc/releases/download/v${version}/ldc-${version}-src.tar.gz" -checksum=17fee8bb535bcb8cda0a45947526555c46c045f302a7349cc8711b254e54cf09 +checksum=fdbb376f08242d917922a6a22a773980217fafa310046fc5d6459490af23dacd nopie=yes nocross="dmd compilation fails on cross" # tests timeout on musl; also require unpackaged python3-lit From 3a823e372a9b8bba6028327c4513b6a239419830 Mon Sep 17 00:00:00 2001 From: oreo639 Date: Sat, 17 Dec 2022 19:29:18 -0800 Subject: [PATCH 5/9] gtkd: rebuild for ldc 1.30 --- srcpkgs/gtkd/template | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/srcpkgs/gtkd/template b/srcpkgs/gtkd/template index ee9c5b9dcbf6..e64a1f54fb96 100644 --- a/srcpkgs/gtkd/template +++ b/srcpkgs/gtkd/template @@ -1,7 +1,7 @@ # Template file for 'gtkd' pkgname=gtkd version=3.9.0 -revision=8 +revision=9 build_style=gnu-makefile make_build_args="LDFLAGS='-linker=bfd' DC=ldc2" make_build_target="shared-libs shared-gstreamer shared-vte shared-peas shared-gtkdgl" From 8408c02fa4c735bab7c55401581630ab1f220716 Mon Sep 17 00:00:00 2001 From: oreo639 Date: Sat, 17 Dec 2022 19:31:21 -0800 Subject: [PATCH 6/9] tilix: rebuild for ldc 1.30 --- srcpkgs/tilix/template | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/srcpkgs/tilix/template b/srcpkgs/tilix/template index 3bd2ef65dd3a..5689948babaa 100644 --- a/srcpkgs/tilix/template +++ b/srcpkgs/tilix/template @@ -1,7 +1,7 @@ # Template file for 'tilix' pkgname=tilix version=1.9.4 -revision=5 +revision=6 build_style=meson configure_args="-Db_lto=false" hostmakedepends="automake gettext-devel gdk-pixbuf glib-devel ldc po4a pkg-config From a68eedee969ea607305885300c154115232e7e22 Mon Sep 17 00:00:00 2001 From: oreo639 Date: Sat, 17 Dec 2022 19:32:34 -0800 Subject: [PATCH 7/9] onedrive: rebuild for ldc 1.30 --- srcpkgs/onedrive/template | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/srcpkgs/onedrive/template b/srcpkgs/onedrive/template index 0a5684cfc5ff..28163f334552 100644 --- a/srcpkgs/onedrive/template +++ b/srcpkgs/onedrive/template @@ -1,7 +1,7 @@ # Template file for 'onedrive' pkgname=onedrive version=2.4.13 -revision=3 +revision=4 build_style=gnu-configure configure_args="DC=ldc2" hostmakedepends="ldc pkg-config" From 75c248d97cd66b0320cbfbe32d9b549ae9d3ccf5 Mon Sep 17 00:00:00 2001 From: oreo639 Date: Sun, 18 Dec 2022 03:32:42 -0800 Subject: [PATCH 8/9] corecollector: fix build with libphobos 2.101 --- .../patches/fix-build-phobos-2-101.patch | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 srcpkgs/corecollector/patches/fix-build-phobos-2-101.patch diff --git a/srcpkgs/corecollector/patches/fix-build-phobos-2-101.patch b/srcpkgs/corecollector/patches/fix-build-phobos-2-101.patch new file mode 100644 index 000000000000..2d335cf6ac92 --- /dev/null +++ b/srcpkgs/corecollector/patches/fix-build-phobos-2-101.patch @@ -0,0 +1,14 @@ +--- a/source/corecollector/logging.d ++++ b/source/corecollector/logging.d +@@ -93,7 +93,10 @@ auto toSyslogLevel(LogLevel lv) @safe + /// Setup the logging with the supplied logging level. + void setupLogging(const LogLevel l, File logFile) @safe + { +- sharedLog = new SyslogLogger(l, logFile); ++ static if (__VERSION__ < 2101) ++ sharedLog = new SyslogLogger(l, logFile); ++ else ++ sharedLog = (() @trusted => cast(shared) new SyslogLogger(l, logFile))(); + } + + @safe unittest From d124bb178d4746021758753ee1e750104daa01c0 Mon Sep 17 00:00:00 2001 From: oreo639 Date: Sun, 18 Dec 2022 16:12:35 -0800 Subject: [PATCH 9/9] btdu: fix build with dmd 2.101 --- srcpkgs/btdu/template | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/srcpkgs/btdu/template b/srcpkgs/btdu/template index c2281f91aae8..e2c173e49344 100644 --- a/srcpkgs/btdu/template +++ b/srcpkgs/btdu/template @@ -2,7 +2,7 @@ pkgname=btdu version=0.4.1 revision=1 -# druntime does not implement ioctl on musl in dmd-2.098.0 +# fails to build on musl due to different argument types for ioctl # struct packing seems to differ on i686 archs and therefore d-btrfs fails archs=x86_64 hostmakedepends="dmd dub" @@ -15,6 +15,11 @@ distfiles="https://github.com/CyberShadow/btdu/archive/v${version}.tar.gz" checksum=265c63ee82067f6b5dc44b47c9ec58be5e13c654f31035c60a7e375ffa4082c9 nocross="dmd compilation fails on cross" +pre_configure() { + vsed -e 's/dependency "ae" version="==0.0.3184"/dependency "ae" version="==0.0.3228"/g' -i dub.sdl + vsed -e 's/"ae": "0.0.3184"/"ae": "0.0.3228"/g' -i dub.selections.json +} + do_build() { dub build -b release }