blob: 4ff88b4cad570af0d349a93856db009fe96de846 [file] [log] [blame]
Manuel Pégourié-Gonnard63e7eba2015-07-28 14:17:48 +02001#!/bin/sh
Bence Szépkútib7246ad2020-05-26 00:33:31 +02002#
3# Copyright (C) 2015-2016, Arm Limited, All Rights Reserved
Bence Szépkúti09b4f192020-05-26 01:54:15 +02004# SPDX-License-Identifier: Apache-2.0
5#
6# Licensed under the Apache License, Version 2.0 (the "License"); you may
7# not use this file except in compliance with the License.
8# You may obtain a copy of the License at
9#
10# http://www.apache.org/licenses/LICENSE-2.0
11#
12# Unless required by applicable law or agreed to in writing, software
13# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
14# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15# See the License for the specific language governing permissions and
16# limitations under the License.
Bence Szépkútib7246ad2020-05-26 00:33:31 +020017#
18# This file is part of Mbed TLS (https://tls.mbed.org)
Manuel Pégourié-Gonnard63e7eba2015-07-28 14:17:48 +020019
20set -eu
21
22if [ $# -ne 2 ]; then
23 echo "Usage: $0 path/to/config.pl path/to/config.h" >&2
24 exit 1
25fi
26
27SCRIPT=$1
28FILE=$2
29
30conf() {
31 $SCRIPT -f $FILE $@
32}
33
Simon Butcherb2c81b12016-06-23 13:56:06 +010034
35# Set the target specific header
Simon Butcher1d46a2d2016-07-11 10:17:03 +010036conf set YOTTA_CFG_MBEDTLS_TARGET_CONFIG_FILE \"mbedtls/target_config.h\"
Simon Butcherb2c81b12016-06-23 13:56:06 +010037
Manuel Pégourié-Gonnard0adc7f72015-07-31 17:50:00 +020038# not supported on mbed OS, nor used by mbed Client
Manuel Pégourié-Gonnard63e7eba2015-07-28 14:17:48 +020039conf unset MBEDTLS_NET_C
40conf unset MBEDTLS_TIMING_C
41
Manuel Pégourié-Gonnard0adc7f72015-07-31 17:50:00 +020042# not supported on all targets with mbed OS, nor used by mbed Client
43conf unset MBEDTLS_FS_IO
44
Manuel Pégourié-Gonnard63e7eba2015-07-28 14:17:48 +020045conf unset MBEDTLS_CIPHER_MODE_CFB
46conf unset MBEDTLS_CIPHER_MODE_CTR
47conf unset MBEDTLS_CIPHER_PADDING_ONE_AND_ZEROS
48conf unset MBEDTLS_CIPHER_PADDING_ZEROS_AND_LEN
49conf unset MBEDTLS_CIPHER_PADDING_ZEROS
50conf unset MBEDTLS_ECP_DP_SECP192R1_ENABLED
51conf unset MBEDTLS_ECP_DP_SECP224R1_ENABLED
52conf unset MBEDTLS_ECP_DP_SECP521R1_ENABLED
53conf unset MBEDTLS_ECP_DP_SECP192K1_ENABLED
54conf unset MBEDTLS_ECP_DP_SECP224K1_ENABLED
55conf unset MBEDTLS_ECP_DP_SECP256K1_ENABLED
56conf unset MBEDTLS_ECP_DP_BP256R1_ENABLED
57conf unset MBEDTLS_ECP_DP_BP384R1_ENABLED
58conf unset MBEDTLS_ECP_DP_BP512R1_ENABLED
59conf unset MBEDTLS_PK_PARSE_EC_EXTENDED
60
61conf unset MBEDTLS_AESNI_C
62conf unset MBEDTLS_ARC4_C
63conf unset MBEDTLS_BLOWFISH_C
64conf unset MBEDTLS_CAMELLIA_C
65conf unset MBEDTLS_DES_C
66conf unset MBEDTLS_DHM_C
67conf unset MBEDTLS_GENPRIME
68conf unset MBEDTLS_MD5_C
69conf unset MBEDTLS_PADLOCK_C
70conf unset MBEDTLS_PEM_WRITE_C
71conf unset MBEDTLS_PKCS5_C
72conf unset MBEDTLS_PKCS12_C
73conf unset MBEDTLS_RIPEMD160_C
Manuel Pégourié-Gonnardc5e03722015-07-28 17:09:42 +020074conf unset MBEDTLS_SHA1_C
Manuel Pégourié-Gonnard63e7eba2015-07-28 14:17:48 +020075conf unset MBEDTLS_XTEA_C
76
77conf unset MBEDTLS_X509_RSASSA_PSS_SUPPORT
78
79conf unset MBEDTLS_X509_CSR_PARSE_C
80conf unset MBEDTLS_X509_CREATE_C
81conf unset MBEDTLS_X509_CRT_WRITE_C
82conf unset MBEDTLS_X509_CSR_WRITE_C
83
84conf unset MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED
85conf unset MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED
86conf unset MBEDTLS_KEY_EXCHANGE_RSA_ENABLED
87conf unset MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED
88conf unset MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED
89conf unset MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED
90conf unset MBEDTLS_SSL_FALLBACK_SCSV
91conf unset MBEDTLS_SSL_CBC_RECORD_SPLITTING
Manuel Pégourié-Gonnard63e7eba2015-07-28 14:17:48 +020092conf unset MBEDTLS_SSL_PROTO_TLS1
93conf unset MBEDTLS_SSL_PROTO_TLS1_1
94conf unset MBEDTLS_SSL_TRUNCATED_HMAC