Files
nixpkgs/pkgs/by-name/xm/xmlbeans/package.nix
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

51 lines
1.2 KiB
Nix

{
lib,
stdenv,
fetchzip,
jre_headless,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "xmlbeans";
version = "5.3.0-20241203";
src = fetchzip {
# old releases are deleted from the cdn
url = "https://web.archive.org/web/20250404194918/https://dlcdn.apache.org/poi/xmlbeans/release/bin/apache-xmlbeans-bin-5.3.0-20241203.zip";
hash = "sha256-AeV+s0VfBgb0YbsY6dNJeqcsguZhDmjuyqXT/415a3k=";
stripRoot = false;
};
postPatch = ''
cp -r apache-xmlbeans-*/* .
rm -r apache-xmlbeans-*
rm bin/*.cmd
substituteInPlace bin/dumpxsb \
--replace-fail 'echo `dirname $0`' ""
substituteInPlace bin/_setlib \
--replace-fail 'echo XMLBEANS_LIB=$XMLBEANS_LIB' ""
for file in bin/*; do
substituteInPlace $file \
--replace-warn "java " "${jre_headless}/bin/java "
done
'';
installPhase = ''
runHook preInstall
mkdir -p $out
chmod +x bin/*
cp -r bin/ lib/ $out/
runHook postInstall
'';
meta = {
description = "Java library for accessing XML by binding it to Java types";
homepage = "https://xmlbeans.apache.org/";
downloadPage = "https://dlcdn.apache.org/poi/xmlbeans/release/bin/";
license = lib.licenses.asl20;
maintainers = [ ];
};
})