From 62456b3b7fcdcd1979fe56a591d92f7f39201217 Mon Sep 17 00:00:00 2001 From: "Roger A. Light" Date: Sun, 25 Jan 2015 11:52:10 +0000 Subject: [PATCH] Add more details on how to build Mosquitto. Explains more of the differences between the Makefiles and the CMake scripts. --- CMakeLists.txt | 6 +++++- Makefile | 4 ++++ config.mk | 4 ++++ 3 files changed, 13 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 948c4192..4eeac6d6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,8 @@ -# This is a cmake script. +# This is a cmake script. Process it with the CMake gui or command line utility +# to produce makefiles / Visual Studio project files on Mac OS X and Windows. +# +# To configure the build options either use the CMake gui, or run the command +# line utility including the "-i" option. set(CMAKE_LEGACY_CYGWIN_WIN32 0) diff --git a/Makefile b/Makefile index 909de294..d147da89 100644 --- a/Makefile +++ b/Makefile @@ -14,6 +14,10 @@ docs : binary : mosquitto mosquitto : +ifeq ($(UNAME),Darwin) + $(error Please compile using CMake on Mac OS X) +endif + set -e; for d in ${DIRS}; do $(MAKE) -C $${d}; done clean : diff --git a/config.mk b/config.mk index 8fc8ff65..2c3c7d19 100644 --- a/config.mk +++ b/config.mk @@ -1,6 +1,9 @@ # ============================================================================= # User configuration section. # +# These options control compilation on all systems apart from Windows and Mac +# OS X. Use CMake to compile on Windows and Mac. +# # Largely, these are options that are designed to make mosquitto run more # easily in restrictive environments by removing features. # @@ -94,6 +97,7 @@ DB_HTML_XSL=man/html.xsl #MANCOUNTRIES=en_GB UNAME:=$(shell uname -s) + ifeq ($(UNAME),SunOS) ifeq ($(CC),cc) CFLAGS?=-O