nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
fork

Configure Feed

Select the types of activity you want to include in your feed.

at devShellTools-shell 68 lines 2.0 kB view raw
1{ 2 lib, 3 stdenv, 4 fetchzip, 5 texliveMedium, 6 buildDocs ? false, 7}: 8 9stdenv.mkDerivation (finalAttrs: { 10 pname = "asl"; 11 version = "142-bld232"; 12 13 src = 14 let 15 inherit (finalAttrs) pname version; 16 in 17 fetchzip { 18 name = "${pname}-${version}"; 19 url = "http://john.ccac.rwth-aachen.de:8000/ftp/as/source/c_version/asl-current-${version}.tar.bz2"; 20 hash = "sha256-Q50GzXBxFMhbt5s9OgHPNH4bdqz2hhEmTnMmKowVn2E="; 21 }; 22 23 outputs = [ 24 "out" 25 "doc" 26 "man" 27 ]; 28 29 nativeBuildInputs = lib.optionals buildDocs [ texliveMedium ]; 30 31 postPatch = 32 lib.optionalString (!buildDocs) '' 33 substituteInPlace Makefile --replace "all: binaries docs" "all: binaries" 34 '' 35 + lib.optionalString (stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isAarch64) '' 36 substituteInPlace sysdefs.h --replace "x86_64" "aarch64" 37 ''; 38 39 dontConfigure = true; 40 41 preBuild = '' 42 bindir="${placeholder "out"}/bin" \ 43 docdir="${placeholder "doc"}/share/doc/asl" \ 44 incdir="${placeholder "out"}/include/asl" \ 45 libdir="${placeholder "out"}/lib/asl" \ 46 mandir="${placeholder "man"}/share/man" \ 47 substituteAll ${./Makefile-nixos.def} Makefile.def 48 mkdir -p .objdir 49 ''; 50 51 meta = with lib; { 52 homepage = "http://john.ccac.rwth-aachen.de:8000/as/index.html"; 53 description = "Portable macro cross assembler"; 54 longDescription = '' 55 AS is a portable macro cross assembler for a variety of microprocessors 56 and -controllers. Though it is mainly targeted at embedded processors and 57 single-board computers, you also find CPU families in the target list that 58 are used in workstations and PCs. 59 ''; 60 license = licenses.gpl2Plus; 61 maintainers = with maintainers; [ ]; 62 platforms = platforms.unix; 63 }; 64}) 65# TODO: cross-compilation support 66# TODO: customize TeX input 67# TODO: report upstream about `mkdir -p .objdir/` 68# TODO: suggest upstream about building docs as an option