Compare commits

..

No commits in common. "subprojects" and "main" have entirely different histories.

16 changed files with 37 additions and 85 deletions

4
.gitmodules vendored
View File

@ -1,3 +1,3 @@
[submodule "source/RCSwitch/rc-switch"] [submodule "source/rc-switch"]
path = source/RCSwitch/rc-switch path = source/rc-switch
url = git@github.com:sui77/rc-switch.git url = git@github.com:sui77/rc-switch.git

View File

@ -1,7 +1,37 @@
cmake_minimum_required(VERSION 3.6) cmake_minimum_required(VERSION 3.6)
add_subdirectory(RCSwitch) find_package(Qt5Widgets)
add_subdirectory(sniffer)
add_subdirectory(qsniff) set(CMAKE_CXX_STANDARD 11)
add_subdirectory(sniff) set(CMAKE_INCLUDE_CURRENT_DIR ON)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTOUIC ON)
add_definitions(-DRPI)
add_library(rc-switch
rc-switch/RCSwitch.cpp
rc-switch/RCSwitch.h
)
add_executable(qSniff
qsniff.cpp
mainwindow.cpp
mainwindow.h
mainwindow.ui
sniffthread.cpp
sniffthread.h
sniffer.cpp
sniffer.h
)
target_link_libraries(qSniff rc-switch wiringPi Qt5::Widgets)
add_executable(Sniff
sniff.cpp
sniffer.cpp
sniffer.h
)
target_link_libraries(Sniff rc-switch wiringPi)

View File

@ -1,21 +0,0 @@
project(rc-switch)
cmake_minimum_required(VERSION 3.6)
add_library(${PROJECT_NAME}
rc-switch/RCSwitch.cpp
rc-switch/RCSwitch.h
)
target_link_libraries(${PROJECT_NAME}
wiringPi
)
target_include_directories(${PROJECT_NAME}
PUBLIC rc-switch
)
target_compile_definitions(${PROJECT_NAME}
PUBLIC RPI
)

View File

@ -1,24 +0,0 @@
project(qSniff)
cmake_minimum_required(VERSION 3.6)
find_package(Qt5Widgets)
set(CMAKE_CXX_STANDARD 11)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTOUIC ON)
add_executable(${PROJECT_NAME}
qsniff.cpp
mainwindow.cpp
mainwindow.h
mainwindow.ui
sniffthread.cpp
sniffthread.h
)
target_link_libraries(${PROJECT_NAME}
sniffer
Qt5::Widgets
)

View File

@ -1,15 +0,0 @@
project(Sniff)
cmake_minimum_required(VERSION 3.6)
set(CMAKE_CXX_STANDARD 11)
add_executable(${PROJECT_NAME}
sniff.cpp
)
target_link_libraries(${PROJECT_NAME}
sniffer
rc-switch
wiringPi
)

View File

@ -1,6 +1,6 @@
#pragma once #pragma once
#include "RCSwitch.h" #include "rc-switch/RCSwitch.h"
class Sniffer class Sniffer
{ {

View File

@ -1,18 +0,0 @@
project(sniffer)
cmake_minimum_required(VERSION 3.6)
set(CMAKE_CXX_STANDARD 11)
add_library(${PROJECT_NAME}
sniffer.cpp
sniffer.h
)
target_link_libraries(${PROJECT_NAME}
rc-switch
)
target_include_directories(${PROJECT_NAME}
PUBLIC .
)