2017-03-12 22:45:40 +01:00
|
|
|
{ stdenv, fetchurl, unzip }:
|
2015-02-08 06:12:16 +01:00
|
|
|
|
2016-06-27 03:57:45 +02:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "objconv-${version}";
|
2018-11-20 12:48:23 +01:00
|
|
|
version = "2.51";
|
2015-02-08 06:12:16 +01:00
|
|
|
|
2017-03-12 22:45:40 +01:00
|
|
|
src = fetchurl {
|
|
|
|
# Versioned archive of objconv sources maintained by orivej.
|
|
|
|
url = "https://archive.org/download/objconv/${name}.zip";
|
2018-11-20 12:48:23 +01:00
|
|
|
sha256 = "0wp6ld9vk11f4nnkn56627zmlv9k5vafi99qa3yyn1pgcd61zcfs";
|
2015-02-08 06:12:16 +01:00
|
|
|
};
|
|
|
|
|
2017-03-12 22:45:40 +01:00
|
|
|
nativeBuildInputs = [ unzip ];
|
2015-02-08 06:12:16 +01:00
|
|
|
|
2017-03-12 22:45:40 +01: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 03:57:45 +02:00
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
2017-03-12 22:45:40 +01:00
|
|
|
description = "Object and executable file converter, modifier and disassembler";
|
2019-04-15 01:25:45 +02:00
|
|
|
homepage = https://www.agner.org/optimize/;
|
2016-06-27 03:57:45 +02:00
|
|
|
license = licenses.gpl2;
|
2017-03-12 22:45:40 +01:00
|
|
|
maintainers = with maintainers; [ orivej vrthra ];
|
|
|
|
platforms = platforms.unix;
|
2016-06-27 03:57:45 +02:00
|
|
|
};
|
2015-02-08 06:12:16 +01:00
|
|
|
}
|