forked from particle-iot/tinydtls
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Include header platform-specific/platform.h at end of dtls_config.h
The new header platform-specific/platform.h contains Contiki-specific settings such as sizes of memory pools and includes target-specific definitions. Previously, this has been done in dtls_config.h, but as autoreconf creates a new dtls_config.h.in, these adjustments were lost.
- Loading branch information
Showing
2 changed files
with
70 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
# -*- Autoconf -*- | ||
# Process this file with autoconf to produce a configure script. | ||
# | ||
# Copyright (C) 2011--2014 Olaf Bergmann <[email protected]> | ||
# Copyright (C) 2011--2015 Olaf Bergmann <[email protected]> | ||
# | ||
# Permission is hereby granted, free of charge, to any person | ||
# obtaining a copy of this software and associated documentation | ||
|
@@ -24,7 +24,7 @@ | |
# SOFTWARE. | ||
|
||
AC_PREREQ([2.65]) | ||
AC_INIT([tinydtls], [0.8.1]) | ||
AC_INIT([tinydtls], [0.8.2]) | ||
AC_CONFIG_SRCDIR([dtls.c]) | ||
dnl AC_CONFIG_HEADERS([config.h]) | ||
|
||
|
@@ -103,6 +103,12 @@ fi | |
|
||
AC_CONFIG_HEADERS([dtls_config.h tinydtls.h]) | ||
|
||
# Adds Contiki-specific definitions to the end of dtls_config.h | ||
AH_BOTTOM([ | ||
#ifdef WITH_CONTIKI | ||
#include "platform-specific/platform.h" | ||
#endif]) | ||
|
||
AC_CONFIG_FILES([Makefile | ||
doc/Makefile | ||
doc/Doxyfile | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
/************************************************************************/ | ||
/* Contiki-specific parameters */ | ||
/************************************************************************/ | ||
|
||
#ifndef _PLATFORM_H_ | ||
#define _PLATFORM_H_ 1 | ||
|
||
#ifdef CONTIKI | ||
#include "contiki.h" | ||
#include "contiki-lib.h" | ||
#include "contiki-net.h" | ||
|
||
#include "contiki-conf.h" | ||
|
||
/* global constants for constrained devices running Contiki */ | ||
#ifndef DTLS_PEER_MAX | ||
/** The maximum number DTLS peers (i.e. sessions). */ | ||
# define DTLS_PEER_MAX 1 | ||
#endif | ||
|
||
#ifndef DTLS_HANDSHAKE_MAX | ||
/** The maximum number of concurrent DTLS handshakes. */ | ||
# define DTLS_HANDSHAKE_MAX 1 | ||
#endif | ||
|
||
#ifndef DTLS_SECURITY_MAX | ||
/** The maximum number of concurrently used cipher keys */ | ||
# define DTLS_SECURITY_MAX (DTLS_PEER_MAX + DTLS_HANDSHAKE_MAX) | ||
#endif | ||
|
||
#ifndef DTLS_HASH_MAX | ||
/** The maximum number of hash functions that can be used in parallel. */ | ||
# define DTLS_HASH_MAX (3 * DTLS_PEER_MAX) | ||
#endif | ||
|
||
/************************************************************************/ | ||
/* Specific Contiki platforms */ | ||
/************************************************************************/ | ||
|
||
#if CONTIKI_TARGET_ECONOTAG | ||
# include "platform-specific/config-econotag.h" | ||
#endif /* CONTIKI_TARGET_ECONOTAG */ | ||
|
||
#ifdef CONTIKI_TARGET_CC2538DK | ||
# include "platform-specific/config-cc2538dk.h" | ||
#endif /* CONTIKI_TARGET_CC2538DK */ | ||
|
||
#ifdef CONTIKI_TARGET_WISMOTE | ||
# include "platform-specific/config-wismote.h" | ||
#endif /* CONTIKI_TARGET_WISMOTE */ | ||
|
||
#ifdef CONTIKI_TARGET_SKY | ||
# include "platform-specific/config-sky.h" | ||
#endif /* CONTIKI_TARGET_SKY */ | ||
|
||
#ifdef CONTIKI_TARGET_MINIMAL_NET | ||
# include "platform-specific/config-minimal-net.h" | ||
#endif /* CONTIKI_TARGET_MINIMAL_NET */ | ||
|
||
#endif /* CONTIKI */ | ||
|
||
#endif /* _PLATFORM_H_ */ |