mirror of
https://github.com/hyprwm/hyprland-plugins.git
synced 2024-11-25 03:35:59 +01:00
hyprtrails: add meson and nix
This commit is contained in:
parent
5fcf732c6e
commit
dbac311729
3 changed files with 58 additions and 0 deletions
|
@ -23,6 +23,10 @@
|
|||
inherit (hyprland.packages.${system}) hyprland;
|
||||
stdenv = pkgs.gcc13Stdenv;
|
||||
};
|
||||
hyprtrails = pkgs.callPackage ./hyprtrails {
|
||||
inherit (hyprland.packages.${system}) hyprland;
|
||||
stdenv = pkgs.gcc13Stdenv;
|
||||
};
|
||||
});
|
||||
|
||||
devShells = withPkgsFor (system: pkgs: {
|
||||
|
|
21
hyprtrails/default.nix
Normal file
21
hyprtrails/default.nix
Normal file
|
@ -0,0 +1,21 @@
|
|||
{
|
||||
lib,
|
||||
stdenv,
|
||||
hyprland,
|
||||
}:
|
||||
stdenv.mkDerivation {
|
||||
pname = "hyprtrails";
|
||||
version = "0.1";
|
||||
src = ./.;
|
||||
|
||||
inherit (hyprland) nativeBuildInputs;
|
||||
|
||||
buildInputs = [hyprland] ++ hyprland.buildInputs;
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/hyprwm/hyprland-plugins";
|
||||
description = "Smooth trails behind moving windows for Hyprland";
|
||||
license = licenses.bsd3;
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
33
hyprtrails/meson.build
Normal file
33
hyprtrails/meson.build
Normal file
|
@ -0,0 +1,33 @@
|
|||
project('hyprtrails', 'cpp',
|
||||
version: '0.1',
|
||||
default_options: ['buildtype=release'],
|
||||
)
|
||||
|
||||
cpp_compiler = meson.get_compiler('cpp')
|
||||
if cpp_compiler.has_argument('-std=c++23')
|
||||
add_global_arguments('-std=c++23', language: 'cpp')
|
||||
elif cpp_compiler.has_argument('-std=c++2b')
|
||||
add_global_arguments('-std=c++2b', language: 'cpp')
|
||||
else
|
||||
error('Could not configure current C++ compiler (' + cpp_compiler.get_id() + ' ' + cpp_compiler.version() + ') with required C++ standard (C++23)')
|
||||
endif
|
||||
|
||||
add_project_arguments(
|
||||
[
|
||||
'-Wno-narrowing',
|
||||
],
|
||||
language: 'cpp')
|
||||
|
||||
globber = run_command('find', '.', '-name', '*.cpp', check: true)
|
||||
src = globber.stdout().strip().split('\n')
|
||||
|
||||
hyprland = dependency('hyprland')
|
||||
|
||||
shared_module(meson.project_name(), src,
|
||||
dependencies: [
|
||||
dependency('hyprland'),
|
||||
dependency('pixman-1'),
|
||||
dependency('libdrm'),
|
||||
],
|
||||
install: true,
|
||||
)
|
Loading…
Reference in a new issue