mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-12 20:55:31 +03:00
emacs.pkgs.jinx: build .so file
Co-authored-by: Jian Lin <75130626+jian-lin@users.noreply.github.com>
This commit is contained in:
parent
aaea1aaea9
commit
1b5ba6d5bd
2 changed files with 52 additions and 0 deletions
|
@ -106,6 +106,31 @@ self: let
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
|
jinx = super.jinx.overrideAttrs (old: {
|
||||||
|
dontUnpack = false;
|
||||||
|
|
||||||
|
nativeBuildInputs = (old.nativeBuildInputs or [ ]) ++ [
|
||||||
|
pkgs.pkg-config
|
||||||
|
];
|
||||||
|
|
||||||
|
buildInputs = (old.buildInputs or [ ]) ++ [ pkgs.enchant2 ];
|
||||||
|
|
||||||
|
postBuild = ''
|
||||||
|
NIX_CFLAGS_COMPILE="$($PKG_CONFIG --cflags enchant-2) $NIX_CFLAGS_COMPILE"
|
||||||
|
$CC -shared -o jinx-mod.so jinx-mod.c -lenchant-2
|
||||||
|
'';
|
||||||
|
|
||||||
|
postInstall = (old.postInstall or "") + "\n" + ''
|
||||||
|
outd=$out/share/emacs/site-lisp/elpa/jinx-*
|
||||||
|
install -m444 -t $outd jinx-mod.so
|
||||||
|
rm $outd/jinx-mod.c $outd/emacs-module.h
|
||||||
|
'';
|
||||||
|
|
||||||
|
meta = old.meta // {
|
||||||
|
maintainers = [ lib.maintainers.DamienCassou ];
|
||||||
|
};
|
||||||
|
});
|
||||||
|
|
||||||
plz = super.plz.overrideAttrs (
|
plz = super.plz.overrideAttrs (
|
||||||
old: {
|
old: {
|
||||||
dontUnpack = false;
|
dontUnpack = false;
|
||||||
|
|
|
@ -314,6 +314,33 @@ let
|
||||||
|
|
||||||
ivy-rtags = fix-rtags super.ivy-rtags;
|
ivy-rtags = fix-rtags super.ivy-rtags;
|
||||||
|
|
||||||
|
jinx = super.jinx.overrideAttrs (old: {
|
||||||
|
nativeBuildInputs = (old.nativeBuildInputs or [ ]) ++ [
|
||||||
|
pkgs.pkg-config
|
||||||
|
];
|
||||||
|
|
||||||
|
buildInputs = (old.buildInputs or [ ]) ++ [ pkgs.enchant2 ];
|
||||||
|
|
||||||
|
postBuild = ''
|
||||||
|
pushd working/jinx
|
||||||
|
NIX_CFLAGS_COMPILE="$($PKG_CONFIG --cflags enchant-2) $NIX_CFLAGS_COMPILE"
|
||||||
|
$CC -shared -o jinx-mod.so jinx-mod.c -lenchant-2
|
||||||
|
popd
|
||||||
|
'';
|
||||||
|
|
||||||
|
postInstall = (old.postInstall or "") + "\n" + ''
|
||||||
|
pushd source
|
||||||
|
outd=$(echo $out/share/emacs/site-lisp/elpa/jinx-*)
|
||||||
|
install -m444 --target-directory=$outd jinx-mod.so
|
||||||
|
rm $outd/jinx-mod.c $outd/emacs-module.h
|
||||||
|
popd
|
||||||
|
'';
|
||||||
|
|
||||||
|
meta = old.meta // {
|
||||||
|
maintainers = [ lib.maintainers.DamienCassou ];
|
||||||
|
};
|
||||||
|
});
|
||||||
|
|
||||||
libgit = super.libgit.overrideAttrs(attrs: {
|
libgit = super.libgit.overrideAttrs(attrs: {
|
||||||
nativeBuildInputs = (attrs.nativeBuildInputs or []) ++ [ pkgs.cmake ];
|
nativeBuildInputs = (attrs.nativeBuildInputs or []) ++ [ pkgs.cmake ];
|
||||||
buildInputs = attrs.buildInputs ++ [ pkgs.libgit2 ];
|
buildInputs = attrs.buildInputs ++ [ pkgs.libgit2 ];
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue