Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
monado
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
blender
monado
Commits
ba50cefc
Commit
ba50cefc
authored
5 years ago
by
Jakob Bornecrantz
Browse files
Options
Downloads
Patches
Plain Diff
meson: Tidy meson.build a bit
parent
059234bb
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
meson.build
+47
-9
47 additions, 9 deletions
meson.build
with
47 additions
and
9 deletions
meson.build
+
47
−
9
View file @
ba50cefc
...
@@ -32,6 +32,23 @@ add_project_arguments(cpp.get_supported_arguments([
...
@@ -32,6 +32,23 @@ add_project_arguments(cpp.get_supported_arguments([
'-Wno-deprecated-copy'
,
# Eigen
'-Wno-deprecated-copy'
,
# Eigen
]),
language
:
'cpp'
)
]),
language
:
'cpp'
)
#
# Pre-setting these variables
#
build_docs
=
false
build_tracking
=
false
v4l2_required
=
false
hidapi_required
=
false
openhmd_required
=
false
#
# Adding dependencies
#
glslangValidator
=
find_program
(
'glslangValidator'
)
glslangValidator
=
find_program
(
'glslangValidator'
)
avcodec
=
dependency
(
'libavcodec'
,
required
:
false
)
avcodec
=
dependency
(
'libavcodec'
,
required
:
false
)
...
@@ -56,8 +73,6 @@ pthreads = cc.find_library('pthread', required: true)
...
@@ -56,8 +73,6 @@ pthreads = cc.find_library('pthread', required: true)
if
get_option
(
'tracking'
).
enabled
()
or
get_option
(
'tracking'
).
auto
()
if
get_option
(
'tracking'
).
enabled
()
or
get_option
(
'tracking'
).
auto
()
build_tracking
=
opencv
.
found
()
build_tracking
=
opencv
.
found
()
else
build_tracking
=
false
endif
endif
# TODO: make these behave well when not present
# TODO: make these behave well when not present
...
@@ -76,10 +91,6 @@ if wayland_scanner.found()
...
@@ -76,10 +91,6 @@ if wayland_scanner.found()
)
)
endif
endif
hidapi_required
=
false
openhmd_required
=
false
v4l2_required
=
false
# For now required on Linux
# For now required on Linux
if
target_machine
.
system
()
==
'linux'
if
target_machine
.
system
()
==
'linux'
v4l2_required
=
true
v4l2_required
=
true
...
@@ -130,8 +141,6 @@ endif
...
@@ -130,8 +141,6 @@ endif
if
drivers
.
length
()
==
0
or
drivers
==
[
'auto'
]
if
drivers
.
length
()
==
0
or
drivers
==
[
'auto'
]
error
(
'You must enable at least one driver.'
)
error
(
'You must enable at least one driver.'
)
else
message
(
'Building with drivers '
+
', '
.
join
(
drivers
))
endif
endif
if
udev
.
found
()
if
udev
.
found
()
...
@@ -162,12 +171,26 @@ if sdl2.found()
...
@@ -162,12 +171,26 @@ if sdl2.found()
add_project_arguments
(
'-DXRT_HAVE_SDL2'
,
language
:
[
'c'
,
'cpp'
])
add_project_arguments
(
'-DXRT_HAVE_SDL2'
,
language
:
[
'c'
,
'cpp'
])
endif
endif
if
doxygen
.
found
()
build_docs
=
true
endif
#
# Go down sub directories
#
subdir
(
'src'
)
subdir
(
'src'
)
if
doxygen
.
found
()
if
build_docs
subdir
(
'doc'
)
subdir
(
'doc'
)
endif
endif
#
# Final bits
#
# This is here so that it gets emitted in the top-level build directory
# This is here so that it gets emitted in the top-level build directory
manifest_devconf
=
configuration_data
()
manifest_devconf
=
configuration_data
()
# https://github.com/mesonbuild/meson/issues/5940
# https://github.com/mesonbuild/meson/issues/5940
...
@@ -178,3 +201,18 @@ manifest_dev_json = configure_file(
...
@@ -178,3 +201,18 @@ manifest_dev_json = configure_file(
output
:
'openxr_monado-dev.json'
,
output
:
'openxr_monado-dev.json'
,
configuration
:
manifest_devconf
,
configuration
:
manifest_devconf
,
)
)
message
(
'Configuration done!'
)
message
(
' drivers: '
+
', '
.
join
(
drivers
))
if
build_docs
message
(
' docs: yes'
)
else
message
(
' docs: no'
)
endif
if
build_tracking
message
(
' tracking: yes'
)
else
message
(
' tracking: no'
)
endif
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment