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
435f6c5c
Commit
435f6c5c
authored
5 years ago
by
Ryan Pavlik
Browse files
Options
Downloads
Patches
Plain Diff
build: Allow enabling inter-procedural optimization in CMake builds, if supported.
parent
9c470ddc
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
CMakeLists.txt
+9
-0
9 additions, 0 deletions
CMakeLists.txt
doc/changes/misc_features/mr.330.md
+1
-0
1 addition, 0 deletions
doc/changes/misc_features/mr.330.md
src/xrt/state_trackers/gui/CMakeLists.txt
+3
-0
3 additions, 0 deletions
src/xrt/state_trackers/gui/CMakeLists.txt
with
13 additions
and
0 deletions
CMakeLists.txt
+
9
−
0
View file @
435f6c5c
...
...
@@ -19,6 +19,10 @@ list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
include
(
CMakeDependentOption
)
include
(
SPIR-V
)
include
(
GNUInstallDirs
)
if
(
NOT
${
CMAKE_VERSION
}
VERSION_LESS 3.9
)
include
(
CheckIPOSupported
)
check_ipo_supported
(
RESULT HAS_IPO
)
endif
()
find_package
(
Eigen3 REQUIRED
)
find_package
(
Vulkan REQUIRED
)
...
...
@@ -64,6 +68,7 @@ else()
find_package
(
OpenGL
)
endif
()
cmake_dependent_option
(
CMAKE_INTERPROCEDURAL_OPTIMIZATION
"Enable inter-procedural (link-time) optimization"
OFF
"HAS_IPO"
OFF
)
cmake_dependent_option
(
XRT_HAVE_WAYLAND
"Enable Wayland support"
ON
"WAYLAND_FOUND AND WAYLAND_SCANNER_FOUND AND WAYLAND_PROTOCOLS_FOUND"
OFF
)
cmake_dependent_option
(
XRT_HAVE_XLIB
"Enable xlib support"
ON
"X11_FOUND"
OFF
)
cmake_dependent_option
(
XRT_HAVE_XCB
"Enable xcb support"
ON
"XCB_FOUND"
OFF
)
...
...
@@ -152,6 +157,10 @@ endif()
# Default to PIC code
set
(
CMAKE_POSITION_INDEPENDENT_CODE ON
)
# Describe IPO setting
if
(
CMAKE_INTERPROCEDURAL_OPTIMIZATION
)
message
(
STATUS
"Inter-procedural optimization enabled"
)
endif
()
###
# Decend into madness.
...
...
This diff is collapsed.
Click to expand it.
doc/changes/misc_features/mr.330.md
0 → 100644
+
1
−
0
View file @
435f6c5c
build: Allow enabling inter-procedural optimization in CMake GUIs, if supported by platform and compiler.
This diff is collapsed.
Click to expand it.
src/xrt/state_trackers/gui/CMakeLists.txt
+
3
−
0
View file @
435f6c5c
# Copyright 2019-2020, Collabora, Ltd.
# SPDX-License-Identifier: BSL-1.0
# c-imgui doesn't do well with IPO - lots of warnings.
set
(
CMAKE_INTERPROCEDURAL_OPTIMIZATION OFF
)
set
(
GUI_SOURCE_FILES
gui_common.h
gui_imgui.h
...
...
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