mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-03 12:23:02 +00:00
571c71e6f7
We are migrating packages that meet below requirements: 1. using `callPackage` 2. called path is a directory 3. overriding set is empty (`{ }`) 4. not containing path expressions other than relative path (to makenixpkgs-vet happy) 5. not referenced by nix files outside of the directory, other than`pkgs/top-level/all-packages.nix` 6. not referencing nix files outside of the directory 7. not referencing `default.nix` (since it's changed to `package.nix`) 8. `outPath` doesn't change after migration The tool is here: https://github.com/Aleksanaa/by-name-migrate.
56 lines
1.2 KiB
Nix
56 lines
1.2 KiB
Nix
{ lib
|
|
, stdenv
|
|
, fetchFromGitHub
|
|
, buildPackages
|
|
, which
|
|
, texi2html
|
|
, enableX11 ? true
|
|
, libX11, libXext, libXv, libpng
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "qemacs";
|
|
version = "6.3.2";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "qemacs";
|
|
repo = "qemacs";
|
|
rev = "0e90c181078f3d85d0d44d985d541184223668e1";
|
|
hash = "sha256-3kq89CoUi9ocR0q2SqYF8S/xNgBpInC4f2d/dJg/nEM=";
|
|
};
|
|
|
|
postPatch = ''
|
|
substituteInPlace Makefile --replace \
|
|
'$(INSTALL) -m 755 -s' \
|
|
'$(INSTALL) -m 755 -s --strip-program=${stdenv.cc.targetPrefix}strip'
|
|
'';
|
|
|
|
nativeBuildInputs = [ which texi2html ];
|
|
buildInputs = lib.optionals enableX11 [ libpng libX11 libXext libXv ];
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
configureFlags = [
|
|
"--cross-prefix=${stdenv.cc.targetPrefix}"
|
|
] ++ lib.optionals (!enableX11) [
|
|
"--disable-x11"
|
|
];
|
|
|
|
makeFlags = [
|
|
# is actually used as BUILD_CC
|
|
"HOST_CC=${buildPackages.stdenv.cc}/bin/cc"
|
|
"CC=${stdenv.cc.targetPrefix}cc"
|
|
];
|
|
|
|
preInstall = ''
|
|
mkdir -p $out/bin $out/man
|
|
'';
|
|
|
|
meta = with lib; {
|
|
homepage = "https://bellard.org/qemacs/";
|
|
description = "Very small but powerful UNIX editor";
|
|
license = licenses.mit;
|
|
maintainers = with maintainers; [ iblech ];
|
|
};
|
|
}
|