Tools: add Python 2 deprecation warning

This commit is contained in:
martin.gano
2020-11-04 23:32:40 +01:00
parent 66416d1a8b
commit f4ea2dcb74
12 changed files with 88 additions and 11 deletions

View File

@@ -5,7 +5,9 @@
# Copyright (c) 2016-2017 Espressif Systems (Shanghai) PTE LTD.
# Distributed under the terms of Apache License v2.0 found in the top-level LICENSE file.
from __future__ import print_function
from optparse import OptionParser
import sys
BASE_ADDR = 0x50000000
@@ -41,6 +43,10 @@ def gen_ld_h_from_sym_riscv(f_sym, f_ld, f_h):
def main():
if sys.version_info[0] < 3:
print("WARNING: Support for Python 2 is deprecated and will be removed in future versions.", file=sys.stderr)
elif sys.version_info[0] == 3 and sys.version_info[1] < 6:
print("WARNING: Python 3 versions older than 3.6 are not supported.", file=sys.stderr)
description = ("This application generates .h and .ld files for symbols defined in input file. "
"The input symbols file can be generated using nm utility like this: "
"esp32-ulp-nm -g -f posix <elf_file> > <symbols_file>")