mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-01 03:34:32 +02:00
ldgen: add traceback in case of exception
This commit is contained in:
@@ -17,6 +17,8 @@
|
|||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import os
|
import os
|
||||||
|
import traceback
|
||||||
|
import sys
|
||||||
|
|
||||||
from fragments import FragmentFileModel
|
from fragments import FragmentFileModel
|
||||||
from sdkconfig import SDKConfig
|
from sdkconfig import SDKConfig
|
||||||
@@ -95,6 +97,9 @@ def main():
|
|||||||
print("linker script generation failed for %s\nERROR: %s" % (input_file.name, e.message))
|
print("linker script generation failed for %s\nERROR: %s" % (input_file.name, e.message))
|
||||||
# Delete the file so the entire build will fail; and not use an outdated script.
|
# Delete the file so the entire build will fail; and not use an outdated script.
|
||||||
os.remove(output_file.name)
|
os.remove(output_file.name)
|
||||||
|
# Print traceback and exit
|
||||||
|
traceback.print_exc()
|
||||||
|
sys.exit(1)
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
main()
|
main()
|
Reference in New Issue
Block a user