mirror of
https://github.com/gelldur/EventBus.git
synced 2025-01-14 01:07:59 +08:00
Add CMakeLists
This commit is contained in:
parent
53d5026cad
commit
d92ee2fe8f
2
.gitignore
vendored
2
.gitignore
vendored
@ -26,3 +26,5 @@
|
||||
*.exe
|
||||
*.out
|
||||
*.app
|
||||
|
||||
build/
|
||||
|
26
CMakeLists.txt
Normal file
26
CMakeLists.txt
Normal file
@ -0,0 +1,26 @@
|
||||
CMAKE_MINIMUM_REQUIRED(VERSION 3.6 FATAL_ERROR)
|
||||
|
||||
# BUILD_SHARED_LIBS can controll build type!
|
||||
PROJECT(EventBus
|
||||
VERSION 1.0.12
|
||||
LANGUAGES CXX
|
||||
)
|
||||
|
||||
ADD_LIBRARY(EventBus
|
||||
src/EventCollector.cpp src/EventCollector.h
|
||||
src/Notification.cpp src/Notification.h
|
||||
src/Notifier.h
|
||||
)
|
||||
ADD_LIBRARY(Dexode::EventBus ALIAS EventBus)
|
||||
|
||||
TARGET_INCLUDE_DIRECTORIES(EventBus PUBLIC src/)
|
||||
|
||||
TARGET_COMPILE_OPTIONS(EventBus
|
||||
PUBLIC $<$<COMPILE_LANGUAGE:CXX>:-std=c++14>
|
||||
PRIVATE -Wall -pedantic -Wno-unused-private-field -Wnon-virtual-dtor -Werror
|
||||
)
|
||||
|
||||
TARGET_COMPILE_FEATURES(EventBus
|
||||
PUBLIC cxx_auto_type cxx_variadic_templates
|
||||
)
|
||||
|
Loading…
x
Reference in New Issue
Block a user