-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathshell.nix
75 lines (68 loc) · 1.69 KB
/
shell.nix
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
{ system ? builtins.currentSystem }:
let
pkgs = import ./nix/nixpkgs.nix { inherit system; };
in
pkgs.mkShell {
buildInputs = with pkgs; [
wayland
wayland-protocols
wayland-scanner
wlroots
wlr-protocols
pixman
libxkbcommon
libffi
libdrm
egl-wayland
libGL
mesa
vulkan-loader
pkg-config
libudev-zero
systemdLibs
libdisplay-info
libliftoff
libinput
xorg.libxcb
xorg.libXau
xorg.libXdmcp
xorg.xcbutilrenderutil
xorg.xcbutilwm
xorg.xcbutilerrors
# Development tools
bear
gdb
haskell-language-server
#Example Wayland Clients
yambar
mako
bemenu
wbg
gcc
gnumake
libseat
ghc
cabal-install
];
shellHook = ''
export WAYLAND_PROTOCOLS=${pkgs.wayland-protocols}/share/wayland-protocols
export WLR_PROTOCOLS=${pkgs.wlr-protocols}/share/wlr-protocols/
export WAYLAND_SCANNER=${pkgs.wayland-scanner}/bin/wayland-scanner
export WLR_RENDERER=pixman
export BEMENU_OPTS="-i -l 10 --fn 'monospace 12' --tb '#1d1f21' --tf '#c5c8c6' --fb '#1d1f21' --ff '#c5c8c6' --nb '#1d1f21' --nf '#c5c8c6' --hb '#1d1f21' --hf '#81a2be'"
export BEMENU_BACKEND=wayland
unset GHC_PACKAGE_PATH
# Build tinywl
echo "Building tinywl..."
cd tinywl
make -f Makefile.shared clean
make -f Makefile.shared
cd ..
# Add the tinywl directory to LD_LIBRARY_PATH
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$PWD/tinywl
echo "Wayland development environment"
echo "wayland-scanner version: $(wayland-scanner --version)"
echo "Wayland protocols path: $WAYLAND_PROTOCOLS"
echo "LD_LIBRARY_PATH includes: $LD_LIBRARY_PATH"
'';
}