Skip to content
General purpose library for communication over the mqtt protocol
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
build yaml build script Oct 26, 2018
build_all Release_2018_05_04 after bump version script May 7, 2018
configs
deps Update c-shared util repo (#40) Mar 5, 2019
devdoc/requirement_docs ACR Add _getTopicLevels to mqttmessage Nov 20, 2018
inc/azure_umqtt_c ACR Add _getTopicLevels to mqttmessage Nov 20, 2018
jenkins
samples New deps and have compileAs per target Nov 8, 2018
src
tests
tools
.gitignore
.gitmodules
CMakeLists.txt
LICENSE
dependencies-test.cmake
dependencies.cmake
readme.md
version.txt changing mqtt %zu to %ld for mbed (#33) Jan 11, 2019

readme.md

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.

Microsoft Azure MQTT

azure-umqtt-c is a general purpose library build for MQTT protocol

Dependencies

azure-mqtt client use the azure-c-shared-utility, which is a C library provisioning common functionality for basic tasks (like string, list manipulation, IO, etc.). azure-c-shared-utility is available here: https://github.com/Azure/azure-c-shared-utility. azure-c-shared-utility needs to be built before building azure-mqtt-c.

Setup

Build

  • Clone azure-umqtt-c by:
git clone --recursive https://github.com/Azure/azure-umqtt-c.git
  • Create a folder cmake under azure-umqtt-c

  • Switch to the cmake folder and run

cmake ..
  • Build
cmake --build .

Installation and Use

Optionally, you may choose to install azure-umqtt-c on your machine:

  1. Switch to the cmake folder and run

    cmake -Duse_installed=ON ../
    
    cmake --build . --target install
    

    or install using the follow commands for each platform:

    On Linux:

    sudo make install
    

    On Windows:

    msbuild /m INSTALL.vcxproj
    
  2. Use it in your project (if installed)

    find_package(umqtt REQUIRED CONFIG)
    target_link_library(yourlib umqtt)
    

This requires that azure-c-shared-utility is installed (through CMake) on your machine.

If running tests, this requires that umock-c, azure-ctest, and azure-c-testrunnerswitcher are installed (through CMake) on your machine.

Building the tests

In order to build the tests use:

cmake .. -Drun_unittests:bool=ON
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.