mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-06 04:53:27 +00:00
4f0dadbf38
After final improvements to the official formatter implementation, this commit now performs the first treewide reformat of Nix files using it. This is part of the implementation of RFC 166. Only "inactive" files are reformatted, meaning only files that aren't being touched by any PR with activity in the past 2 months. This is to avoid conflicts for PRs that might soon be merged. Later we can do a full treewide reformat to get the rest, which should not cause as many conflicts. A CI check has already been running for some time to ensure that new and already-formatted files are formatted, so the files being reformatted here should also stay formatted. This commit was automatically created and can be verified using nix-builda08b3a4d19
.tar.gz \ --argstr baseRevb32a094368
result/bin/apply-formatting $NIXPKGS_PATH
81 lines
1.8 KiB
Nix
81 lines
1.8 KiB
Nix
{
|
|
lib,
|
|
stdenv,
|
|
fetchFromGitHub,
|
|
ant,
|
|
jdk8, # the build script wants JAVA 8 for compilation
|
|
jre, # version can be >= 8 (latest version by default)
|
|
makeWrapper,
|
|
makeDesktopItem,
|
|
copyDesktopItems,
|
|
stripJavaArchivesHook,
|
|
}:
|
|
|
|
stdenv.mkDerivation (finalAttrs: {
|
|
pname = "jpsxdec";
|
|
version = "2.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "m35";
|
|
repo = "jpsxdec";
|
|
rev = "v${finalAttrs.version}";
|
|
hash = "sha256-PZOc5mpnUiUyydWyfZjWuPG4w+tRd6WLJ6YQMqu/95I=";
|
|
};
|
|
|
|
sourceRoot = "${finalAttrs.src.name}/jpsxdec";
|
|
|
|
nativeBuildInputs = [
|
|
ant
|
|
jdk8
|
|
makeWrapper
|
|
copyDesktopItems
|
|
stripJavaArchivesHook
|
|
];
|
|
|
|
buildPhase = ''
|
|
runHook preBuild
|
|
ant release
|
|
runHook postBuild
|
|
'';
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
|
|
mkdir -p $out/share/jpsxdec
|
|
mv _ant/release/{doc,*.jar} $out/share/jpsxdec
|
|
install -Dm644 src/jpsxdec/gui/icon48.png $out/share/pixmaps/jpsxdec.png
|
|
|
|
makeWrapper ${jre}/bin/java $out/bin/jpsxdec \
|
|
--add-flags "-jar $out/share/jpsxdec/jpsxdec.jar"
|
|
|
|
runHook postInstall
|
|
'';
|
|
|
|
desktopItems = [
|
|
(makeDesktopItem {
|
|
name = "jpsxdec";
|
|
exec = "jpsxdec";
|
|
icon = "jpsxdec";
|
|
desktopName = "jPSXdec";
|
|
comment = finalAttrs.meta.description;
|
|
categories = [
|
|
"AudioVideo"
|
|
"Utility"
|
|
];
|
|
})
|
|
];
|
|
|
|
meta = with lib; {
|
|
changelog = "https://github.com/m35/jpsxdec/blob/${finalAttrs.src.rev}/jpsxdec/doc/CHANGES.txt";
|
|
description = "Cross-platform PlayStation 1 audio and video converter";
|
|
homepage = "https://jpsxdec.blogspot.com/";
|
|
license = {
|
|
url = "https://raw.githubusercontent.com/m35/jpsxdec/${finalAttrs.src.rev}/.github/LICENSE.md";
|
|
free = true;
|
|
};
|
|
mainProgram = "jpsxdec";
|
|
maintainers = with maintainers; [ zane ];
|
|
platforms = platforms.all;
|
|
};
|
|
})
|