mirror of
https://github.com/nillerusr/source-engine.git
synced 2025-06-19 05:38:08 +00:00
Compare commits
1 Commits
0b5f0e8cec
...
0cb0cc2b2b
Author | SHA1 | Date | |
---|---|---|---|
![]() |
0cb0cc2b2b |
34
flake.lock
generated
34
flake.lock
generated
@ -1,23 +1,5 @@
|
||||
{
|
||||
"nodes": {
|
||||
"flake-utils": {
|
||||
"inputs": {
|
||||
"systems": "systems"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1731533236,
|
||||
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"ivp-submodule": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
@ -67,28 +49,12 @@
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"flake-utils": "flake-utils",
|
||||
"ivp-submodule": "ivp-submodule",
|
||||
"lib-submodule": "lib-submodule",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"thirdparty-submodule": "thirdparty-submodule"
|
||||
}
|
||||
},
|
||||
"systems": {
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"thirdparty-submodule": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
|
81
flake.nix
81
flake.nix
@ -1,7 +1,6 @@
|
||||
{
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs";
|
||||
flake-utils.url = "github:numtide/flake-utils";
|
||||
|
||||
ivp-submodule = {
|
||||
url = "github:nillerusr/source-physics";
|
||||
@ -19,47 +18,45 @@
|
||||
};
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, flake-utils, ... }@inputs:
|
||||
flake-utils.lib.eachDefaultSystem (system:
|
||||
let
|
||||
pkgs = import nixpkgs { inherit system; };
|
||||
outputs = { self, nixpkgs, ... }@inputs:
|
||||
let
|
||||
pkgs = nixpkgs.legacyPackages.x86_64-linux;
|
||||
|
||||
# Fix for git submodules
|
||||
hl2-unwrapped = (pkgs.callPackage ./hl2-unwrapped.nix { }).overrideAttrs {
|
||||
postPatch = ''
|
||||
rm -rf ./{ivp,lib,thirdparty}
|
||||
ln -s ${inputs.ivp-submodule} ./ivp
|
||||
ln -s ${inputs.lib-submodule} ./lib
|
||||
ln -s ${inputs.thirdparty-submodule} ./thirdparty
|
||||
'';
|
||||
};
|
||||
in
|
||||
{
|
||||
# Install the game on your own computer
|
||||
packages = {
|
||||
hl2 = pkgs.callPackage ./build.nix { inherit hl2-unwrapped; };
|
||||
default = self.packages.${system}.hl2;
|
||||
};
|
||||
# Fix for git submodules
|
||||
hl2-unwrapped = (pkgs.callPackage ./hl2-unwrapped.nix { }).overrideAttrs {
|
||||
postPatch = ''
|
||||
rm -rf ./{ivp,lib,thirdparty}
|
||||
ln -s ${inputs.ivp-submodule} ./ivp
|
||||
ln -s ${inputs.lib-submodule} ./lib
|
||||
ln -s ${inputs.thirdparty-submodule} ./thirdparty
|
||||
'';
|
||||
};
|
||||
in
|
||||
{
|
||||
# Install the game on your own computer
|
||||
packages.x86_64-linux = {
|
||||
hl2 = pkgs.callPackage ./build.nix { inherit hl2-unwrapped; };
|
||||
default = self.packages.x86_64-linux.hl2;
|
||||
};
|
||||
|
||||
# Build the game for others
|
||||
devShells.default = pkgs.mkShell rec {
|
||||
nativeBuildInputs = with pkgs; [
|
||||
makeWrapper
|
||||
SDL2
|
||||
freetype
|
||||
fontconfig
|
||||
zlib
|
||||
bzip2
|
||||
libjpeg
|
||||
libpng
|
||||
curl
|
||||
openal
|
||||
libopus
|
||||
pkg-config
|
||||
gcc
|
||||
python3
|
||||
];
|
||||
};
|
||||
}
|
||||
);
|
||||
# Build the game for others
|
||||
devShells.default = pkgs.mkShell rec {
|
||||
nativeBuildInputs = with pkgs; [
|
||||
makeWrapper
|
||||
SDL2
|
||||
freetype
|
||||
fontconfig
|
||||
zlib
|
||||
bzip2
|
||||
libjpeg
|
||||
libpng
|
||||
curl
|
||||
openal
|
||||
libopus
|
||||
pkg-config
|
||||
gcc
|
||||
python3
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user