|
1 | | -#!/bin/python3 |
| 1 | +#!/bin/env python3 |
2 | 2 | import re |
3 | 3 | import json |
4 | 4 | import glob |
@@ -323,12 +323,16 @@ def update_openocd_config(file_path, **kwargs): |
323 | 323 | board_timer_freq = None |
324 | 324 | board_irqmax = None |
325 | 325 |
|
| 326 | + board_cpucore = "ux900fd" |
326 | 327 | try: |
327 | 328 | cust_file = args.custsoc |
328 | 329 |
|
329 | 330 | with open(args.conf, 'r') as conf_file: |
330 | 331 | conf_data = json.load(conf_file) |
331 | 332 |
|
| 333 | + if 'cpu_config' in conf_data: |
| 334 | + board_cpucore = conf_data['cpu_config'].get("core", "ux900fd") |
| 335 | + |
332 | 336 | if 'general_config' in conf_data: |
333 | 337 | general_config = conf_data['general_config'] |
334 | 338 | if 'ddr' in general_config: |
@@ -557,10 +561,10 @@ def update_openocd_config(file_path, **kwargs): |
557 | 561 |
|
558 | 562 | print("\n===generate successfully!===\n") |
559 | 563 | print("Here are the reference build commands for compiling Linux SDK for you:") |
560 | | - print("$cd ..") |
561 | | - print("$make SOC=%s CORE=ux900fd BOOT_MODE=sd freeloader bootimages" % args.custsoc) |
562 | | - print("$make SOC=%s CORE=ux900fd BOOT_MODE=sd run_qemu" % args.custsoc) |
563 | | - print("Please adjust the compilation parameters according to your real environment.") |
| 564 | + print("$ cd ..") |
| 565 | + print("$ make SOC=%s CORE=%s BOOT_MODE=sd freeloader bootimages" % (args.custsoc, board_cpucore)) |
| 566 | + print("$ make SOC=%s CORE=%s BOOT_MODE=sd run_qemu" % (args.custsoc, board_cpucore)) |
| 567 | + print("Please adjust the compilation parameters according to your real hardware environment.") |
564 | 568 | except Exception as e: |
565 | 569 | print(f'Exception occur: {e}') |
566 | 570 | # back to orgin working directory,remote generated files |
|
0 commit comments