diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2018-12-24 18:54:34 +0100 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2018-12-24 19:32:10 +0100 |
commit | a88e34b21b07f70123926fcb5c505d6afdf99807 (patch) | |
tree | 905059194dcc64c7c163b8912947d8173fd4cc91 /cmake/opentrack-boilerplate.cmake | |
parent | 5bf85412e4eacf92acc936b6e74bce0e2b1055d9 (diff) |
style/quality only
No functional changes.
- add `override' everywhere where missing
- almost pass clang's `-Wweak-vtables'
- avoid some float/double conversions
- remove unused private members
- make signedness conversions explicit
- put stuff in right namespaces to aid analysis
Diffstat (limited to 'cmake/opentrack-boilerplate.cmake')
-rw-r--r-- | cmake/opentrack-boilerplate.cmake | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/cmake/opentrack-boilerplate.cmake b/cmake/opentrack-boilerplate.cmake index c56c43ee..9d72c1af 100644 --- a/cmake/opentrack-boilerplate.cmake +++ b/cmake/opentrack-boilerplate.cmake @@ -133,8 +133,6 @@ function(otr_module n_) endif() set(n "opentrack-${n_}") - # XXX TODO update callers to use instead of long name -sh 20180527 - set(self "${n}" PARENT_SCOPE) if(NOT arg_SUBDIRS) otr_glob_sources(${n} .) @@ -175,6 +173,8 @@ function(otr_module n_) set_property(TARGET "${n}" PROPERTY PREFIX "") endif() + set(self "${n}" PARENT_SCOPE) + if(NOT arg_RELINK) set_property(TARGET ${n} PROPERTY LINK_DEPENDS_NO_SHARED TRUE) else() @@ -205,6 +205,10 @@ function(otr_module n_) otr_compat(${n}) + if(CMAKE_COMPILER_IS_CLANG AND (arg_EXECUTABLE OR (NOT arg_BIN AND NOT arg_STATIC))) + set_property(TARGET "${n}" APPEND_STRING PROPERTY COMPILE_FLAGS "-Wno-weak-vtables ") + endif() + if(NOT arg_NO-INSTALL) if(arg_BIN AND WIN32) install(TARGETS "${n}" RUNTIME DESTINATION . PERMISSIONS ${opentrack-perms-exec}) |