Skip to content

Commit

Permalink
🐛 Don't patch code about glib
Browse files Browse the repository at this point in the history
  • Loading branch information
Freed-Wu committed Nov 6, 2024
1 parent 7dbb991 commit 82783be
Showing 1 changed file with 24 additions and 11 deletions.
35 changes: 24 additions & 11 deletions pkgs/tools/misc/tmux-rime/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -10,27 +10,40 @@
stdenv.mkDerivation rec {
pname = "tmux-rime";
version = "0.0.3";
src = fetchFromGitHub {
owner = "Freed-Wu";
repo = pname;
rev = version;
fetchSubmodules = false;
sha256 = "sha256-DCSeENxxXycCqQKv+8mPGy3sxF5CRHUPUaI9wRpEw8Q=";
};
srcs = [
(
fetchFromGitHub {
owner = "Freed-Wu";
repo = pname;
rev = version;
name = pname;
sha256 = "sha256-DCSeENxxXycCqQKv+8mPGy3sxF5CRHUPUaI9wRpEw8Q=";
}
)
(
fetchFromGitHub {
owner = "xmake-io";
repo = "xmake-repo";
rev = "9e39ee6a9c9a4c43192b95b7efcc95ea1c79a28d";
name = "xmake-repo";
sha256 = "sha256-LNXxNJalnJ18T/1JY1b3OxWBT1QMEnJkur2WVYa44aM=";
}
)
];
sourceRoot = ".";

nativeBuildInputs = [ stdenv.cc unzip pkg-config xmake ];
buildInputs = [ glib.dev librime ];

postPatch = ''
substituteInPlace xmake.lua --replace-quiet "glib" "glib-2.0"
'';

# https://github.com/xmake-io/xmake/discussions/5699
configurePhase = ''
export XMAKE_ROOT=y
HOME=$PWD PATH=$HOME:$PATH
echo -e "#!$SHELL\necho I am git" > $HOME/git
chmod +x $HOME/git
install -d .xmake/repositories
ln -sf ../../xmake-repo .xmake/repositories
cd ${pname}
xmake g --network=private
xmake f --verbose
'';
Expand Down

0 comments on commit 82783be

Please sign in to comment.