forked from Azure/iot-edge-v1
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 2c99994
Showing
241 changed files
with
65,350 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# Default behavior: if Git thinks a file is text (as opposed to binary), it | ||
# will normalize line endings to LF in the repository, but convert to your | ||
# platform's native line endings on checkout (e.g., CRLF for Windows). | ||
* text=auto | ||
|
||
# Explicitly declare text files you want to always be normalized and converted | ||
# to native line endings on checkout. E.g., | ||
#*.c text | ||
|
||
# Declare files that will always have CRLF line endings on checkout. E.g., | ||
#*.sln text eol=crlf | ||
|
||
# Declare files that will always have LF line endings on checkout. E.g., | ||
*.sh text eol=lf | ||
|
||
# Denote all files that should not have line endings normalized, should not be | ||
# merged, and should not show in a textual diff. | ||
*.docm binary | ||
*.docx binary | ||
*.ico binary | ||
*.lib binary | ||
*.png binary | ||
*.pptx binary | ||
*.snk binary | ||
*.vsdx binary | ||
*.xps binary |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,219 @@ | ||
# Compiled object files | ||
*.o | ||
*.opp | ||
|
||
# Compiled static libraries | ||
*.a | ||
|
||
## Ignore Visual Studio temporary files, build results, and | ||
## files generated by popular Visual Studio add-ons. | ||
|
||
# User-specific files | ||
*.suo | ||
*.user | ||
*.sln.docstates | ||
|
||
# Build results | ||
|
||
[Dd]ebug/ | ||
[Rr]elease/ | ||
x64/ | ||
[Bb]in/ | ||
[Oo]bj/ | ||
|
||
# Enable "build/" folder in the NuGet Packages folder since NuGet packages use it for MSBuild targets | ||
!packages/*/build/ | ||
|
||
# MSTest test Results | ||
[Tt]est[Rr]esult*/ | ||
[Bb]uild[Ll]og.* | ||
|
||
*_i.c | ||
*_p.c | ||
*.ilk | ||
*.meta | ||
*.obj | ||
*.pch | ||
*.pdb | ||
*.pgc | ||
*.pgd | ||
*.rsp | ||
*.sbr | ||
*.tlb | ||
*.tli | ||
*.tlh | ||
*.tmp | ||
*.tmp_proj | ||
*.log | ||
*.vspscc | ||
*.vssscc | ||
.builds | ||
*.pidb | ||
*.log | ||
*.scc | ||
|
||
# Visual C++ cache files | ||
ipch/ | ||
*.aps | ||
*.ncb | ||
*.opensdf | ||
*.sdf | ||
*.cachefile | ||
|
||
# Visual Studio profiler | ||
*.psess | ||
*.vsp | ||
*.vspx | ||
|
||
# Guidance Automation Toolkit | ||
*.gpState | ||
|
||
# ReSharper is a .NET coding add-in | ||
_ReSharper*/ | ||
*.[Rr]e[Ss]harper | ||
|
||
# TeamCity is a build add-in | ||
_TeamCity* | ||
|
||
# DotCover is a Code Coverage Tool | ||
*.dotCover | ||
|
||
# NCrunch | ||
*.ncrunch* | ||
.*crunch*.local.xml | ||
|
||
# Installshield output folder | ||
[Ee]xpress/ | ||
|
||
# DocProject is a documentation generator add-in | ||
DocProject/buildhelp/ | ||
DocProject/Help/*.HxT | ||
DocProject/Help/*.HxC | ||
DocProject/Help/*.hhc | ||
DocProject/Help/*.hhk | ||
DocProject/Help/*.hhp | ||
DocProject/Help/Html2 | ||
DocProject/Help/html | ||
|
||
# Click-Once directory | ||
publish/ | ||
|
||
# Publish Web Output | ||
*.Publish.xml | ||
|
||
# NuGet Packages Directory | ||
packages/ | ||
|
||
# Windows Azure Build Output | ||
csx | ||
*.build.csdef | ||
|
||
# Windows Store app package directory | ||
AppPackages/ | ||
|
||
# Others | ||
sql/ | ||
*.Cache | ||
ClientBin/ | ||
[Ss]tyle[Cc]op.* | ||
~$* | ||
*~ | ||
*.dbmdl | ||
*.[Pp]ublish.xml | ||
*.pfx | ||
*.publishsettings | ||
|
||
# RIA/Silverlight projects | ||
Generated_Code/ | ||
|
||
# Backup & report files from converting an old project file to a newer | ||
# Visual Studio version. Backup files are not needed, because we have git ;-) | ||
_UpgradeReport_Files/ | ||
Backup*/ | ||
UpgradeLog*.XML | ||
UpgradeLog*.htm | ||
|
||
# SQL Server files | ||
App_Data/*.mdf | ||
App_Data/*.ldf | ||
|
||
|
||
#LightSwitch generated files | ||
GeneratedArtifacts/ | ||
_Pvt_Extensions/ | ||
ModelManifest.xml | ||
|
||
# ========================= | ||
# Windows detritus | ||
# ========================= | ||
|
||
# Windows image file caches | ||
Thumbs.db | ||
ehthumbs.db | ||
|
||
# Folder config file | ||
Desktop.ini | ||
|
||
# Recycle Bin used on file shares | ||
$RECYCLE.BIN/ | ||
|
||
# Mac desktop service store files | ||
.DS_Store | ||
|
||
# Visual studio build artifacts | ||
*.tlog | ||
*.lastbuildstate | ||
*.idb | ||
*.exp | ||
*.lib | ||
*.dll | ||
|
||
# Windows CE build artifacts | ||
Build.err | ||
Build.wrn | ||
Buildx86retail.dat | ||
*.dat | ||
|
||
# Tools EXE that doesn't end up in a typical build directory | ||
c/common/tools/macro_utils_h_generator/macro_utils_h_generator.exe | ||
|
||
# hg directories should be ignored | ||
**/hg/ | ||
|
||
# Java | ||
java/**/.idea/ | ||
java/**/out/ | ||
java/**/target/ | ||
java/**/*.iml | ||
java/**/*dependency-reduced-pom.xml | ||
tools/jenkins-cli.jar | ||
|
||
# Node.js | ||
**/.settings/ | ||
**/node_modules/ | ||
**/.idea/ | ||
|
||
# VS Code stuff | ||
typings/** | ||
.vscode/** | ||
|
||
csharp/NuGet/*.exe | ||
csharp/NuGet/*.nupkg | ||
csharp/.vs/* | ||
service/java/.idea | ||
service/java/target | ||
service/java/iot.service.sdk.java.iml | ||
|
||
# ignore cmake build folder | ||
.cmake/** | ||
build/** | ||
|
||
# ignore Atom Editor files | ||
.atom-build.json | ||
.remote-sync.json | ||
|
||
# ignore VS Code C++ files | ||
browse.VC.db | ||
|
||
# api reference docstates | ||
api_reference/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
[submodule "deps/azure-c-shared-utility"] | ||
path = deps/azure-c-shared-utility | ||
url = https://github.com/Azure/azure-c-shared-utility | ||
[submodule "deps/azure-iot-sdks"] | ||
path = deps/azure-iot-sdks | ||
url = https://github.com/azure/azure-iot-sdks | ||
[submodule "deps/parson"] | ||
path = deps/parson | ||
url = https://github.com/kgabis/parson |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,98 @@ | ||
cmake_minimum_required(VERSION 2.8.11) | ||
project(azure_iot_gateway_sdk) | ||
|
||
#the following variables are project-wide and can be used with cmake-gui | ||
option(run_e2e_tests "set run_e2e_tests to ON to run e2e tests (default is OFF) [if possible, they are always build]" OFF) | ||
option(install_executables "should cmake run cmake's install function (that includes dynamic link libraries) [it does for yocto]" OFF) | ||
|
||
option(run_as_a_service "Flags that we have the goal of running gateway as a service for samples and OS that supports it." OFF) | ||
|
||
#making a nice global variable to know if we are on linux or not. | ||
if(CMAKE_SYSTEM_NAME STREQUAL "Linux") | ||
set(LINUX TRUE) | ||
find_program( MEMORYCHECK_COMMAND valgrind ) | ||
set( MEMORYCHECK_COMMAND_OPTIONS "--trace-children=yes --leak-check=full --suppressions=${CMAKE_CURRENT_LIST_DIR}/core/valgrind_suppressions.txt --error-exitcode=1" ) | ||
endif() | ||
|
||
include (CTest) | ||
|
||
#setting #defines | ||
if(WIN32) | ||
add_definitions(-D_CRT_SECURE_NO_WARNINGS) | ||
add_compile_options(/guard:cf) | ||
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} /guard:cf") | ||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /guard:cf") | ||
set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} /guard:cf") | ||
endif() | ||
|
||
if(${LINUX}) | ||
set (CMAKE_C_FLAGS "-fPIC ${CMAKE_C_FLAGS}") | ||
endif() | ||
|
||
function(add_module_to_solution undecoratedModuleName) | ||
set_target_properties(${undecoratedModuleName} | ||
PROPERTIES FOLDER "Modules/${undecoratedModuleName}") | ||
set_target_properties(${undecoratedModuleName}_static | ||
PROPERTIES FOLDER "Modules/${undecoratedModuleName}") | ||
set_target_properties(${undecoratedModuleName}_hl | ||
PROPERTIES FOLDER "Modules/${undecoratedModuleName}") | ||
set_target_properties(${undecoratedModuleName}_hl_static | ||
PROPERTIES FOLDER "Modules/${undecoratedModuleName}") | ||
endfunction() | ||
|
||
function(add_sample_to_solution sampleName) | ||
set_target_properties(${sampleName} PROPERTIES FOLDER "AzureIoTGateway_Samples") | ||
endfunction() | ||
|
||
|
||
macro(compileAsC99) | ||
if (CMAKE_VERSION VERSION_LESS "3.1") | ||
if (CMAKE_C_COMPILER_ID STREQUAL "GNU") | ||
set (CMAKE_C_FLAGS "--std=c99 ${CMAKE_C_FLAGS}") | ||
set (CMAKE_CXX_FLAGS "--std=c++11 ${CMAKE_CXX_FLAGS}") | ||
endif() | ||
else() | ||
set (CMAKE_C_STANDARD 99) | ||
set (CMAKE_CXX_STANDARD 11) | ||
endif() | ||
endmacro(compileAsC99) | ||
|
||
macro(compileAsC11) | ||
if (CMAKE_VERSION VERSION_LESS "3.1") | ||
if (CMAKE_C_COMPILER_ID STREQUAL "GNU") | ||
set (CMAKE_C_FLAGS "--std=c11 ${CMAKE_C_FLAGS}") | ||
set (CMAKE_C_FLAGS "-D_POSIX_C_SOURCE=200112L ${CMAKE_C_FLAGS}") | ||
set (CMAKE_CXX_FLAGS "--std=c++11 ${CMAKE_CXX_FLAGS}") | ||
endif() | ||
else() | ||
set (CMAKE_C_STANDARD 11) | ||
set (CMAKE_CXX_STANDARD 11) | ||
endif() | ||
endmacro(compileAsC11) | ||
|
||
enable_testing() | ||
compileAsC99() | ||
|
||
#this adds the C shared utility | ||
add_subdirectory(./deps/azure-c-shared-utility) | ||
|
||
#this adds the C IoTHubClient | ||
add_subdirectory(./deps/azure-iot-sdks/c) | ||
|
||
#this makes available from now on the includes of azure-c-shared-utility | ||
include_directories(${SHARED_UTIL_INC_FOLDER}) | ||
|
||
function(linkSharedUtil whatIsBuilding) | ||
target_link_libraries(${whatIsBuilding} aziotsharedutil) | ||
endfunction(linkSharedUtil) | ||
|
||
#this adds parson | ||
include_directories(./deps/parson) | ||
|
||
add_subdirectory(./core) | ||
|
||
include_directories(${GW_INC}) | ||
|
||
add_subdirectory(modules) | ||
|
||
add_subdirectory(samples) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
Microsoft Azure IoT Gateway SDK | ||
Copyright (c) Microsoft Corporation | ||
|
||
MIT license | ||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the Software), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF | ||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND | ||
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE | ||
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION | ||
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION | ||
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. |
Oops, something went wrong.