imtui: add patch for imgui 1.90.1
This commit is contained in:
parent
436ade14bb
commit
826093c6f1
@ -8,6 +8,7 @@
|
||||
, withCurl ? (!withEmscripten), curl
|
||||
, withNcurses ? (!withEmscripten), ncurses
|
||||
, static ? withEmscripten
|
||||
, darwin
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
@ -25,10 +26,14 @@ stdenv.mkDerivation rec {
|
||||
|
||||
buildInputs = lib.optional withEmscripten emscripten
|
||||
++ lib.optional withCurl curl
|
||||
++ lib.optional withNcurses ncurses;
|
||||
++ lib.optional withNcurses ncurses
|
||||
++ lib.optional stdenv.isDarwin darwin.apple_sdk.frameworks.Cocoa;
|
||||
|
||||
postPatch = ''
|
||||
cp -r ${imgui}/include/imgui third-party/imgui
|
||||
'' + lib.optionalString (lib.versionAtLeast imgui.version "1.90.1") ''
|
||||
substituteInPlace src/imtui-impl-{emscripten,ncurses}.cpp \
|
||||
--replace "ImGuiKey_KeyPadEnter" "ImGuiKey_KeypadEnter"
|
||||
'';
|
||||
|
||||
cmakeFlags = [
|
||||
@ -54,5 +59,6 @@ stdenv.mkDerivation rec {
|
||||
changelog = "https://github.com/ggerganov/imtui/blob/${src.rev}/CHANGELOG.md";
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ azahi ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user