1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-12-22 14:47:06 +00:00
nixpkgs/pkgs/development/tools/misc/objconv/default.nix

40 lines
972 B
Nix
Raw Normal View History

{ lib, stdenv, fetchurl, unzip }:
2015-02-08 05:12:16 +00:00
2016-06-27 02:57:45 +01:00
stdenv.mkDerivation rec {
pname = "objconv";
2020-08-29 15:06:34 +01:00
version = "2.52";
2015-02-08 05:12:16 +00:00
2017-03-12 21:45:40 +00:00
src = fetchurl {
# Versioned archive of objconv sources maintained by orivej.
url = "https://archive.org/download/objconv/${pname}-${version}.zip";
2020-08-29 15:06:34 +01:00
sha256 = "0r117r7yvqvvdgwgwxpkyzi6p5nm0xb6p67wvkmvggm9fdyl3z8v";
2015-02-08 05:12:16 +00:00
};
2017-03-12 21:45:40 +00:00
nativeBuildInputs = [ unzip ];
2015-02-08 05:12:16 +00:00
2017-03-12 21:45:40 +00:00
outputs = [ "out" "doc" ];
unpackPhase = ''
mkdir -p "$name"
cd "$name"
unpackFile "$src"
unpackFile source.zip
'';
buildPhase = "c++ -o objconv -O2 *.cpp";
installPhase = ''
mkdir -p $out/bin $out/doc/objconv
mv objconv $out/bin
mv objconv-instructions.pdf $out/doc/objconv
'';
2016-06-27 02:57:45 +01:00
meta = with lib; {
2017-03-12 21:45:40 +00:00
description = "Object and executable file converter, modifier and disassembler";
homepage = "https://www.agner.org/optimize/";
2016-06-27 02:57:45 +01:00
license = licenses.gpl2;
2017-03-12 21:45:40 +00:00
maintainers = with maintainers; [ orivej vrthra ];
platforms = platforms.unix;
2016-06-27 02:57:45 +01:00
};
2015-02-08 05:12:16 +00:00
}