-
-
Notifications
You must be signed in to change notification settings - Fork 14.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
80 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
diff --git a/src/platform/core/CMakeLists.txt b/src/platform/core/CMakeLists.txt | ||
index 2bc6d8c..3175c14 100644 | ||
--- a/src/platform/core/CMakeLists.txt | ||
+++ b/src/platform/core/CMakeLists.txt | ||
@@ -18,8 +18,7 @@ find_package(OpenGL REQUIRED) | ||
|
||
include(FetchContent) | ||
FetchContent_Declare(glad | ||
- GIT_REPOSITORY https://github.com/Dav1dde/glad.git | ||
- GIT_TAG adc3d7a1d704e099581ca25bc5bbdf728c2db67b # v2.0.5-2-gadc3d7a | ||
+ SOURCE_DIR @gladSrc@ | ||
SOURCE_SUBDIR cmake | ||
) | ||
FetchContent_MakeAvailable(glad) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
{ | ||
lib, | ||
stdenv, | ||
fetchFromGitHub, | ||
substituteAll, | ||
cmake, | ||
python3Packages, | ||
libsForQt5, | ||
SDL2, | ||
fmt, | ||
toml11, | ||
libunarr, | ||
}: | ||
|
||
stdenv.mkDerivation (finalAttrs: { | ||
pname = "nanoboyadvance"; | ||
version = "1.8.1"; | ||
|
||
src = fetchFromGitHub { | ||
owner = "nba-emu"; | ||
repo = "NanoBoyAdvance"; | ||
rev = "v${finalAttrs.version}"; | ||
hash = "sha256-du3dPTg3OxNTWXDQo2m9W0rJxtrkn+lQSh/XGiu/eGg="; | ||
}; | ||
|
||
patches = [ | ||
(substituteAll { | ||
src = ./dont-fetch-glad.patch; | ||
gladSrc = fetchFromGitHub { | ||
owner = "Dav1dde"; | ||
repo = "glad"; | ||
rev = "v2.0.5"; | ||
hash = "sha256-Ba7nbd0DxDHfNXXu9DLfnxTQTiJIQYSES9CP5Bfq4K0="; | ||
}; | ||
}) | ||
]; | ||
|
||
nativeBuildInputs = [ | ||
cmake | ||
python3Packages.jinja2 | ||
libsForQt5.wrapQtAppsHook | ||
]; | ||
|
||
buildInputs = [ | ||
libsForQt5.qtbase | ||
SDL2 | ||
fmt | ||
toml11 | ||
libunarr | ||
]; | ||
|
||
cmakeFlags = [ | ||
(lib.cmakeBool "USE_SYSTEM_FMT" true) | ||
(lib.cmakeBool "USE_SYSTEM_TOML11" true) | ||
(lib.cmakeBool "USE_SYSTEM_UNARR" true) | ||
]; | ||
|
||
meta = { | ||
description = "A cycle-accurate Nintendo Game Boy Advance emulator"; | ||
homepage = "https://github.com/nba-emu/NanoBoyAdvance"; | ||
license = lib.licenses.gpl3Plus; | ||
mainProgram = "NanoBoyAdvance"; | ||
maintainers = with lib.maintainers; [ tomasajt ]; | ||
platforms = lib.platforms.all; | ||
}; | ||
}) |