From 5321a509c02ca1962f16359d43694866c0a3eaf0 Mon Sep 17 00:00:00 2001 From: Lilac Date: Fri, 20 Dec 2024 16:11:08 +0000 Subject: [PATCH] quarto-cli: auto updated to 1.6.39-1 --- repo/quarto-cli/000_deno_1.41.diff | 12 --- repo/quarto-cli/000_pandoc_lua.diff | 19 +++++ repo/quarto-cli/001_deno_1.44.diff | 18 ++++ repo/quarto-cli/PKGBUILD | 122 ++++++++++++++-------------- 4 files changed, 100 insertions(+), 71 deletions(-) delete mode 100644 repo/quarto-cli/000_deno_1.41.diff create mode 100644 repo/quarto-cli/000_pandoc_lua.diff create mode 100644 repo/quarto-cli/001_deno_1.44.diff diff --git a/repo/quarto-cli/000_deno_1.41.diff b/repo/quarto-cli/000_deno_1.41.diff deleted file mode 100644 index 6e14f64..0000000 --- a/repo/quarto-cli/000_deno_1.41.diff +++ /dev/null @@ -1,12 +0,0 @@ -diff -ur quarto-cli-1.4.551.orig/src/project/types/website/website-search.ts quarto-cli-1.4.551/src/project/types/website/website-search.ts ---- quarto-cli-1.4.551.orig/src/project/types/website/website-search.ts 2024-03-06 11:25:25.000000000 +1300 -+++ quarto-cli-1.4.551/src/project/types/website/website-search.ts 2024-03-06 22:04:38.498170207 +1300 -@@ -8,7 +8,7 @@ - import { basename, join, relative } from "path/mod.ts"; - - // currently not building the index here so not using fuse --// @deno-types="fuse/dist/fuse.d.ts" -+// - // import Fuse from "fuse/dist/fuse.esm.min.js"; - - import { DOMParser, Element, initDenoDom } from "../../../core/deno-dom.ts"; diff --git a/repo/quarto-cli/000_pandoc_lua.diff b/repo/quarto-cli/000_pandoc_lua.diff new file mode 100644 index 0000000..183fbe9 --- /dev/null +++ b/repo/quarto-cli/000_pandoc_lua.diff @@ -0,0 +1,19 @@ +--- quarto-cli-1.5.55/src/command/render/pandoc.ts.original 2024-07-27 22:49:08.770086319 +1200 ++++ quarto-cli-1.5.55/src/command/render/pandoc.ts 2024-07-27 22:49:23.266719276 +1200 +@@ -235,16 +235,6 @@ + pandocEnv["QUARTO_TRACE_FILTERS"] = traceFilters + traceCountSuffix; + } + } +- +- // https://github.com/quarto-dev/quarto-cli/issues/8274 +- // do not use the default LUA_CPATH, as it will cause pandoc to +- // load the system lua libraries, which may not be compatible with +- // the lua version we are using +- if (Deno.env.get("QUARTO_LUA_CPATH") !== undefined) { +- pandocEnv["LUA_CPATH"] = getEnv("QUARTO_LUA_CPATH"); +- } else { +- pandocEnv["LUA_CPATH"] = ""; +- } + }; + + // compute cwd for render diff --git a/repo/quarto-cli/001_deno_1.44.diff b/repo/quarto-cli/001_deno_1.44.diff new file mode 100644 index 0000000..6c5a424 --- /dev/null +++ b/repo/quarto-cli/001_deno_1.44.diff @@ -0,0 +1,18 @@ +--- quarto-cli-1.4.556.original/src/core/deno-dom.ts 2024-06-27 08:15:10.000000000 +1200 ++++ quarto-cli-1.4.556/src/core/deno-dom.ts 2024-06-27 10:02:37.434536479 +1200 +@@ -98,13 +98,13 @@ + const genericParse = ( + parser: ( + srcBuf: Uint8Array, +- srcLength: number, ++ srcLength: bigint, + returnBuf: Uint8Array, + ) => void, + srcHtml: string, + ): string => { + const encodedHtml = utf8Encoder.encode(srcHtml); +- parser(encodedHtml, encodedHtml.length, returnBufSizeLen); ++ parser(encodedHtml, BigInt(encodedHtml.length), returnBufSizeLen); + + const outBufSize = Number( + new DataView(returnBufSizeLenRaw).getBigUint64(0, !isBigEndian), diff --git a/repo/quarto-cli/PKGBUILD b/repo/quarto-cli/PKGBUILD index abb4c6c..a12e48a 100644 --- a/repo/quarto-cli/PKGBUILD +++ b/repo/quarto-cli/PKGBUILD @@ -1,85 +1,89 @@ -# Maintainer: Aleksandr Beliaev +# Maintainer: Harriet O'Brien +# Contributor: Aleksandr Beliaev pkgname=quarto-cli -pkgver=1.4.555 +pkgver=1.6.39 pkgrel=1 -_pkgbasename=quarto-cli -_denodomver="0.1.35-alpha-artifacts" +#_pkgbasename=quarto-cli +_denodomver="0.1.41-alpha-artifacts" +_denover="2.0.4-1" +_deno_commit=b7c282d _deno_arch="deno-x86_64-unknown-linux-gnu" -pkgdesc="Quarto is an open-source scientific and technical publishing system built on [Pandoc](https://pandoc.org)." -arch=('x86_64' 'i686') -depends=('nodejs' 'deno' 'dart-sass' 'esbuild' 'pandoc' 'lua-lpeg' 'typst') -makedepends=('git' 'npm' 'rust') +pkgdesc="Quarto is an open-source scientific and technical publishing system built on [Pandoc](https://pandoc.org)" +arch=('x86_64') +depends=("nodejs" + "deno" + "dart-sass" + "esbuild" + "pandoc" + "lua-lpeg" + "typst") +makedepends=("git" + "npm" + "rust") url="https://quarto.org/" -license=('MIT') +license=("MIT") provides=("quarto") -conflicts=('quarto-cli-bin' 'quarto-cli-pre-release' 'quarto-cli-bin-pre-release' 'quarto-cli-git') +conflicts=("quarto-cli-bin" + "quarto-cli-pre-release" + "quarto-cli-bin-pre-release" + "quarto-cli-git") options=(!strip) - -source=("${_pkgbasename}-${pkgver}.tar.gz::https://github.com/quarto-dev/quarto-cli/archive/refs/tags/v${pkgver}.tar.gz" - "https://github.com/b-fuze/deno-dom/archive/refs/tags/v${_denodomver}.tar.gz" - "000_deno_1.41.diff" - ) - -sha256sums=('0e8ca6e1d5578011a74339890f0b6a2a7cbb0f822f24e0fbdfd4285ab04fab4d' - '14fb042a6912041b9fda91fd643cf278764d075bc9539aa1e107475915cd896c' - 'd09e82634e6b64359c54d3a99b8abb4503cea3c62ef30b46d02ffcfde718d36c') -prepare() { - cd "${srcdir}/${_pkgbasename}-${pkgver}" - patch -p1 < ../000_deno_1.41.diff -} +source=("https://github.com/quarto-dev/$pkgname/releases/download/v$pkgver/$provides-$pkgver-linux-amd64.tar.gz" + "https://archive.archlinux.org/packages/d/deno/deno-$_denover-x86_64.pkg.tar.zst" + "https://github.com/b-fuze/deno-dom/archive/refs/tags/v$_denodomver.tar.gz" + "000_pandoc_lua.diff") +sha256sums=("d797c796713a57c14d8115f49a45d626a16478697096a0421f2d2d980e5f9d4a" + "897c81da3ca3cb1c236f111d237abfcc973cc0e7a4089ca3f21997e17cb0a9a2" + "5ab1a73e73b9edf9d2c81e655658d970e6212497a5368d8f0bc8613bbdf8d91d" + "0f27dff1e1b16e4f2f21c43b838aaae18bf9f82339eb65878b24de128f89450f") build() { - cd "${srcdir}/${_pkgbasename}-${pkgver}" - source configuration - source "${srcdir}/${_pkgbasename}-${pkgver}/package/src/set_package_paths.sh" - export QUARTO_VERSION=${pkgver} - export QUARTO_VENDOR_BINARIES='false' - export QUARTO_NO_SYMLINK='true' - export DENO_DOM_PLUGIN="${srcdir}/deno-dom-${_denodomver}/target/release/libplugin.so" + cd "$srcdir/$provides-$pkgver/" + # source configuration + # source "$srcdir/$provides-$pkgver/pkg/src/set_package_paths.sh" + export QUARTO_VERSION=$pkgver + export QUARTO_VENDOR_BINARIES="false" + export QUARTO_NO_SYMLINK="true" + export DENO_DOM_PLUGIN="$srcdir/deno-dom-$_denodomver/target/release/libplugin.so" if [ -z "$QUARTO_DENO" ]; then export QUARTO_DENO=$SCRIPT_PATH/../dist/bin/tools/deno fi - # keep deno cache directory out of default $home/.cache/deno - export DENO_DIR="${srcdir}/${_pkgbasename}-${pkgver}/package/cache" + # Keep deno cache directory out of default $home/.cache/deno + export DENO_DIR="$srcdir/$provides-$pkgver/package/cache" # Rust optimizations - export CARGO_HOME="${srcdir}/${_pkgbasename}-${pkgver}/.cargo" + export CARGO_HOME="$srcdir/$provides-$pkgver/.cargo" export RUSTFLAGS="-C strip=symbols" - mkdir -p package/dist/bin/tools/${arch}/dart-sass - mkdir -p package/dist/bin/tools/${arch}/deno_dom - cp /usr/bin/deno package/dist/bin/tools - ln -sfT /usr/bin/pandoc package/dist/bin/tools/${arch}/pandoc - ln -sfT /usr/bin/sass package/dist/bin/tools/${arch}/dart-sass/sass - ln -sfT /usr/bin/esbuild package/dist/bin/tools/${arch}/esbuild + mkdir -p package/dist/bin/tools/$arch/dart-sass + mkdir -p package/dist/bin/tools/$arch/deno_dom + cp $srcdir/usr/bin/deno package/dist/bin/tools + ln -sfT /usr/bin/pandoc package/dist/bin/tools/$arch/pandoc + ln -sfT /usr/bin/sass package/dist/bin/tools/$arch/dart-sass/sass + ln -sfT /usr/bin/esbuild package/dist/bin/tools/$arch/esbuild msg "Building Deno Stdlib..." - cd "${srcdir}/deno-dom-${_denodomver}" + cd "$srcdir/deno-dom-$_denodomver" cargo build --release - cd "${srcdir}/${_pkgbasename}-${pkgver}" - # unsure if it's needed at all - # package/dist/bin/tools/deno run --allow-all package/src/common/create-deno-config.ts > deno.jsonc - cd package/src - #../dist/bin/tools/deno run --unstable --allow-env --allow-read --allow-write --allow-run --allow-net --allow-ffi --importmap=../../src/dev_import_map.json bld.ts configure --log-level info - ../dist/bin/tools/deno run --unstable --allow-env --allow-read --allow-write --allow-run --allow-net --allow-ffi --importmap=../../src/import_map.json bld.ts prepare-dist --log-level info - + cd "$srcdir/$provides-$pkgver/package/dist/bin/tools" + deno run --unstable --allow-env --allow-read --allow-write --allow-run --allow-net --allow-ffi --importmap=../../../../share/conf/jsx-import-map.json ../../../../share/conf/jsx-runtime.ts prepare-dist --log-level info } package() { - cd "${srcdir}/${_pkgbasename}-${pkgver}" - mkdir -p package/pkg-working/bin/tools/${arch}/dart-sass - mkdir -p package/pkg-working/bin/tools/${arch}/deno_dom - cp "${srcdir}/deno-dom-${_denodomver}/target/release/libplugin.so" "${srcdir}/${_pkgbasename}-${pkgver}/package/pkg-working/bin/tools/${arch}/deno_dom" + cd "$srcdir/$provides-$pkgver" + mkdir -p package/pkg-working/bin/tools/$arch/dart-sass + mkdir -p package/pkg-working/bin/tools/$arch/deno_dom + cp "$srcdir/deno-dom-$_denodomver/target/release/libplugin.so" "$srcdir/$provides-$pkgver/package/pkg-working/bin/tools/$arch/deno_dom" # keep legacy pandoc location, see https://github.com/quarto-dev/quarto/issues/237 ln -sfT /usr/bin/pandoc package/pkg-working/bin/tools/pandoc - ln -sfT /usr/bin/pandoc package/pkg-working/bin/tools/${arch}/pandoc - ln -sfT /usr/bin/deno package/pkg-working/bin/tools/${arch}/deno - ln -sfT /usr/bin/sass package/pkg-working/bin/tools/${arch}/dart-sass/sass - ln -sfT /usr/bin/esbuild package/pkg-working/bin/tools/${arch}/esbuild - ln -sfT /usr/bin/typst package/pkg-working/bin/tools/${arch}/typst + ln -sfT /usr/bin/pandoc package/pkg-working/bin/tools/$arch/pandoc + ln -sfT /usr/bin/deno package/pkg-working/bin/tools/$arch/deno + ln -sfT /usr/bin/sass package/pkg-working/bin/tools/$arch/dart-sass/sass + ln -sfT /usr/bin/esbuild package/pkg-working/bin/tools/$arch/esbuild + ln -sfT /usr/bin/typst package/pkg-working/bin/tools/$arch/typst - install -d ${pkgdir}/usr/{bin,lib/${_pkgbasename}/{bin,share}} - cp -R package/pkg-working/* "${pkgdir}/usr/lib/${_pkgbasename}" - ln -sf "/usr/lib/${_pkgbasename}/bin/quarto" "$pkgdir/usr/bin/quarto" + install -d $pkgdir/usr/{bin,lib/$pkgname/{bin,share}} + cp -R package/pkg-working/* "$pkgdir/usr/lib/$pkgname" + ln -sf "/usr/lib/$pkgname/bin/quarto" "$pkgdir/usr/bin/quarto" }