Add UCRT and fix timestamp

Add the UCRT build
Add support for UCRT on AArch64, but still need more help getting that
built with the zlib build failure
Convert to a run command, instead of a build command, so that the
timestamp of the tarball is more accurate
This commit is contained in:
Greg Hellings
2025-02-06 14:38:55 -06:00
parent cc62360e67
commit 570aa6ae52
3 changed files with 50 additions and 56 deletions
+9 -4
View File
@@ -20,13 +20,16 @@ build:
needs: needs:
- job: check - job: check
artifacts: true artifacts: true
parallel:
matrix:
- ARCH: [x86, ucrt]
tags: tags:
- nix - nix
script: script:
- nix build -L - nix build -L ".#${ARCH}"
- URL=$CI_API_V4_URL/projects/$CI_PROJECT_ID/packages/generic/sword-utils/$TAG/sword-$TAG.tar.xz - URL=$CI_API_V4_URL/projects/$CI_PROJECT_ID/packages/generic/sword-utils/$TAG/sword-${ARCH}-${TAG}.tar.xz
- 'curl -i --fail-with-body --header "JOB-TOKEN: $CI_JOB_TOKEN" --upload-file ./result/sword.tar.xz "${URL}"' - 'curl -i --fail-with-body --header "JOB-TOKEN: $CI_JOB_TOKEN" --upload-file ./result/sword.tar.xz "${URL}"'
- echo "X86_TARBALL=${URL}" > build.env - echo "${ARCH}_TARBALL=${URL}" > build.env
artifacts: artifacts:
reports: reports:
dotenv: build.env dotenv: build.env
@@ -42,9 +45,11 @@ build:
script: echo "Tagging as released" script: echo "Tagging as released"
release: release:
name: Release $TAG name: Release $TAG
tag_name: '$TAG' tag_name: "$TAG"
description: Automatic SWORD utils build for Windows description: Automatic SWORD utils build for Windows
assets: assets:
links: links:
- name: Windows (x86-64) release - name: Windows (x86-64) release
url: "${X86_TARBALL}" url: "${X86_TARBALL}"
- name: Windows (x86-64) release with UCRT
url: "${UCRT_TARBALL}"
Generated
+14 -31
View File
@@ -21,11 +21,11 @@
"nixpkgs-lib": "nixpkgs-lib" "nixpkgs-lib": "nixpkgs-lib"
}, },
"locked": { "locked": {
"lastModified": 1733312601, "lastModified": 1738453229,
"narHash": "sha256-4pDvzqnegAfRkPwO3wmwBhVi/Sye1mzps0zHWYnP88c=", "narHash": "sha256-7H9XgNiGLKN1G1CgRh0vUL4AheZSYzPm+zmZ7vxbJdo=",
"owner": "hercules-ci", "owner": "hercules-ci",
"repo": "flake-parts", "repo": "flake-parts",
"rev": "205b12d8b7cd4802fbcb8e8ef6a0f1408781a4f9", "rev": "32ea77a06711b758da0ad9bd6a844c5740a87abd",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -74,15 +74,14 @@
"inputs": { "inputs": {
"flake-compat": "flake-compat", "flake-compat": "flake-compat",
"gitignore": "gitignore", "gitignore": "gitignore",
"nixpkgs": "nixpkgs", "nixpkgs": "nixpkgs"
"nixpkgs-stable": "nixpkgs-stable"
}, },
"locked": { "locked": {
"lastModified": 1734425854, "lastModified": 1737465171,
"narHash": "sha256-nzE5UbJ41aPEKf8R2ZFYtLkqPmF7EIUbNEdHMBLg0Ig=", "narHash": "sha256-R10v2hoJRLq8jcL4syVFag7nIGE7m13qO48wRIukWNg=",
"owner": "cachix", "owner": "cachix",
"repo": "git-hooks.nix", "repo": "git-hooks.nix",
"rev": "0ddd26d0925f618c3a5d85a4fa5eb1e23a09491d", "rev": "9364dc02281ce2d37a1f55b6e51f7c0f65a75f17",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -109,39 +108,23 @@
}, },
"nixpkgs-lib": { "nixpkgs-lib": {
"locked": { "locked": {
"lastModified": 1733096140, "lastModified": 1738452942,
"narHash": "sha256-1qRH7uAUsyQI7R1Uwl4T+XvdNv778H0Nb5njNrqvylY=", "narHash": "sha256-vJzFZGaCpnmo7I6i416HaBLpC+hvcURh/BQwROcGIp8=",
"type": "tarball", "type": "tarball",
"url": "https://github.com/NixOS/nixpkgs/archive/5487e69da40cbd611ab2cadee0b4637225f7cfae.tar.gz" "url": "https://github.com/NixOS/nixpkgs/archive/072a6db25e947df2f31aab9eccd0ab75d5b2da11.tar.gz"
}, },
"original": { "original": {
"type": "tarball", "type": "tarball",
"url": "https://github.com/NixOS/nixpkgs/archive/5487e69da40cbd611ab2cadee0b4637225f7cfae.tar.gz" "url": "https://github.com/NixOS/nixpkgs/archive/072a6db25e947df2f31aab9eccd0ab75d5b2da11.tar.gz"
}
},
"nixpkgs-stable": {
"locked": {
"lastModified": 1730741070,
"narHash": "sha256-edm8WG19kWozJ/GqyYx2VjW99EdhjKwbY3ZwdlPAAlo=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "d063c1dd113c91ab27959ba540c0d9753409edf3",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-24.05",
"repo": "nixpkgs",
"type": "github"
} }
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1734435836, "lastModified": 1738797219,
"narHash": "sha256-kMBQ5PRiFLagltK0sH+08aiNt3zGERC2297iB6vrvlU=", "narHash": "sha256-KRwX9Z1XavpgeSDVM/THdFd6uH8rNm/6R+7kIbGa+2s=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "4989a246d7a390a859852baddb1013f825435cee", "rev": "1da52dd49a127ad74486b135898da2cef8c62665",
"type": "github" "type": "github"
}, },
"original": { "original": {
+17 -11
View File
@@ -31,12 +31,14 @@
]; ];
perSystem = perSystem =
{ pkgs, self', ... }@inputs': { pkgs, self', ... }@inputs':
let
in
{ {
_module.args.pkgs = import inputs.nixpkgs { _module.args.pkgs = import inputs.nixpkgs {
inherit (inputs') system; inherit (inputs') system;
overlays = [ ]; overlays = [
(_: prev: {
icu = prev.icu76;
})
];
}; };
devShells.default = pkgs.mkShell { devShells.default = pkgs.mkShell {
# These will just be available # These will just be available
@@ -68,7 +70,9 @@
# This is not special, this is just flakes # This is not special, this is just flakes
packages = packages =
let let
win = pkgs.pkgsCross.mingwW64; tar =
win:
let
svnSword = ( svnSword = (
win.sword.overrideAttrs { win.sword.overrideAttrs {
src = pkgs.fetchsvn { src = pkgs.fetchsvn {
@@ -79,16 +83,18 @@
} }
); );
in in
{ pkgs.writeShellScriptBin "package-sword" ''
default = pkgs.stdenv.mkDerivation { out=$(pwd)
name = "mingw-sword";
phases = [ "installPhase" ];
installPhase = ''
mkdir -p $out
pushd ${svnSword} pushd ${svnSword}
${pkgs.gnutar}/bin/tar cvhaf $out/sword.tar.xz * ${pkgs.gnutar}/bin/tar cvhaf $out/sword.tar.xz *
''; '';
}; in
with pkgs.pkgsCross;
{
default = tar mingwW64;
x86 = tar mingwW64;
ucrt = tar ucrt64;
ucrtAarch = tar ucrtAarch64;
}; };
}; };
}; };