Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
mongoose
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
esp
mongoose
Commits
b298d46a
Commit
b298d46a
authored
Oct 13, 2016
by
Deomid Ryabkov
Committed by
Cesanta Bot
Oct 13, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MG_DISABLE_MQTT -> MG_ENABLE_MQTT
PUBLISHED_FROM=34e6028b68e286f81be7ba0f8ae73b760f144131
parent
75059d1b
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
17 additions
and
10 deletions
+17
-10
disabling-flags.md
docs/overview/build-options/disabling-flags.md
+0
-1
enabling-flags.md
docs/overview/build-options/enabling-flags.md
+3
-1
Makefile
examples/mqtt_client/Makefile
+1
-1
mongoose.c
mongoose.c
+3
-3
mongoose.h
mongoose.h
+10
-4
No files found.
docs/overview/build-options/disabling-flags.md
View file @
b298d46a
...
...
@@ -4,7 +4,6 @@ title: Disabling flags
-
`MG_DISABLE_HTTP_WEBSOCKET`
disable HTTP + WebSocket protocol support
-
`MG_DISABLE_HTTP_DIGEST_AUTH`
disable HTTP Digest (MD5) authorisation support
-
`MG_DISABLE_MQTT`
disable MQTT support
-
`MG_DISABLE_SHA1`
disable SHA1 support (used by WebSocket)
-
`MG_DISABLE_MD5`
disable MD5 support (used by HTTP auth)
-
`MG_DISABLE_SOCKETPAIR`
disable
`mg_broadcast()`
API
...
...
docs/overview/build-options/enabling-flags.md
View file @
b298d46a
...
...
@@ -2,9 +2,11 @@
title
:
Enabling flags
---
-
`MG_ENABLE_SSL`
Enable OpenSSL support
-
`MG_ENABLE_CGI`
Enable CGI support
-
`MG_ENABLE_SSL`
Enable SSL/TLS support (OpenSSL API)
-
`MG_ENABLE_IPV6`
Enable IPV6 support
-
`MG_ENABLE_THREADS`
enable
`mg_start_thread()`
API
-
`MG_ENABLE_MQTT`
enable MQTT client
-
`MG_ENABLE_MQTT_BROKER`
enable MQTT broker
-
`MG_ENABLE_DNS_SERVER`
enable DNS server
-
`MG_ENABLE_COAP`
enable CoAP protocol
...
...
examples/mqtt_client/Makefile
View file @
b298d46a
PROG
=
mqtt_client
MODULE_CFLAGS
=
-DMG_ENABLE_MQTT
_BROKER
MODULE_CFLAGS
=
-DMG_ENABLE_MQTT
SSL_LIB
=
openssl
include
../examples.mk
mongoose.c
View file @
b298d46a
...
...
@@ -109,7 +109,7 @@ struct ctl_msg {
char
message
[
MG_CTL_MSG_MESSAGE_SIZE
];
};
#if
!MG_DIS
ABLE_MQTT
#if
MG_EN
ABLE_MQTT
struct
mg_mqtt_message
;
MG_INTERNAL
int
parse_mqtt
(
struct
mbuf
*
io
,
struct
mg_mqtt_message
*
mm
);
#endif
...
...
@@ -7979,7 +7979,7 @@ int mg_match_prefix(const char *pattern, int pattern_len, const char *str) {
* All rights reserved
*/
#if
!MG_DIS
ABLE_MQTT
#if
MG_EN
ABLE_MQTT
#include <string.h>
...
...
@@ -8293,7 +8293,7 @@ void mg_mqtt_disconnect(struct mg_connection *nc) {
mg_mqtt_prepend_header
(
nc
,
MG_MQTT_CMD_DISCONNECT
,
0
,
0
);
}
#endif
/* MG_
DIS
ABLE_MQTT */
#endif
/* MG_
EN
ABLE_MQTT */
#ifdef MG_MODULE_LINES
#line 1 "mongoose/src/mqtt_server.c"
#endif
...
...
mongoose.h
View file @
b298d46a
...
...
@@ -1219,10 +1219,6 @@ const char *c_strnstr(const char *s, const char *find, size_t slen);
#define MG_DISABLE_DAV 0
#endif
#ifndef MG_DISABLE_MQTT
#define MG_DISABLE_MQTT 0
#endif
#ifndef MG_DISABLE_PFS
#define MG_DISABLE_PFS 0
#endif
...
...
@@ -1287,6 +1283,10 @@ const char *c_strnstr(const char *s, const char *find, size_t slen);
#define MG_ENABLE_JAVASCRIPT 0
#endif
#ifndef MG_ENABLE_MQTT
#define MG_ENABLE_MQTT 0
#endif
#ifndef MG_ENABLE_MQTT_BROKER
#define MG_ENABLE_MQTT_BROKER 0
#endif
...
...
@@ -1322,6 +1322,12 @@ const char *c_strnstr(const char *s, const char *find, size_t slen);
#define MG_DISABLE_SOCKETPAIR 1
#endif
/* MG_NO_BSD_SOCKETS */
/* MQTT broker requires MQTT */
#if MG_ENABLE_MQTT_BROKER && !MG_ENABLE_MQTT
#undef MG_ENABLE_MQTT
#define MG_ENABLE_MQTT 1
#endif
#endif
/* CS_MONGOOSE_SRC_FEATURES_H_ */
#ifdef MG_MODULE_LINES
#line 1 "mongoose/src/net.h"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment