Merge branch 'refactor/ldgen' into 'master'

refactor: ldgen

Closes IDF-605 and IDFGH-6271

See merge request espressif/esp-idf!16509
This commit is contained in:
Fu Hanxi
2022-01-10 09:15:44 +00:00
32 changed files with 951 additions and 1729 deletions

View File

@@ -11,26 +11,21 @@ else
elf_dir=$1
fi
if ! command -v coverage &> /dev/null; then
echo "coverage could not be found, please install it ('pip install coverage')"
exit 1
fi
SUPPORTED_TARGETS=("esp32" "esp32s2" "esp32c3" "esp32s3" )
res=0
coverage erase
python -m coverage erase
for chip in "${SUPPORTED_TARGETS[@]}"; do
{
echo "run b64 decoding tests on $chip"
coverage run -a --source=corefile ../espcoredump.py --chip="$chip" --gdb-timeout-sec 5 info_corefile -m -t b64 -c "${chip}/coredump.b64" -s "${chip}/core.elf" "${elf_dir}/${chip}.elf" &>"${chip}/output" &&
python -m coverage run -a --source=corefile ../espcoredump.py --chip="$chip" --gdb-timeout-sec 5 info_corefile -m -t b64 -c "${chip}/coredump.b64" -s "${chip}/core.elf" "${elf_dir}/${chip}.elf" &>"${chip}/output" &&
diff "${chip}/expected_output" "${chip}/output" &&
coverage run -a --source=corefile ../espcoredump.py --chip="$chip" --gdb-timeout-sec 5 info_corefile -m -t elf -c "${chip}/core.elf" "${elf_dir}/${chip}.elf" &>"${chip}/output2" &&
python -m coverage run -a --source=corefile ../espcoredump.py --chip="$chip" --gdb-timeout-sec 5 info_corefile -m -t elf -c "${chip}/core.elf" "${elf_dir}/${chip}.elf" &>"${chip}/output2" &&
diff "${chip}/expected_output" "${chip}/output2"
} || {
echo 'The test for espcoredump has failed!'
res=1
}
done
coverage run -a --source=corefile ./test_espcoredump.py
coverage report ../corefile/*.py ../espcoredump.py
python -m coverage run -a --source=corefile ./test_espcoredump.py
python -m coverage report ../corefile/*.py ../espcoredump.py
exit $res

View File

@@ -1,17 +1,10 @@
// Copyright 2020 Espressif Systems (Shanghai) CO LTD
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
/*
* SPDX-FileCopyrightText: 2020-2022 Espressif Systems (Shanghai) CO LTD
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <features.h>
#include "esp_netif_lwip_internal.h"
esp_err_t esp_netif_get_ip_info(esp_netif_t *esp_netif, esp_netif_ip_info_t *ip_info)

View File

@@ -3,3 +3,4 @@
#define __warning__ deprecated
#define IRAM_ATTR
#define __ESP_ATTR_H__
#include <features.h>

View File

@@ -1,16 +1,8 @@
// Copyright 2015-2016 Espressif Systems (Shanghai) PTE LTD
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
/*
* SPDX-FileCopyrightText: 2015-2022 Espressif Systems (Shanghai) CO LTD
*
* SPDX-License-Identifier: Apache-2.0
*/
#ifndef _ESP32_COMPAT_H_
#define _ESP32_COMPAT_H_
@@ -20,6 +12,7 @@
#define _ESP_TASK_H_
#ifdef USE_BSD_STRING
#include <features.h>
#include <bsd/string.h>
#endif
#include <stdint.h>