-
Notifications
You must be signed in to change notification settings - Fork 85
Expand file tree
/
Copy pathdefault.nix
More file actions
46 lines (39 loc) · 828 Bytes
/
default.nix
File metadata and controls
46 lines (39 loc) · 828 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
{
pkgs ? import <nixpkgs> {},
lib ? pkgs.lib
}:
pkgs.stdenv.mkDerivation {
pname = "skyemu";
version = "3-unstable-2025-01-25";
src = ./.;
postPatch = ''
# Nixpkgs does not support macOS universal builds
substituteInPlace CMakeLists.txt \
--replace-fail "set(CMAKE_OSX_ARCHITECTURES" "#"
'';
nativeBuildInputs = with pkgs; [
cmake
ninja
pkg-config
];
buildInputs = with pkgs; [
curl
openssl
SDL2
]
++ lib.optionals stdenv.hostPlatform.isLinux (with pkgs; [
alsa-lib
xorg.libXcursor
xorg.libXi
xorg.xinput
]);
cmakeFlags = [
(lib.cmakeBool "USE_SYSTEM_CURL" true)
(lib.cmakeBool "USE_SYSTEM_OPENSSL" true)
(lib.cmakeBool "USE_SYSTEM_SDL2" true)
];
meta = {
mainProgram = "SkyEmu";
license = lib.licenses.mit;
};
}