From 9e53764f13cb8887f533cee4b1a4b6ce1121a48b Mon Sep 17 00:00:00 2001 From: Tony Crisci Date: Tue, 5 Dec 2017 09:02:42 -0500 Subject: [PATCH] meson wrap --- .build.yml | 6 ------ .gitignore | 1 + .travis.yml | 2 -- common/meson.build | 7 ++++++- meson.build | 2 +- subprojects/wlroots.wrap | 4 ++++ 6 files changed, 12 insertions(+), 10 deletions(-) create mode 100644 subprojects/wlroots.wrap diff --git a/.build.yml b/.build.yml index a2f855e9..c362b0f6 100644 --- a/.build.yml +++ b/.build.yml @@ -15,13 +15,7 @@ packages: - libxkbcommon sources: - https://git.sr.ht/~sircmpwn/sway - - https://git.sr.ht/~sircmpwn/wlroots tasks: - - wlroots: | - cd wlroots - meson --prefix=/usr build - ninja -C build - sudo ninja -C build install - setup: | cd sway meson build diff --git a/.gitignore b/.gitignore index b6e56f7a..c8d850b1 100644 --- a/.gitignore +++ b/.gitignore @@ -8,3 +8,4 @@ build/ .lvimrc config-debug wayland-*-protocol.* +subprojects/wlroots/ diff --git a/.travis.yml b/.travis.yml index db717718..2af6f183 100644 --- a/.travis.yml +++ b/.travis.yml @@ -26,8 +26,6 @@ arch: - libinput - libxkbcommon script: - - git clone https://github.com/swaywm/wlroots - - 'cd wlroots && meson --prefix=/usr build && ninja -C build && sudo ninja -C build install' - meson build --buildtype=$BUILD_TYPE - ninja -C build diff --git a/common/meson.build b/common/meson.build index 3a4282ad..16f85105 100644 --- a/common/meson.build +++ b/common/meson.build @@ -1,3 +1,7 @@ +sway_common_deps = [ + wlroots +] + lib_sway_common = static_library('sway-common', files( 'log.c', @@ -7,5 +11,6 @@ lib_sway_common = static_library('sway-common', 'readline.c', 'ipc-client.c' ), - include_directories: sway_inc + include_directories: sway_inc, + dependencies: [sway_common_deps] ) diff --git a/meson.build b/meson.build index 695e237e..e60571ba 100644 --- a/meson.build +++ b/meson.build @@ -20,7 +20,7 @@ prefix = get_option('prefix') jsonc = dependency('json-c', version: '>=0.12.1') pcre = dependency('libpcre') -wlroots = dependency('wlroots') +wlroots = dependency('wlroots', fallback: ['wlroots', 'wlroots']) wayland_server = dependency('wayland-server') wayland_client = dependency('wayland-client') wayland_egl = dependency('wayland-egl') diff --git a/subprojects/wlroots.wrap b/subprojects/wlroots.wrap new file mode 100644 index 00000000..4b5b558f --- /dev/null +++ b/subprojects/wlroots.wrap @@ -0,0 +1,4 @@ +[wrap-git] +directory=wlroots +url=https://github.com/swaywm/wlroots.git +revision=head