mongoose/docs/build-options/intro.md
Sergey Lyubka b7a0748312 Ditch JSON-RPC from mongoose
PUBLISHED_FROM=89b978c02be2f10eb930ff13673d45249fd67763
2016-07-01 11:35:18 +00:00

23 lines
801 B
Markdown

---
title: Build Options
items:
- { type: file, name: enabling-flags.md }
- { type: file, name: disabling-flags.md }
- { type: file, name: platform-spec.md }
- { type: file, name: tunables.md }
---
Mongoose source code ships in a single .c file that contains functionality
for all supported protocols (modules). Modules can be disabled at compile
time which reduces executable size. That can be done by setting preprocessor
flags. Also, some preprocessor flags can be used to tune internal Mongoose
parameters.
To set a preprocessor flag during compile time, use `-D <PREPROCESSOR_FLAG>`
compiler option. For example, to disable both MQTT and COAP,
compile the application `my_app.c` like this (assumed UNIX system):
```
$ cc my_app.c mongoose.c -D MG_DISABLE_MQTT -D MG_DISABLE_COAP
```