mirror of
https://github.com/SebastianWendel/nixpkgs.git
synced 2024-09-20 20:39:04 +02:00
go-lib: init at 5.8.27
s
This commit is contained in:
parent
4bb21228e5
commit
732cfc7947
|
@ -3,6 +3,15 @@ let
|
|||
packages = self:
|
||||
let
|
||||
inherit (self) callPackage;
|
||||
|
||||
replaceAll = x: y: ''
|
||||
echo Replacing "${x}" to "${y}":
|
||||
for file in $(grep -rl "${x}"); do
|
||||
echo -- $file
|
||||
substituteInPlace $file \
|
||||
--replace "${x}" "${y}"
|
||||
done
|
||||
'';
|
||||
in {
|
||||
#### LIBRARIES
|
||||
dtkcommon = callPackage ./library/dtkcommon { };
|
||||
|
@ -25,6 +34,9 @@ let
|
|||
deepin-editor = callPackage ./apps/deepin-editor { };
|
||||
deepin-terminal = callPackage ./apps/deepin-terminal { };
|
||||
|
||||
#### Go Packages
|
||||
go-lib = callPackage ./go-package/go-lib { inherit replaceAll; };
|
||||
|
||||
#### ARTWORK
|
||||
dde-account-faces = callPackage ./artwork/dde-account-faces { };
|
||||
deepin-icon-theme = callPackage ./artwork/deepin-icon-theme { };
|
||||
|
|
45
pkgs/desktops/deepin/go-package/go-lib/default.nix
Normal file
45
pkgs/desktops/deepin/go-package/go-lib/default.nix
Normal file
|
@ -0,0 +1,45 @@
|
|||
{ stdenv
|
||||
, lib
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, replaceAll
|
||||
, runtimeShell
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "go-lib";
|
||||
version = "5.8.27";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "linuxdeepin";
|
||||
repo = pname;
|
||||
rev = version;
|
||||
sha256 = "sha256-ZV5zWu7UvNKVcVo79/iKMhF4H09rGyDCvEL61H05lZc=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
(fetchpatch {
|
||||
name = "fix_IsDir_for_symlink";
|
||||
url = "https://github.com/linuxdeepin/go-lib/commit/79239904679dc70a11e1ac8e65670afcfdd7c122.patch";
|
||||
sha256 = "sha256-RsN9hK26i/W6P/+e1l1spCLdlgIEWTehhIW6POBOvW4=";
|
||||
})
|
||||
];
|
||||
|
||||
postPatch = replaceAll "/bin/sh" "${runtimeShell}";
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
mkdir -p $out/share/gocode/src/github.com/linuxdeepin/go-lib
|
||||
cp -a * $out/share/gocode/src/github.com/linuxdeepin/go-lib
|
||||
rm -r $out/share/gocode/src/github.com/linuxdeepin/go-lib/debian
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Library containing many useful go routines for things such as glib, gettext, archive, graphic, etc";
|
||||
homepage = "https://github.com/linuxdeepin/go-lib";
|
||||
license = licenses.gpl3Plus;
|
||||
platforms = platforms.linux;
|
||||
maintainers = teams.deepin.members;
|
||||
};
|
||||
}
|
Loading…
Reference in a new issue