diff options
author | Mihai Fufezan <[email protected]> | 2024-08-08 02:30:44 +0300 |
---|---|---|
committer | Mihai Fufezan <[email protected]> | 2024-08-08 08:27:45 +0300 |
commit | 66e5de5509696741b3676ce693a5a93e2b7b4505 (patch) | |
tree | be03ceb8abfd97443ab846cfb624d38028f52c74 | |
parent | 590088ed7d8a98968ab8f003f2e672e462f06279 (diff) | |
download | Hyprland-66e5de5509696741b3676ce693a5a93e2b7b4505.tar.gz Hyprland-66e5de5509696741b3676ce693a5a93e2b7b4505.zip |
Nix: add cmake patchnative-handle
-rw-r--r-- | nix/default.nix | 5 | ||||
-rw-r--r-- | nix/stdcxx.patch | 12 |
2 files changed, 17 insertions, 0 deletions
diff --git a/nix/default.nix b/nix/default.nix index e4e12f43..9bae9d83 100644 --- a/nix/default.nix +++ b/nix/default.nix @@ -71,6 +71,11 @@ assert lib.assertMsg (!hidpiXWayland) "The option `hidpiXWayland` has been remov src = lib.cleanSource ../.; }; + patches = [ + # forces GCC to use -std=c++26 + ./stdcxx.patch + ]; + postPatch = '' # Fix hardcoded paths to /usr installation sed -i "s#/usr#$out#" src/render/OpenGL.cpp diff --git a/nix/stdcxx.patch b/nix/stdcxx.patch new file mode 100644 index 00000000..032e494d --- /dev/null +++ b/nix/stdcxx.patch @@ -0,0 +1,12 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index cfbd431f..73e8e0c2 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -64,6 +64,7 @@ endif() + include_directories(. "src/" "subprojects/udis86/" "protocols/") + set(CMAKE_CXX_STANDARD 26) + add_compile_options( ++ -std=c++26 + -Wall + -Wextra + -Wno-unused-parameter |