1
0
mirror of https://github.com/eclipse/paho.mqtt.cpp.git synced 2025-05-09 03:11:23 +08:00

9 Commits

Author SHA1 Message Date
fpagliughi
a7e9b12042 #461 Updated license to EPL-v2.0 2023-11-18 14:01:59 -05:00
fmp
2cd0109a81 Updates to CMake build - removing vars, targets exporting include paths 2018-12-08 10:41:45 -05:00
Guilherme Maciel Ferreira
fe3d463516 Fix doxygen file
Remove deprecated tags and add the input documentation directory.

Signed-off-by: Guilherme Maciel Ferreira <guilherme.maciel.ferreira@gmail.com>
2017-04-12 14:10:32 -05:00
Frank Pagliughi
9d0a6a64a5 Merge pull request #8 from guilhermeferreira/build-cmake
Add support for the CMake build system
2017-04-03 23:14:43 -04:00
Guilherme Maciel Ferreira
5642eccf59 Join recursive Makefile.am in a top level Makefile.am
Recursive Makefiles are considered harmfull (http://aegis.sourceforge.net/auug97.pdf)

Signed-off-by: Guilherme Maciel Ferreira <guilherme.maciel.ferreira@gmail.com>
2017-04-03 18:11:17 -05:00
Guilherme Maciel Ferreira
2c2df375ec Add support for the Autotools build system
---------------------------------------------------------------------
 Advantages
---------------------------------------------------------------------

1. Automatically find the Paho MQTT C library. Which is required by
   Paho MQTT C++ library;

2. Detect if the doxygen program is available in order to build (or
   not) the documentation;

3. Detect if the compiler supports C++11;

4. Choose whether to build static, dynamic or both kinds of libraries;

5. Choose whether or not to build documentation or sample programs;

6. Easier cross compilation;

7. Adds standard make targets, like "install";

8. Automatic handling of portability issues. For example, library
   naming differs accross OS;

---------------------------------------------------------------------
 Build instructions
---------------------------------------------------------------------

The first step is to run the bootstrap script:

  $ ./bootstrap

Create the build directory, to build out-of-tree:

  $ mkdir mybuild && cd mybuild
  $ export PAHO_CPP_DIR=$PWD

Next, in order to build only the static library:

  $ $PAHO_CPP_DIR/configure --disable-shared --enable-static
  $ make

the commands above build

  libpaho-mqttpp3.a

Or, in order to build only the dynamic library:

  $ $PAHO_CPP_DIR/configure --enable-shared --disable-static
  $ make

the previous commands build:

  libpaho-mqttpp3.so.0.2

and its respective link and soname.

If the Paho MQTT C is installed on a non-standard directory, you can
provide the path to the configure script:

  $ $PAHO_CPP_DIR/configure --with-paho-mqtt-c=/opt/paho.mqtt.c/

---------------------------------------------------------------------
 Remarks
---------------------------------------------------------------------

The regular Make version is around 2.5 times faster than the Autotools
version. The overall time for Autotools include the time of bootstrap,
configure and make. The regular Make time include only the make command.

Remove the .dep files from "src/obj/" directory. The "make" sets its
current directory to "src/obj/" in order to compile. And "make" does
find the libtool script, because its current directory should be "src/".

Successfully built on with C++11 restriction:
- Ubuntu 10.04 (x86 32-bit) with g++ 4.8.2, GNU libc 2.11.1 and libstdc++ 6.0.13;
- Fedora 23.10 (64-bit) with g++ 5.3.1, GNU libc 2.22 and libstdc++ 6.0.21;
- FreeBSD 10.3 (64-bit) with clang++ 3.4.1;

Signed-off-by: Guilherme Maciel Ferreira <guilherme.maciel.ferreira@gmail.com>
2017-04-03 18:10:10 -05:00
Guilherme Maciel Ferreira
5bd965791e Add support for the CMake build system
CMake is an open-source, cross-platform tool designed to build, test
and package software. CMake controls the software compilation using
simple platform and compiler independent configuration files, and
generate native makefiles and workspaces that can be used in compiler
environments like Windows, Mac OS, BSD and Linux.

---------------------------------------------------------------------
 Build instructions
---------------------------------------------------------------------

On Unix or GNU Linux, build out of tree passing the Paho MQTT C
directory:

  $ mkdir build
  $ cd build
  $ cmake -DPAHO_MQTT_C_PATH=/tmp/paho-c ..

On Windows, open the CMake GUI and "configure" the Visual Studio
build. On the GUI interface, set the PAHO_MQTT_C_PATH and "generate"
the build files.

---------------------------------------------------------------------
 Remarks
---------------------------------------------------------------------

Successfully built on with C++11 restriction:
- Windows 7 SP1 (64-bit) with Visual Studio/C++ 14 (2015);
- Fedora 23.10 (64-bit) with g++ 5.3.1, libc 2.22 and libstdc++ 6.0.21;
- Fedora 23.10 (64-bit) with clang++ 3.7.0, libc 2.22 and libstdc++ 6.0.21;
- FreeBSD 10.3 (64-bit) with clang++ 3.4.1;

Signed-off-by: Guilherme Maciel Ferreira <guilherme.maciel.ferreira@gmail.com>
2017-04-03 12:30:32 -05:00
Frank Pagliughi
5a96f84f91 Added response_options classes to simplify the async_client.
Created non-heap publish in sync_client.
2016-08-26 20:27:37 -04:00
Frank Pagliughi
62fce2e106 Initial commit 2014-03-27 14:54:25 +00:00