Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nanopb/nanopb.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/pb.h
diff options
context:
space:
mode:
authorPetteri Aimonen <jpa@git.mail.kapsi.fi>2013-03-09 16:56:34 +0400
committerPetteri Aimonen <jpa@git.mail.kapsi.fi>2013-03-09 16:56:34 +0400
commit03e53930723dce5793678365f350e94c2bc358dc (patch)
tree2aac5d81701efb541c77fe1bfbc738a531f21aff /pb.h
parentd580b225e859ef0462e1d96553003eff2793b796 (diff)
Add PB_SYSTEM_HEADER compile time option.
This allows replacing the C99 standard include file names with a single system-specific file. It should provide all the necessary system functions (typedefs, memset, memcpy, strlen). Update issue 62 Status: FixedInGit
Diffstat (limited to 'pb.h')
-rw-r--r--pb.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/pb.h b/pb.h
index b12debe..138c6bb 100644
--- a/pb.h
+++ b/pb.h
@@ -8,9 +8,14 @@
#define NANOPB_VERSION nanopb-0.2.1-dev
+#ifdef PB_SYSTEM_HEADER
+#include PB_SYSTEM_HEADER
+#else
#include <stdint.h>
#include <stddef.h>
#include <stdbool.h>
+#include <string.h>
+#endif
#ifdef __GNUC__
/* This just reduces memory requirements, but is not required. */