aboutsummaryrefslogtreecommitdiff
path: root/meson.build
blob: 06eed97fb1cb8c0b4595065d8b508edd7a5b0fc0 (plain)
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
project(
	'sway',
	'c',
	license: 'MIT',
	default_options: [
		'c_std=c11',
		'warning_level=2',
		'werror=true',
	],
)

cc = meson.get_compiler('c')

jsonc		   = dependency('json-c', version: '>=0.12.1')
pcre		   = dependency('libpcre')
wlroots		   = dependency('wlroots')
wayland_server = dependency('wayland-server')
wayland_client = dependency('wayland-client')
wayland_egl    = dependency('wayland-egl')
wayland_protos = dependency('wayland-protocols')
xkbcommon      = dependency('xkbcommon')
pango		   = dependency('pango')
pixman		   = dependency('pixman-1')
libcap		   = dependency('libcap')

math           = cc.find_library('m')

# TODO version
add_project_arguments('-DSWAY_VERSION="5"', language: 'c')

sway_inc = include_directories('include')

sway_sources = [
	'sway/main.c',
	'sway/server.c',
	'sway/commands.c',
	'sway/commands/exit.c',
	'sway/ipc-json.c',
	'sway/ipc-server.c',
	'sway/desktop/output.c',
	'sway/desktop/xdg_shell_v6.c',
	'sway/tree/container.c',
	'sway/tree/layout.c',
	'sway/tree/workspace.c',
	'common/log.c',
	'common/list.c',
	'common/stringop.c',
	'common/readline.c',
	'common/ipc-client.c',
]

sway_deps = [
	pixman,
	wayland_server,
	jsonc,
	wlroots,
	libcap,
	math,
]

executable(
	'sway',
	sway_sources,
	include_directories: [sway_inc],
	dependencies: sway_deps
)