mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2026-07-09 17:25:37 -06:00
Abseil-Cpp for protobuff. (#4638)
Added abseil-cpp Add git abseilCppSource added to flake.lock Add abseilCppSource and pass the nix path to be compiled. Removed git
This commit is contained in:
parent
32bd28e04d
commit
56fd63cc95
18
flake.lock
generated
18
flake.lock
generated
@ -1,5 +1,22 @@
|
|||||||
{
|
{
|
||||||
"nodes": {
|
"nodes": {
|
||||||
|
"abseilCppSource": {
|
||||||
|
"flake": false,
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1750171688,
|
||||||
|
"narHash": "sha256-eB7OqTO9Vwts9nYQ/Mdq0Ds4T1KgmmpYdzU09VPWOhk=",
|
||||||
|
"owner": "abseil",
|
||||||
|
"repo": "abseil-cpp",
|
||||||
|
"rev": "76bb24329e8bf5f39704eb10d21b9a80befa7c81",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "abseil",
|
||||||
|
"ref": "20250512.1",
|
||||||
|
"repo": "abseil-cpp",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1779560665,
|
"lastModified": 1779560665,
|
||||||
@ -18,6 +35,7 @@
|
|||||||
},
|
},
|
||||||
"root": {
|
"root": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
|
"abseilCppSource": "abseilCppSource",
|
||||||
"nixpkgs": "nixpkgs"
|
"nixpkgs": "nixpkgs"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
27
flake.nix
27
flake.nix
@ -6,10 +6,15 @@
|
|||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
|
nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
|
||||||
|
|
||||||
|
abseilCppSource = {
|
||||||
|
url = "github:abseil/abseil-cpp?ref=20250512.1";
|
||||||
|
flake = false;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs =
|
outputs =
|
||||||
{ self, nixpkgs }:
|
{ self, nixpkgs, abseilCppSource }:
|
||||||
let
|
let
|
||||||
pkgsLinux = nixpkgs.legacyPackages.x86_64-linux;
|
pkgsLinux = nixpkgs.legacyPackages.x86_64-linux;
|
||||||
|
|
||||||
@ -21,6 +26,7 @@
|
|||||||
let
|
let
|
||||||
shell =
|
shell =
|
||||||
{ self
|
{ self
|
||||||
|
, lib
|
||||||
, mkShell
|
, mkShell
|
||||||
, clangStdenv
|
, clangStdenv
|
||||||
, clang-tools
|
, clang-tools
|
||||||
@ -87,7 +93,7 @@
|
|||||||
clang-tools
|
clang-tools
|
||||||
cmake
|
cmake
|
||||||
pkg-config
|
pkg-config
|
||||||
] ++ sdlConfigureDeps ++ pkgsLinux.lib.optionals enableDebugTooling [ renderdoc gef strace perf vulkan-tools ];
|
] ++ sdlConfigureDeps ++ lib.optionals enableDebugTooling [ renderdoc gef strace perf vulkan-tools ];
|
||||||
|
|
||||||
shellHook = ''
|
shellHook = ''
|
||||||
echo "Entering shadPS4 development shell!"
|
echo "Entering shadPS4 development shell!"
|
||||||
@ -112,6 +118,7 @@
|
|||||||
|
|
||||||
build =
|
build =
|
||||||
{ clangStdenv
|
{ clangStdenv
|
||||||
|
, lib
|
||||||
, cmake
|
, cmake
|
||||||
, ninja
|
, ninja
|
||||||
, pkg-config
|
, pkg-config
|
||||||
@ -151,6 +158,7 @@
|
|||||||
, libuuid
|
, libuuid
|
||||||
, systemdMinimal
|
, systemdMinimal
|
||||||
, libx11
|
, libx11
|
||||||
|
, abseilCppSource
|
||||||
, releaseMode ? "debug"
|
, releaseMode ? "debug"
|
||||||
, enableDiscordRpc ? false
|
, enableDiscordRpc ? false
|
||||||
,
|
,
|
||||||
@ -201,9 +209,10 @@
|
|||||||
|
|
||||||
cmakeFlags = [
|
cmakeFlags = [
|
||||||
(getBuildSettings releaseMode).flag
|
(getBuildSettings releaseMode).flag
|
||||||
(pkgsLinux.lib.cmakeBool "ENABLE_DISCORD_RPC" enableDiscordRpc)
|
(lib.cmakeBool "ENABLE_DISCORD_RPC" enableDiscordRpc)
|
||||||
(pkgsLinux.lib.cmakeBool "ENABLE_TESTS" false)
|
(lib.cmakeBool "ENABLE_TESTS" false)
|
||||||
(pkgsLinux.lib.cmakeBool "ENABLE_SYSTEM_LIBRARIES" true)
|
(lib.cmakeBool "ENABLE_SYSTEM_LIBRARIES" true)
|
||||||
|
"-DFETCHCONTENT_SOURCE_DIR_ABSL=${abseilCppSource}"
|
||||||
];
|
];
|
||||||
dontStrip = (getBuildSettings releaseMode).symbols;
|
dontStrip = (getBuildSettings releaseMode).symbols;
|
||||||
|
|
||||||
@ -219,10 +228,10 @@
|
|||||||
});
|
});
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
debug = pkgsLinux.callPackage build { releaseMode = "debug"; };
|
debug = pkgsLinux.callPackage build { releaseMode = "debug"; inherit abseilCppSource; };
|
||||||
release = pkgsLinux.callPackage build { releaseMode = "release"; };
|
release = pkgsLinux.callPackage build { releaseMode = "release"; inherit abseilCppSource; };
|
||||||
releaseWithDebInfo = pkgsLinux.callPackage build { releaseMode = "relWithDebInfo"; };
|
releaseWithDebInfo = pkgsLinux.callPackage build { releaseMode = "relWithDebInfo"; inherit abseilCppSource; };
|
||||||
default = pkgsLinux.callPackage build { releaseMode = "relWithDebInfo"; };
|
default = pkgsLinux.callPackage build { releaseMode = "relWithDebInfo"; inherit abseilCppSource; };
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user