init comm для настройки переменных для отладки
This commit is contained in:
commit
2e9592ffbb
BIN
.out/scanVars.exe
Normal file
BIN
.out/scanVars.exe
Normal file
Binary file not shown.
732
.out/scanVars0.py
Normal file
732
.out/scanVars0.py
Normal file
@ -0,0 +1,732 @@
|
||||
# pyinstaller --onefile --distpath . --workpath ./build --specpath ./build scanVars.py
|
||||
import sys
|
||||
import os
|
||||
import re
|
||||
import argparse
|
||||
from pathlib import Path
|
||||
|
||||
|
||||
# === Словарь соответствия типов XML → DebugVarType_t ===
|
||||
type_map = dict([
|
||||
*[(k, 'pt_int8') for k in ('signed char', 'char')],
|
||||
*[(k, 'pt_int16') for k in ('int', 'int16', 'short')],
|
||||
*[(k, 'pt_int32') for k in ('long', 'int32', '_iqx')],
|
||||
*[(k, 'pt_int64') for k in ('long long', 'int64')],
|
||||
|
||||
*[(k, 'pt_uint8') for k in ('unsigned char',)],
|
||||
*[(k, 'pt_uint16') for k in ('unsigned int', 'unsigned short', 'Uint16')],
|
||||
*[(k, 'pt_uint32') for k in ('unsigned long', 'Uint32')],
|
||||
*[(k, 'pt_uint64') for k in ('unsigned long long', 'Uint64')],
|
||||
|
||||
*[(k, 'pt_ptr_int8') for k in ('signed char*',)],
|
||||
*[(k, 'pt_ptr_int16') for k in ('int*', 'short*')],
|
||||
*[(k, 'pt_ptr_int32') for k in ('long*',)],
|
||||
*[(k, 'pt_ptr_uint8') for k in ('unsigned char*',)],
|
||||
*[(k, 'pt_ptr_uint16') for k in ('unsigned int*', 'unsigned short*')],
|
||||
*[(k, 'pt_ptr_uint32') for k in ('unsigned long*',)],
|
||||
('unsigned long long*', 'pt_int64'),
|
||||
|
||||
*[(k, 'pt_arr_int8') for k in ('signed char[]',)],
|
||||
*[(k, 'pt_arr_int16') for k in ('int[]', 'short[]')],
|
||||
*[(k, 'pt_arr_int32') for k in ('long[]',)],
|
||||
*[(k, 'pt_arr_uint8') for k in ('unsigned char[]',)],
|
||||
*[(k, 'pt_arr_uint16') for k in ('unsigned int[]', 'unsigned short[]')],
|
||||
*[(k, 'pt_arr_uint32') for k in ('unsigned long[]',)],
|
||||
|
||||
*[(k, 'pt_float') for k in ('float', 'float32')],
|
||||
|
||||
('struct', 'pt_struct'),
|
||||
('union', 'pt_union'),
|
||||
])
|
||||
|
||||
def parse_makefile(makefile_path):
|
||||
makefile_dir = os.path.dirname(makefile_path)
|
||||
project_root = os.path.dirname(makefile_dir) # поднялись из Debug
|
||||
|
||||
with open(makefile_path, 'r', encoding='utf-8') as f:
|
||||
lines = f.readlines()
|
||||
|
||||
objs_lines = []
|
||||
collecting = False
|
||||
|
||||
for line in lines:
|
||||
stripped = line.strip()
|
||||
if stripped.startswith("ORDERED_OBJS") and "+=" in stripped:
|
||||
parts = stripped.split("\\")
|
||||
first_part = parts[0]
|
||||
idx = first_part.find("+=")
|
||||
tail = first_part[idx+2:].strip()
|
||||
if tail:
|
||||
objs_lines.append(tail)
|
||||
collecting = True
|
||||
if len(parts) > 1:
|
||||
for p in parts[1:]:
|
||||
p = p.strip()
|
||||
if p:
|
||||
objs_lines.append(p)
|
||||
continue
|
||||
|
||||
if collecting:
|
||||
if stripped.endswith("\\"):
|
||||
objs_lines.append(stripped[:-1].strip())
|
||||
else:
|
||||
objs_lines.append(stripped)
|
||||
collecting = False
|
||||
|
||||
objs_str = ' '.join(objs_lines)
|
||||
|
||||
objs_str = re.sub(r"\$\([^)]+\)", "", objs_str)
|
||||
|
||||
objs = []
|
||||
for part in objs_str.split():
|
||||
part = part.strip()
|
||||
if part.startswith('"') and part.endswith('"'):
|
||||
part = part[1:-1]
|
||||
if part:
|
||||
objs.append(part)
|
||||
|
||||
c_files = []
|
||||
include_dirs = set()
|
||||
|
||||
for obj_path in objs:
|
||||
if "DebugTools" in obj_path:
|
||||
continue
|
||||
if "v120" in obj_path:
|
||||
continue
|
||||
|
||||
if obj_path.startswith("Debug\\") or obj_path.startswith("Debug/"):
|
||||
rel_path = obj_path.replace("Debug\\", "Src\\").replace("Debug/", "Src/")
|
||||
else:
|
||||
rel_path = obj_path
|
||||
|
||||
abs_path = os.path.normpath(os.path.join(project_root, rel_path))
|
||||
|
||||
root, ext = os.path.splitext(abs_path)
|
||||
if ext.lower() == ".obj":
|
||||
c_path = root + ".c"
|
||||
else:
|
||||
c_path = abs_path
|
||||
|
||||
# Сохраняем только .c файлы
|
||||
if c_path.lower().endswith(".c"):
|
||||
c_files.append(c_path)
|
||||
dir_path = os.path.dirname(c_path)
|
||||
if dir_path and "DebugTools" not in dir_path:
|
||||
include_dirs.add(dir_path)
|
||||
|
||||
return c_files, sorted(include_dirs)
|
||||
|
||||
# Шаблон для поиска глобальных переменных
|
||||
# Пример: int varname;
|
||||
# Пропускаем строки с static и функции
|
||||
VAR_PATTERN = re.compile(
|
||||
r'^\s*(?!static)(\w[\w\s\*]+)\s+(\w+)\s*(=\s*[^;]+)?\s*;',
|
||||
re.MULTILINE)
|
||||
EXTERN_PATTERN = re.compile(
|
||||
r'^\s*extern\s+[\w\s\*]+\s+(\w+)\s*;',
|
||||
re.MULTILINE)
|
||||
|
||||
|
||||
TYPEDEF_PATTERN = re.compile(
|
||||
r'typedef\s+(struct|union)?\s*(\w+)?\s*{[^}]*}\s*(\w+)\s*;', re.DOTALL)
|
||||
|
||||
TYPEDEF_SIMPLE_PATTERN = re.compile(
|
||||
r'typedef\s+(.+?)\s+(\w+)\s*;', re.DOTALL)
|
||||
|
||||
def map_type_to_pt(typename, varname):
|
||||
typename = typename.strip()
|
||||
|
||||
# Убираем const и volatile, где бы они ни были (например, "const volatile int")
|
||||
for qualifier in ('const', 'volatile'):
|
||||
typename = typename.replace(qualifier, '')
|
||||
|
||||
typename = typename.strip() # снова убрать лишние пробелы после удаления
|
||||
|
||||
# Раскрутка через typedef
|
||||
resolved_type = typedef_aliases.get(typename, typename)
|
||||
|
||||
# Прямая проверка
|
||||
if resolved_type in type_map:
|
||||
return type_map[resolved_type]
|
||||
|
||||
if resolved_type.startswith('struct'):
|
||||
return type_map['struct']
|
||||
if resolved_type.startswith('union'):
|
||||
return type_map['union']
|
||||
|
||||
if '_iq' in resolved_type and '_iqx' in type_map:
|
||||
return type_map['_iqx']
|
||||
|
||||
return 'pt_unknown'
|
||||
|
||||
def get_iq_define(vtype):
|
||||
if '_iq' in vtype:
|
||||
# Преобразуем _iqXX в t_iqXX
|
||||
return 't' + vtype[vtype.index('_iq'):]
|
||||
else:
|
||||
return 't_iq_none'
|
||||
|
||||
def get_files_by_ext(roots, exts):
|
||||
files = []
|
||||
for root in roots:
|
||||
for dirpath, _, filenames in os.walk(root):
|
||||
for f in filenames:
|
||||
if any(f.endswith(e) for e in exts):
|
||||
files.append(os.path.join(dirpath, f))
|
||||
return files
|
||||
|
||||
def read_file_try_encodings(filepath):
|
||||
for enc in ['utf-8', 'cp1251']:
|
||||
try:
|
||||
with open(filepath, 'r', encoding=enc) as f:
|
||||
content = f.read()
|
||||
content = strip_single_line_comments(content) # <=== ВАЖНО
|
||||
return content, enc
|
||||
except UnicodeDecodeError:
|
||||
continue
|
||||
raise UnicodeDecodeError(f"Не удалось прочитать файл {filepath} с кодировками utf-8 и cp1251")
|
||||
|
||||
FUNC_PATTERN = re.compile(
|
||||
r'\w[\w\s\*\(\),]*\([^;{)]*\)\s*\{(?:[^{}]*|\{[^}]*\})*?\}', re.DOTALL)
|
||||
|
||||
def strip_single_line_comments(code):
|
||||
# Удалим // ... до конца строки
|
||||
return re.sub(r'//.*?$', '', code, flags=re.MULTILINE)
|
||||
|
||||
def remove_function_bodies(code):
|
||||
|
||||
result = []
|
||||
i = 0
|
||||
length = len(code)
|
||||
while i < length:
|
||||
match = re.search(r'\b[\w\s\*\(\),]*\([^;{}]*\)\s*\{', code[i:])
|
||||
if not match:
|
||||
result.append(code[i:])
|
||||
break
|
||||
|
||||
start = i + match.start()
|
||||
brace_start = i + match.end() - 1
|
||||
result.append(code[i:start]) # Добавляем всё до функции
|
||||
|
||||
# Ищем конец функции по уровню вложенности скобок
|
||||
brace_level = 1
|
||||
j = brace_start + 1
|
||||
in_string = False
|
||||
while j < length and brace_level > 0:
|
||||
char = code[j]
|
||||
|
||||
if char == '"' or char == "'":
|
||||
quote = char
|
||||
j += 1
|
||||
while j < length and code[j] != quote:
|
||||
if code[j] == '\\':
|
||||
j += 2
|
||||
else:
|
||||
j += 1
|
||||
elif code[j] == '{':
|
||||
brace_level += 1
|
||||
elif code[j] == '}':
|
||||
brace_level -= 1
|
||||
j += 1
|
||||
|
||||
# Заменяем тело функции пробелами той же длины
|
||||
result.append(' ' * (j - start))
|
||||
i = j
|
||||
|
||||
return ''.join(result)
|
||||
|
||||
def extract_struct_definitions_from_file(filepath):
|
||||
with open(filepath, 'r', encoding='utf-8', errors='ignore') as f:
|
||||
content = f.read()
|
||||
|
||||
# Удаляем комментарии
|
||||
content = re.sub(r'//.*', '', content)
|
||||
content = re.sub(r'/\*.*?\*/', '', content, flags=re.DOTALL)
|
||||
|
||||
type_definitions = {}
|
||||
anonymous_counter = [0]
|
||||
|
||||
def split_fields(body):
|
||||
"""
|
||||
Разбивает тело struct/union на поля с учётом вложенных { }.
|
||||
Возвращает список строк - полей (без ;).
|
||||
"""
|
||||
fields = []
|
||||
start = 0
|
||||
brace_level = 0
|
||||
for i, ch in enumerate(body):
|
||||
if ch == '{':
|
||||
brace_level += 1
|
||||
elif ch == '}':
|
||||
brace_level -= 1
|
||||
elif ch == ';' and brace_level == 0:
|
||||
fields.append(body[start:i].strip())
|
||||
start = i + 1
|
||||
# если что-то осталось после последнего ;
|
||||
tail = body[start:].strip()
|
||||
if tail:
|
||||
fields.append(tail)
|
||||
return fields
|
||||
|
||||
def parse_fields(body):
|
||||
fields = {}
|
||||
body = body.strip('{} \n\t')
|
||||
field_strings = split_fields(body)
|
||||
for field_str in field_strings:
|
||||
if field_str.startswith(('struct ', 'union ')):
|
||||
# Вложенный struct/union
|
||||
# Пытаемся найти имя и тело
|
||||
m = re.match(r'(struct|union)\s*(\w*)\s*({.*})\s*(\w+)?', field_str, re.DOTALL)
|
||||
if m:
|
||||
kind, tag, inner_body, varname = m.groups()
|
||||
if not varname:
|
||||
# Анонимная вложенная структура/объединение
|
||||
varname = f"__anon_{anonymous_counter[0]}"
|
||||
anonymous_counter[0] += 1
|
||||
type_definitions[varname] = parse_fields(inner_body)
|
||||
fields[varname] = varname
|
||||
else:
|
||||
# Если есть имя переменной
|
||||
anon_type_name = f"__anon_{anonymous_counter[0]}"
|
||||
anonymous_counter[0] += 1
|
||||
type_definitions[anon_type_name] = parse_fields(inner_body)
|
||||
fields[varname] = anon_type_name if tag == '' else f"{kind} {tag}"
|
||||
else:
|
||||
# Не смогли распарсить вложенную структуру - кладём как есть
|
||||
fields[field_str] = None
|
||||
else:
|
||||
# Обычное поле
|
||||
# Нужно выделить тип и имя поля с учётом указателей и массивов
|
||||
m = re.match(r'(.+?)\s+([\w\*\[\]]+)$', field_str)
|
||||
if m:
|
||||
typename, varname = m.groups()
|
||||
fields[varname.strip()] = typename.strip()
|
||||
else:
|
||||
# не распарсили поле — кладём "как есть"
|
||||
fields[field_str] = None
|
||||
return fields
|
||||
|
||||
# Парсим typedef struct/union {...} Alias;
|
||||
typedef_struct_pattern = re.compile(
|
||||
r'\btypedef\s+(struct|union)\s*({.*?})\s*(\w+)\s*;', re.DOTALL)
|
||||
for match in typedef_struct_pattern.finditer(content):
|
||||
alias = match.group(3)
|
||||
body = match.group(2)
|
||||
type_definitions[alias] = parse_fields(body)
|
||||
|
||||
# Парсим struct/union Name {...};
|
||||
named_struct_pattern = re.compile(
|
||||
r'\b(struct|union)\s+(\w+)\s*({.*?})\s*;', re.DOTALL)
|
||||
for match in named_struct_pattern.finditer(content):
|
||||
name = match.group(2)
|
||||
body = match.group(3)
|
||||
if name not in type_definitions:
|
||||
type_definitions[name] = parse_fields(body)
|
||||
|
||||
return type_definitions
|
||||
|
||||
def parse_vars_from_file(filepath):
|
||||
content, encoding = read_file_try_encodings(filepath)
|
||||
content_clean = remove_function_bodies(content)
|
||||
|
||||
vars_found = []
|
||||
for m in VAR_PATTERN.finditer(content_clean):
|
||||
typename = m.group(1).strip()
|
||||
varlist = m.group(2)
|
||||
for var in varlist.split(','):
|
||||
varname = var.strip()
|
||||
# Убираем указатели и массивы
|
||||
varname = varname.strip('*').split('[')[0]
|
||||
# Фильтрация мусора
|
||||
if not re.match(r'^[_a-zA-Z][_a-zA-Z0-9]*$', varname):
|
||||
continue
|
||||
vars_found.append((varname, typename))
|
||||
return vars_found, encoding
|
||||
|
||||
def parse_typedefs_from_file(filepath):
|
||||
"""
|
||||
Парсит typedef из файла C:
|
||||
- typedef struct/union { ... } Alias;
|
||||
- typedef simple_type Alias;
|
||||
|
||||
Возвращает словарь alias -> базовый тип (например, 'MyType' -> 'struct' или 'unsigned int').
|
||||
"""
|
||||
with open(filepath, 'r', encoding='utf-8', errors='ignore') as f:
|
||||
content = f.read()
|
||||
|
||||
# Убираем однострочные комментарии
|
||||
content = re.sub(r'//.*?$', '', content, flags=re.MULTILINE)
|
||||
# Убираем многострочные комментарии
|
||||
content = re.sub(r'/\*.*?\*/', '', content, flags=re.DOTALL)
|
||||
|
||||
aliases = {}
|
||||
|
||||
# --- Парсим typedef struct/union {...} Alias;
|
||||
# Используем стек для вложенных фигурных скобок
|
||||
typedef_struct_union_pattern = re.compile(r'\btypedef\s+(struct|union)\b', re.IGNORECASE)
|
||||
pos = 0
|
||||
while True:
|
||||
m = typedef_struct_union_pattern.search(content, pos)
|
||||
if not m:
|
||||
break
|
||||
kind = m.group(1)
|
||||
brace_open_pos = content.find('{', m.end())
|
||||
if brace_open_pos == -1:
|
||||
# Нет тела структуры, пропускаем
|
||||
pos = m.end()
|
||||
continue
|
||||
|
||||
# Ищем позицию закрывающей скобки с учётом вложенности
|
||||
brace_level = 1
|
||||
i = brace_open_pos + 1
|
||||
while i < len(content) and brace_level > 0:
|
||||
if content[i] == '{':
|
||||
brace_level += 1
|
||||
elif content[i] == '}':
|
||||
brace_level -= 1
|
||||
i += 1
|
||||
if brace_level != 0:
|
||||
# Некорректный синтаксис
|
||||
pos = m.end()
|
||||
continue
|
||||
|
||||
# Отрезок typedef структуры/объединения
|
||||
typedef_block = content[m.start():i]
|
||||
|
||||
# После закрывающей скобки ожидаем имя алиаса и точку с запятой
|
||||
rest = content[i:].lstrip()
|
||||
alias_match = re.match(r'(\w+)\s*;', rest)
|
||||
if alias_match:
|
||||
alias_name = alias_match.group(1)
|
||||
aliases[alias_name] = kind # например, "struct" или "union"
|
||||
pos = i + alias_match.end()
|
||||
else:
|
||||
# Анонимный typedef? Просто пропускаем
|
||||
pos = i
|
||||
|
||||
# --- Удаляем typedef struct/union {...} Alias; чтобы не мешали простым typedef
|
||||
# Для этого удалим весь блок typedef struct/union {...} Alias;
|
||||
def remove_typedef_struct_union_blocks(text):
|
||||
result = []
|
||||
last_pos = 0
|
||||
for m in typedef_struct_union_pattern.finditer(text):
|
||||
brace_open_pos = text.find('{', m.end())
|
||||
if brace_open_pos == -1:
|
||||
continue
|
||||
brace_level = 1
|
||||
i = brace_open_pos + 1
|
||||
while i < len(text) and brace_level > 0:
|
||||
if text[i] == '{':
|
||||
brace_level += 1
|
||||
elif text[i] == '}':
|
||||
brace_level -= 1
|
||||
i += 1
|
||||
if brace_level != 0:
|
||||
continue
|
||||
# Ищем имя алиаса и точку с запятой после i
|
||||
rest = text[i:].lstrip()
|
||||
alias_match = re.match(r'\w+\s*;', rest)
|
||||
if alias_match:
|
||||
end_pos = i + alias_match.end()
|
||||
result.append(text[last_pos:m.start()])
|
||||
last_pos = end_pos
|
||||
result.append(text[last_pos:])
|
||||
return ''.join(result)
|
||||
|
||||
content_simple = remove_typedef_struct_union_blocks(content)
|
||||
|
||||
# --- Парсим простые typedef: typedef base_type alias;
|
||||
simple_typedef_pattern = re.compile(
|
||||
r'\btypedef\s+([^{};]+?)\s+(\w+)\s*;', re.MULTILINE)
|
||||
for m in simple_typedef_pattern.finditer(content_simple):
|
||||
base_type = m.group(1).strip()
|
||||
alias = m.group(2).strip()
|
||||
if alias not in aliases:
|
||||
aliases[alias] = base_type
|
||||
|
||||
return aliases
|
||||
|
||||
def parse_externs_from_file(filepath):
|
||||
content, encoding = read_file_try_encodings(filepath)
|
||||
extern_vars = set(EXTERN_PATTERN.findall(content))
|
||||
return extern_vars, encoding
|
||||
|
||||
def get_relpath_to_srcdirs(filepath, src_dirs):
|
||||
# Ищем первый SRC_DIR, в котором лежит filepath, и возвращаем относительный путь
|
||||
for d in src_dirs:
|
||||
try:
|
||||
rel = os.path.relpath(filepath, d)
|
||||
# Проверим, что rel не уходит выше корня (например, не начинается с '..')
|
||||
if not rel.startswith('..'):
|
||||
return rel.replace('\\', '/') # Для единообразия в путях
|
||||
except ValueError:
|
||||
continue
|
||||
# Если ни один SRC_DIR не подходит, вернуть basename
|
||||
return os.path.basename(filepath)
|
||||
|
||||
def find_all_includes_recursive(c_files, include_dirs, processed_files=None):
|
||||
"""
|
||||
Рекурсивно ищет все include-файлы начиная с заданных c_files.
|
||||
include_dirs — список директорий, в которых ищем include-файлы.
|
||||
processed_files — множество уже обработанных файлов (для избежания циклов).
|
||||
"""
|
||||
if processed_files is None:
|
||||
processed_files = set()
|
||||
|
||||
include_files = set()
|
||||
include_pattern = re.compile(r'#include\s+"([^"]+)"')
|
||||
|
||||
for cfile in c_files:
|
||||
norm_path = os.path.normpath(cfile)
|
||||
if norm_path in processed_files:
|
||||
continue
|
||||
processed_files.add(norm_path)
|
||||
|
||||
content, _ = read_file_try_encodings(cfile)
|
||||
includes = include_pattern.findall(content)
|
||||
for inc in includes:
|
||||
include_files.add(inc)
|
||||
|
||||
# Ищем полный путь к include-файлу в include_dirs
|
||||
inc_full_path = None
|
||||
for dir_ in include_dirs:
|
||||
candidate = os.path.normpath(os.path.join(dir_, inc))
|
||||
if os.path.isfile(candidate):
|
||||
inc_full_path = candidate
|
||||
break
|
||||
|
||||
# Если нашли include-файл и ещё не обработали — рекурсивно ищем include внутри него
|
||||
if inc_full_path and inc_full_path not in processed_files:
|
||||
nested_includes = find_all_includes_recursive(
|
||||
[inc_full_path], include_dirs, processed_files
|
||||
)
|
||||
include_files.update(nested_includes)
|
||||
|
||||
return include_files
|
||||
|
||||
def file_uses_typedef_vars(filepath, missing_vars, typedefs):
|
||||
"""
|
||||
Проверяем, содержит ли файл typedef с одним из missing_vars.
|
||||
typedefs — словарь alias->базовый тип, полученный parse_typedefs_from_file.
|
||||
"""
|
||||
# Здесь проще проверить, есть ли в typedefs ключи из missing_vars,
|
||||
# но в условии — typedef переменных из missing_in_h,
|
||||
# значит, нужно проверить typedef переменных с этими именами
|
||||
|
||||
# Для упрощения — прочитаем содержимое и проверим наличие typedef с именами из missing_vars
|
||||
|
||||
content, _ = read_file_try_encodings(filepath)
|
||||
|
||||
for var in missing_vars:
|
||||
# Ищем в content что-то типа typedef ... var ...;
|
||||
# Для простоты регулярка: typedef ... var;
|
||||
pattern = re.compile(r'\btypedef\b[^;]*\b' + re.escape(var) + r'\b[^;]*;', re.DOTALL)
|
||||
if pattern.search(content):
|
||||
return True
|
||||
return False
|
||||
|
||||
def file_contains_extern_vars(filepath, extern_vars):
|
||||
content, _ = read_file_try_encodings(filepath)
|
||||
for var in extern_vars:
|
||||
pattern = re.compile(r'\bextern\b[^;]*\b' + re.escape(var) + r'\b\s*;')
|
||||
if pattern.search(content):
|
||||
return True
|
||||
return False
|
||||
|
||||
def add_struct_fields(new_debug_vars, var_prefix, struct_type, all_structs, existing_debug_vars):
|
||||
"""
|
||||
Рекурсивно добавляет поля структуры в new_debug_vars.
|
||||
|
||||
var_prefix: имя переменной или путь к полю (например "myVar" или "myVar.subfield")
|
||||
struct_type: имя типа структуры (например "MyStruct")
|
||||
all_structs: словарь всех структур
|
||||
existing_debug_vars: множество уже существующих имен переменных
|
||||
"""
|
||||
if struct_type not in all_structs:
|
||||
# Типа нет в структуре, значит не структура или неизвестный тип — выходим
|
||||
return
|
||||
|
||||
fields = all_structs[struct_type]
|
||||
for field_name, field_type in fields.items():
|
||||
full_var_name = f"{var_prefix}.{field_name}"
|
||||
|
||||
if full_var_name in existing_debug_vars or full_var_name in new_debug_vars:
|
||||
continue
|
||||
|
||||
if field_type is None:
|
||||
continue
|
||||
|
||||
iq_type = get_iq_define(field_type)
|
||||
pt_type = map_type_to_pt(field_type, full_var_name)
|
||||
formated_name = f'"{full_var_name}"'
|
||||
line = f'\t{{(char *)&{full_var_name:<40} , {pt_type:<20} , {iq_type:<20} , {formated_name:<40}}}, \\'
|
||||
new_debug_vars[full_var_name] = line
|
||||
|
||||
# Если поле — тоже структура, рекурсивно раскрываем
|
||||
# При этом убираем указатели и массивы из типа, если они есть
|
||||
base_field_type = field_type.split()[0] # например "struct" или "MyStruct*"
|
||||
# Удаляем указатели и массивы из имени типа для поиска в all_structs
|
||||
base_field_type = re.sub(r'[\*\[\]0-9]+', '', base_field_type)
|
||||
base_field_type = base_field_type.strip()
|
||||
|
||||
if base_field_type in all_structs:
|
||||
add_struct_fields(new_debug_vars, full_var_name, base_field_type, all_structs, existing_debug_vars)
|
||||
else:
|
||||
a=1
|
||||
|
||||
|
||||
|
||||
def main(make_path):
|
||||
|
||||
c_files, include_dirs = parse_makefile(make_path)
|
||||
all_dirs = c_files + include_dirs
|
||||
|
||||
h_files = get_files_by_ext(include_dirs, ['.h'])
|
||||
|
||||
vars_in_c = {}
|
||||
encodings_c = set()
|
||||
for cf in c_files:
|
||||
vars_found, enc = parse_vars_from_file(cf)
|
||||
encodings_c.add(enc)
|
||||
for vname, vtype in vars_found:
|
||||
vars_in_c[vname] = (vtype, cf)
|
||||
|
||||
externs_in_h = set()
|
||||
for hf in h_files:
|
||||
externs, _ = parse_externs_from_file(hf)
|
||||
externs_in_h |= externs
|
||||
|
||||
missing_in_h = {v: vars_in_c[v] for v in vars_in_c if v not in externs_in_h}
|
||||
|
||||
all_structs = {}
|
||||
for fl in c_files + h_files:
|
||||
structs = extract_struct_definitions_from_file(fl)
|
||||
all_structs.update(structs)
|
||||
|
||||
# Подготовка typedef-ов
|
||||
global typedef_aliases
|
||||
typedef_aliases = {}
|
||||
for f in h_files + c_files:
|
||||
aliases = parse_typedefs_from_file(f)
|
||||
typedef_aliases.update(aliases)
|
||||
|
||||
|
||||
included_headers = find_all_includes_recursive(c_files, include_dirs) # все подключенные .h
|
||||
include_files = []
|
||||
|
||||
for header in included_headers:
|
||||
# Полный путь к файлу нужно получить
|
||||
full_path = None
|
||||
for d in all_dirs:
|
||||
candidate = os.path.join(d, header)
|
||||
if os.path.isfile(candidate):
|
||||
full_path = candidate
|
||||
break
|
||||
if not full_path:
|
||||
continue # файл не найден в SRC_DIRS — игнорируем
|
||||
|
||||
# Проверяем, что это строго .h
|
||||
if not full_path.endswith('.h'):
|
||||
continue
|
||||
|
||||
# Парсим typedef из файла
|
||||
typedefs = parse_typedefs_from_file(full_path)
|
||||
|
||||
# Проверяем, использует ли typedef переменные из missing_in_h по их vtype
|
||||
uses_typedef = any(vtype in typedefs for (vtype, path) in missing_in_h.values())
|
||||
|
||||
# Проверяем наличие extern переменных
|
||||
has_extern = file_contains_extern_vars(full_path, externs_in_h)
|
||||
|
||||
if not has_extern and not uses_typedef:
|
||||
continue
|
||||
|
||||
# Если прошло оба условия — добавляем
|
||||
include_files.append(full_path)
|
||||
|
||||
# Путь к debug_vars.h
|
||||
common_prefix = os.path.commonpath(include_dirs)
|
||||
output_dir = os.path.join(common_prefix, 'DebugTools')
|
||||
os.makedirs(output_dir, exist_ok=True)
|
||||
output_path = os.path.join(output_dir, 'debug_vars.c')
|
||||
|
||||
# Считываем существующие переменные
|
||||
existing_debug_vars = {}
|
||||
if os.path.isfile(output_path):
|
||||
with open(output_path, 'r', encoding='utf-8', errors='ignore') as f:
|
||||
old_lines = f.readlines()
|
||||
for line in old_lines:
|
||||
m = re.match(r'\s*{.*?,\s+.*?,\s+.*?,\s+"([_a-zA-Z][_a-zA-Z0-9]*)"\s*},', line)
|
||||
if m:
|
||||
varname = m.group(1)
|
||||
existing_debug_vars[varname] = line.strip()
|
||||
|
||||
# Генерируем новые переменные
|
||||
new_debug_vars = {}
|
||||
for vname, (vtype, path) in vars_in_c.items():
|
||||
if vname in existing_debug_vars:
|
||||
continue
|
||||
iq_type = get_iq_define(vtype)
|
||||
pt_type = map_type_to_pt(vtype, vname)
|
||||
|
||||
if pt_type not in ('pt_struct', 'pt_union'):
|
||||
formated_name = f'"{vname}"'
|
||||
line = f'{{(char *)&{vname:<41} , {pt_type:<21} , {iq_type:<21} , {formated_name:<42}}}, \\'
|
||||
new_debug_vars[vname] = line
|
||||
else:
|
||||
continue
|
||||
# Если тип переменной — структура, добавляем поля
|
||||
base_type = vtype.split()[0]
|
||||
# Удаляем символы указателей '*' и всю квадратную скобку с содержимым (например [10])
|
||||
base_type = re.sub(r'\*|\[[^\]]*\]', '', base_type).strip()
|
||||
if base_type in all_structs:
|
||||
add_struct_fields(new_debug_vars, vname, base_type, all_structs, existing_debug_vars)
|
||||
|
||||
# Сортируем новые переменные по алфавиту по имени
|
||||
sorted_new_debug_vars = dict(sorted(new_debug_vars.items()))
|
||||
# Объединяем все переменные
|
||||
all_debug_lines = list(existing_debug_vars.values()) + list(sorted_new_debug_vars.values())
|
||||
|
||||
# DebugVar_Numb теперь по всем переменным
|
||||
out_lines = []
|
||||
out_lines.append("// Этот файл сгенерирован автоматически")
|
||||
out_lines.append(f'#include "debug_tools.h"')
|
||||
|
||||
out_lines.append('\n\n// Инклюды для доступа к переменным')
|
||||
out_lines.append(f'#include "IQmathLib.h"')
|
||||
for incf in include_files:
|
||||
out_lines.append(f'#include "{incf}"')
|
||||
|
||||
|
||||
out_lines.append('\n\n// Экстерны для доступа к переменным')
|
||||
for vname, (vtype, path) in missing_in_h.items():
|
||||
out_lines.append(f'extern {vtype} {vname};')
|
||||
|
||||
out_lines.append(f'\n\n// Определение массива с указателями на переменные для отладки')
|
||||
out_lines.append(f'int DebugVar_Numb = {len(all_debug_lines)};')
|
||||
out_lines.append('#pragma DATA_SECTION(dbg_vars,".dbgvar_info")')
|
||||
out_lines.append('DebugVar_t dbg_vars[] = {\\')
|
||||
out_lines.extend(all_debug_lines)
|
||||
out_lines.append('};')
|
||||
out_lines.append('')
|
||||
# Выберем кодировку для записи файла
|
||||
# Если встречается несколько, возьмем первую из set
|
||||
enc_to_write = 'cp1251'
|
||||
|
||||
#print("== GLOBAL VARS FOUND ==")
|
||||
#for vname, (vtype, path) in vars_in_c.items():
|
||||
#print(f"{vtype:<20} {vname:<40} // {path}")
|
||||
|
||||
|
||||
with open(output_path, 'w', encoding=enc_to_write) as f:
|
||||
f.write('\n'.join(out_lines))
|
||||
|
||||
print(f'Файл debug_vars.c сгенерирован в кодировке, переменных: {len(all_debug_lines)}')
|
||||
|
||||
if __name__ == '__main__':
|
||||
if len(sys.argv) < 2:
|
||||
main('F:/Work/Projects/TMS/TMS_new_bus/Debug/makefile')
|
||||
print("Usage: parse_makefile.py path/to/Makefile")
|
||||
sys.exit(1)
|
||||
else:
|
||||
main(sys.argv[1])
|
143
.out/setupAllVars.py
Normal file
143
.out/setupAllVars.py
Normal file
@ -0,0 +1,143 @@
|
||||
import xml.etree.ElementTree as ET
|
||||
|
||||
|
||||
# === Словарь соответствия типов XML → DebugVarType_t ===
|
||||
type_map = dict([
|
||||
*[(k, 'pt_int8') for k in ('signed char', 'char')],
|
||||
*[(k, 'pt_int16') for k in ('int', 'int16', 'short')],
|
||||
*[(k, 'pt_int32') for k in ('long', 'int32', '_iqx')],
|
||||
*[(k, 'pt_int64') for k in ('long long', 'int64')],
|
||||
|
||||
*[(k, 'pt_uint8') for k in ('unsigned char',)],
|
||||
*[(k, 'pt_uint16') for k in ('unsigned int', 'unsigned short', 'Uint16')],
|
||||
*[(k, 'pt_uint32') for k in ('unsigned long', 'Uint32')],
|
||||
*[(k, 'pt_uint64') for k in ('unsigned long long', 'Uint64')],
|
||||
|
||||
*[(k, 'pt_ptr_int8') for k in ('signed char*',)],
|
||||
*[(k, 'pt_ptr_int16') for k in ('int*', 'short*')],
|
||||
*[(k, 'pt_ptr_int32') for k in ('long*',)],
|
||||
*[(k, 'pt_ptr_uint8') for k in ('unsigned char*',)],
|
||||
*[(k, 'pt_ptr_uint16') for k in ('unsigned int*', 'unsigned short*')],
|
||||
*[(k, 'pt_ptr_uint32') for k in ('unsigned long*',)],
|
||||
('unsigned long long*', 'pt_int64'),
|
||||
|
||||
*[(k, 'pt_arr_int8') for k in ('signed char[]',)],
|
||||
*[(k, 'pt_arr_int16') for k in ('int[]', 'short[]')],
|
||||
*[(k, 'pt_arr_int32') for k in ('long[]',)],
|
||||
*[(k, 'pt_arr_uint8') for k in ('unsigned char[]',)],
|
||||
*[(k, 'pt_arr_uint16') for k in ('unsigned int[]', 'unsigned short[]')],
|
||||
*[(k, 'pt_arr_uint32') for k in ('unsigned long[]',)],
|
||||
|
||||
*[(k, 'pt_float') for k in ('float', 'float32')],
|
||||
|
||||
('struct', 'pt_struct'),
|
||||
('union', 'pt_union'),
|
||||
])
|
||||
|
||||
|
||||
|
||||
def is_anonymous(elem):
|
||||
typ = elem.attrib.get('type', '')
|
||||
return 'anonymous' in typ
|
||||
|
||||
|
||||
def get_array_sizes(elem):
|
||||
sizes = []
|
||||
i = 0
|
||||
while True:
|
||||
attr = 'size' if i == 0 else f'size{i}'
|
||||
if attr in elem.attrib:
|
||||
sizes.append(elem.attrib[attr])
|
||||
i += 1
|
||||
else:
|
||||
break
|
||||
return ''.join(f'[{size}]' for size in sizes)
|
||||
|
||||
|
||||
def collect_externs_and_vars(element, prefix, extern_vars, variables):
|
||||
kind = element.attrib.get('kind', '')
|
||||
name = element.attrib.get('name', prefix)
|
||||
vtype = element.attrib.get('type', 'unknown')
|
||||
|
||||
# Пропускаем анонимные типы полностью
|
||||
if is_anonymous(element):
|
||||
return
|
||||
|
||||
# Для массивов учитываем все размеры size, size1, size2...
|
||||
if kind == 'array':
|
||||
array_dims = get_array_sizes(element)
|
||||
extern_type = vtype # тип без размеров
|
||||
extern_vars[name] = (extern_type, array_dims)
|
||||
variables.append((name, vtype)) # В массив макросов кладём сам массив (без элементов)
|
||||
return
|
||||
|
||||
# Для обычных структур (не анонимных) и переменных
|
||||
if kind in ('struct', 'union'):
|
||||
extern_vars[name] = (vtype, '')
|
||||
variables.append((name, vtype))
|
||||
return
|
||||
|
||||
# Простые переменные
|
||||
extern_vars[name] = (vtype, '')
|
||||
variables.append((name, vtype))
|
||||
|
||||
|
||||
def parse_variables(xml_path):
|
||||
tree = ET.parse(xml_path)
|
||||
root = tree.getroot()
|
||||
|
||||
extern_vars = dict()
|
||||
variables = []
|
||||
|
||||
for var in root.findall('variable'):
|
||||
collect_externs_and_vars(var, var.attrib['name'], extern_vars, variables)
|
||||
|
||||
return variables, extern_vars
|
||||
|
||||
def format_extern_declaration(varname, vartype, dims):
|
||||
base_type = vartype.replace('[]', '') # убираем [] из типа
|
||||
return f"extern {base_type} {varname}{dims};"
|
||||
|
||||
|
||||
def to_macro_entry(varname, vartype):
|
||||
# pt_ и t_iq_none — пример, замените на вашу логику или словарь
|
||||
ptr_type = type_map.get(vartype)
|
||||
if ptr_type is None:
|
||||
ptr_type = 'char *'
|
||||
iq_type = "t_iq_none"
|
||||
return f"\t{{(char *)&{varname:<40}, {ptr_type:<20}, {iq_type:<20}, \"{varname}\"}},"
|
||||
|
||||
|
||||
def generate_code(variables, extern_vars):
|
||||
# extern-блок
|
||||
extern_lines = []
|
||||
for var, (vtype, dims) in sorted(extern_vars.items()):
|
||||
# фильтр анонимных структур по имени (пример)
|
||||
if "anonymous" in var:
|
||||
continue
|
||||
extern_lines.append(format_extern_declaration(var, vtype, dims))
|
||||
|
||||
# define DebugVar_Numb
|
||||
debugvar_numb = len(variables)
|
||||
defines = [f"#define DebugVar_Numb\t{debugvar_numb}"]
|
||||
|
||||
# define DebugVar_Init
|
||||
defines.append("#define DebugVar_Init\t\\")
|
||||
defines.append("{\\")
|
||||
for varname, vartype in variables:
|
||||
defines.append(to_macro_entry(varname, vartype))
|
||||
defines.append("}")
|
||||
|
||||
return "\n".join(extern_lines) + "\n\n" + "\n".join(defines)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
xml_file = "F:/Work/Projects/TMS/TMS_new_bus/bin/New_bus_allVars.xml"
|
||||
variables, extern_vars = parse_variables(xml_file)
|
||||
|
||||
code = generate_code(variables, extern_vars)
|
||||
|
||||
with open("debug_vars.h", "w") as f:
|
||||
f.write(code)
|
||||
|
||||
print("Сгенерировано в debug_vars.h")
|
BIN
__pycache__/generateVars.cpython-313.pyc
Normal file
BIN
__pycache__/generateVars.cpython-313.pyc
Normal file
Binary file not shown.
BIN
__pycache__/parseMakefile.cpython-313.pyc
Normal file
BIN
__pycache__/parseMakefile.cpython-313.pyc
Normal file
Binary file not shown.
BIN
__pycache__/scanVars.cpython-313.pyc
Normal file
BIN
__pycache__/scanVars.cpython-313.pyc
Normal file
Binary file not shown.
38
build/generateVars.spec
Normal file
38
build/generateVars.spec
Normal file
@ -0,0 +1,38 @@
|
||||
# -*- mode: python ; coding: utf-8 -*-
|
||||
|
||||
|
||||
a = Analysis(
|
||||
['..\\generateVars.py'],
|
||||
pathex=[],
|
||||
binaries=[],
|
||||
datas=[],
|
||||
hiddenimports=[],
|
||||
hookspath=[],
|
||||
hooksconfig={},
|
||||
runtime_hooks=[],
|
||||
excludes=[],
|
||||
noarchive=False,
|
||||
optimize=0,
|
||||
)
|
||||
pyz = PYZ(a.pure)
|
||||
|
||||
exe = EXE(
|
||||
pyz,
|
||||
a.scripts,
|
||||
a.binaries,
|
||||
a.datas,
|
||||
[],
|
||||
name='generateVars',
|
||||
debug=False,
|
||||
bootloader_ignore_signals=False,
|
||||
strip=False,
|
||||
upx=True,
|
||||
upx_exclude=[],
|
||||
runtime_tmpdir=None,
|
||||
console=True,
|
||||
disable_windowed_traceback=False,
|
||||
argv_emulation=False,
|
||||
target_arch=None,
|
||||
codesign_identity=None,
|
||||
entitlements_file=None,
|
||||
)
|
1066
build/generateVars/Analysis-00.toc
Normal file
1066
build/generateVars/Analysis-00.toc
Normal file
File diff suppressed because it is too large
Load Diff
230
build/generateVars/EXE-00.toc
Normal file
230
build/generateVars/EXE-00.toc
Normal file
@ -0,0 +1,230 @@
|
||||
('F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\generateVars.exe',
|
||||
True,
|
||||
False,
|
||||
False,
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\bootloader\\images\\icon-console.ico',
|
||||
None,
|
||||
False,
|
||||
False,
|
||||
b'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\n<assembly xmlns='
|
||||
b'"urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">\n <trustInfo x'
|
||||
b'mlns="urn:schemas-microsoft-com:asm.v3">\n <security>\n <requested'
|
||||
b'Privileges>\n <requestedExecutionLevel level="asInvoker" uiAccess='
|
||||
b'"false"/>\n </requestedPrivileges>\n </security>\n </trustInfo>\n '
|
||||
b'<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">\n <'
|
||||
b'application>\n <supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f'
|
||||
b'0}"/>\n <supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"/>\n '
|
||||
b' <supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"/>\n <s'
|
||||
b'upportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"/>\n <supporte'
|
||||
b'dOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"/>\n </application>\n <'
|
||||
b'/compatibility>\n <application xmlns="urn:schemas-microsoft-com:asm.v3">'
|
||||
b'\n <windowsSettings>\n <longPathAware xmlns="http://schemas.micros'
|
||||
b'oft.com/SMI/2016/WindowsSettings">true</longPathAware>\n </windowsSett'
|
||||
b'ings>\n </application>\n <dependency>\n <dependentAssembly>\n <ass'
|
||||
b'emblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version='
|
||||
b'"6.0.0.0" processorArchitecture="*" publicKeyToken="6595b64144ccf1df" langua'
|
||||
b'ge="*"/>\n </dependentAssembly>\n </dependency>\n</assembly>',
|
||||
True,
|
||||
False,
|
||||
None,
|
||||
None,
|
||||
None,
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\generateVars.pkg',
|
||||
[('pyi-contents-directory _internal', '', 'OPTION'),
|
||||
('PYZ-00.pyz',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\PYZ-00.pyz',
|
||||
'PYZ'),
|
||||
('struct',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\localpycs\\struct.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod01_archive',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\localpycs\\pyimod01_archive.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod02_importers',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\localpycs\\pyimod02_importers.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod03_ctypes',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\localpycs\\pyimod03_ctypes.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod04_pywin32',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\localpycs\\pyimod04_pywin32.pyc',
|
||||
'PYMODULE'),
|
||||
('pyiboot01_bootstrap',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\loader\\pyiboot01_bootstrap.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_inspect',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_inspect.py',
|
||||
'PYSOURCE'),
|
||||
('generateVars',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\generateVars.py',
|
||||
'PYSOURCE'),
|
||||
('python313.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\python313.dll',
|
||||
'BINARY'),
|
||||
('_decimal.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_decimal.pyd',
|
||||
'EXTENSION'),
|
||||
('_hashlib.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_hashlib.pyd',
|
||||
'EXTENSION'),
|
||||
('select.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\select.pyd',
|
||||
'EXTENSION'),
|
||||
('_socket.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_socket.pyd',
|
||||
'EXTENSION'),
|
||||
('unicodedata.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\unicodedata.pyd',
|
||||
'EXTENSION'),
|
||||
('_lzma.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_lzma.pyd',
|
||||
'EXTENSION'),
|
||||
('_bz2.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_bz2.pyd',
|
||||
'EXTENSION'),
|
||||
('_elementtree.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_elementtree.pyd',
|
||||
'EXTENSION'),
|
||||
('pyexpat.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\pyexpat.pyd',
|
||||
'EXTENSION'),
|
||||
('_ssl.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_ssl.pyd',
|
||||
'EXTENSION'),
|
||||
('api-ms-win-crt-environment-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-environment-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-heap-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-heap-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-filesystem-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-filesystem-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-convert-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-convert-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-stdio-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-stdio-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-locale-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-locale-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('VCRUNTIME140.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\VCRUNTIME140.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-time-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-time-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-runtime-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-runtime-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-string-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-string-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-math-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-math-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-process-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-process-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-conio-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-conio-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('libcrypto-3.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\libcrypto-3.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-utility-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-utility-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('libssl-3.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\libssl-3.dll',
|
||||
'BINARY'),
|
||||
('ucrtbase.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\ucrtbase.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-interlocked-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-interlocked-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-datetime-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-datetime-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-string-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-string-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-timezone-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-timezone-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-errorhandling-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-errorhandling-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-profile-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-profile-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-console-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-console-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processthreads-l1-1-1.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-processthreads-l1-1-1.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-namedpipe-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-namedpipe-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-heap-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-heap-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l1-2-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-file-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l2-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-file-l2-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-libraryloader-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-libraryloader-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-debug-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-debug-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-rtlsupport-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-rtlsupport-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-sysinfo-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-sysinfo-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-file-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-localization-l1-2-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-localization-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-util-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-util-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-handle-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-handle-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-synch-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-synch-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-memory-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-memory-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processenvironment-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-processenvironment-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processthreads-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-processthreads-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-synch-l1-2-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-synch-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('base_library.zip',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\base_library.zip',
|
||||
'DATA')],
|
||||
[],
|
||||
False,
|
||||
False,
|
||||
1751903262,
|
||||
[('run.exe',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\bootloader\\Windows-64bit-intel\\run.exe',
|
||||
'EXECUTABLE')],
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\python313.dll')
|
208
build/generateVars/PKG-00.toc
Normal file
208
build/generateVars/PKG-00.toc
Normal file
@ -0,0 +1,208 @@
|
||||
('F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\generateVars.pkg',
|
||||
{'BINARY': True,
|
||||
'DATA': True,
|
||||
'EXECUTABLE': True,
|
||||
'EXTENSION': True,
|
||||
'PYMODULE': True,
|
||||
'PYSOURCE': True,
|
||||
'PYZ': False,
|
||||
'SPLASH': True,
|
||||
'SYMLINK': False},
|
||||
[('pyi-contents-directory _internal', '', 'OPTION'),
|
||||
('PYZ-00.pyz',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\PYZ-00.pyz',
|
||||
'PYZ'),
|
||||
('struct',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\localpycs\\struct.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod01_archive',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\localpycs\\pyimod01_archive.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod02_importers',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\localpycs\\pyimod02_importers.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod03_ctypes',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\localpycs\\pyimod03_ctypes.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod04_pywin32',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\localpycs\\pyimod04_pywin32.pyc',
|
||||
'PYMODULE'),
|
||||
('pyiboot01_bootstrap',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\loader\\pyiboot01_bootstrap.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_inspect',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_inspect.py',
|
||||
'PYSOURCE'),
|
||||
('generateVars',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\generateVars.py',
|
||||
'PYSOURCE'),
|
||||
('python313.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\python313.dll',
|
||||
'BINARY'),
|
||||
('_decimal.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_decimal.pyd',
|
||||
'EXTENSION'),
|
||||
('_hashlib.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_hashlib.pyd',
|
||||
'EXTENSION'),
|
||||
('select.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\select.pyd',
|
||||
'EXTENSION'),
|
||||
('_socket.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_socket.pyd',
|
||||
'EXTENSION'),
|
||||
('unicodedata.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\unicodedata.pyd',
|
||||
'EXTENSION'),
|
||||
('_lzma.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_lzma.pyd',
|
||||
'EXTENSION'),
|
||||
('_bz2.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_bz2.pyd',
|
||||
'EXTENSION'),
|
||||
('_elementtree.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_elementtree.pyd',
|
||||
'EXTENSION'),
|
||||
('pyexpat.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\pyexpat.pyd',
|
||||
'EXTENSION'),
|
||||
('_ssl.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_ssl.pyd',
|
||||
'EXTENSION'),
|
||||
('api-ms-win-crt-environment-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-environment-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-heap-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-heap-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-filesystem-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-filesystem-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-convert-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-convert-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-stdio-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-stdio-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-locale-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-locale-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('VCRUNTIME140.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\VCRUNTIME140.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-time-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-time-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-runtime-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-runtime-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-string-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-string-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-math-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-math-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-process-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-process-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-conio-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-conio-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('libcrypto-3.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\libcrypto-3.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-utility-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-utility-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('libssl-3.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\libssl-3.dll',
|
||||
'BINARY'),
|
||||
('ucrtbase.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\ucrtbase.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-interlocked-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-interlocked-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-datetime-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-datetime-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-string-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-string-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-timezone-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-timezone-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-errorhandling-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-errorhandling-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-profile-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-profile-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-console-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-console-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processthreads-l1-1-1.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-processthreads-l1-1-1.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-namedpipe-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-namedpipe-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-heap-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-heap-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l1-2-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-file-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l2-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-file-l2-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-libraryloader-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-libraryloader-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-debug-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-debug-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-rtlsupport-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-rtlsupport-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-sysinfo-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-sysinfo-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-file-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-localization-l1-2-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-localization-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-util-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-util-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-handle-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-handle-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-synch-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-synch-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-memory-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-memory-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processenvironment-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-processenvironment-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processthreads-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-processthreads-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-synch-l1-2-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-synch-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('base_library.zip',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\base_library.zip',
|
||||
'DATA')],
|
||||
'python313.dll',
|
||||
False,
|
||||
False,
|
||||
False,
|
||||
[],
|
||||
None,
|
||||
None,
|
||||
None)
|
BIN
build/generateVars/PYZ-00.pyz
Normal file
BIN
build/generateVars/PYZ-00.pyz
Normal file
Binary file not shown.
415
build/generateVars/PYZ-00.toc
Normal file
415
build/generateVars/PYZ-00.toc
Normal file
@ -0,0 +1,415 @@
|
||||
('F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\generateVars\\PYZ-00.pyz',
|
||||
[('__future__',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\__future__.py',
|
||||
'PYMODULE'),
|
||||
('_colorize',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\_colorize.py',
|
||||
'PYMODULE'),
|
||||
('_compat_pickle',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\_compat_pickle.py',
|
||||
'PYMODULE'),
|
||||
('_compression',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\_compression.py',
|
||||
'PYMODULE'),
|
||||
('_opcode_metadata',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\_opcode_metadata.py',
|
||||
'PYMODULE'),
|
||||
('_py_abc',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\_py_abc.py',
|
||||
'PYMODULE'),
|
||||
('_pydatetime',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\_pydatetime.py',
|
||||
'PYMODULE'),
|
||||
('_pydecimal',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\_pydecimal.py',
|
||||
'PYMODULE'),
|
||||
('_strptime',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\_strptime.py',
|
||||
'PYMODULE'),
|
||||
('_threading_local',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\_threading_local.py',
|
||||
'PYMODULE'),
|
||||
('argparse',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\argparse.py',
|
||||
'PYMODULE'),
|
||||
('ast',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\ast.py',
|
||||
'PYMODULE'),
|
||||
('base64',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\base64.py',
|
||||
'PYMODULE'),
|
||||
('bisect',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\bisect.py',
|
||||
'PYMODULE'),
|
||||
('bz2',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\bz2.py',
|
||||
'PYMODULE'),
|
||||
('calendar',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\calendar.py',
|
||||
'PYMODULE'),
|
||||
('contextlib',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\contextlib.py',
|
||||
'PYMODULE'),
|
||||
('contextvars',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\contextvars.py',
|
||||
'PYMODULE'),
|
||||
('copy',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\copy.py',
|
||||
'PYMODULE'),
|
||||
('csv',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\csv.py',
|
||||
'PYMODULE'),
|
||||
('dataclasses',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\dataclasses.py',
|
||||
'PYMODULE'),
|
||||
('datetime',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\datetime.py',
|
||||
'PYMODULE'),
|
||||
('decimal',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\decimal.py',
|
||||
'PYMODULE'),
|
||||
('dis',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\dis.py',
|
||||
'PYMODULE'),
|
||||
('email',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\__init__.py',
|
||||
'PYMODULE'),
|
||||
('email._encoded_words',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\_encoded_words.py',
|
||||
'PYMODULE'),
|
||||
('email._header_value_parser',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\_header_value_parser.py',
|
||||
'PYMODULE'),
|
||||
('email._parseaddr',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\_parseaddr.py',
|
||||
'PYMODULE'),
|
||||
('email._policybase',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\_policybase.py',
|
||||
'PYMODULE'),
|
||||
('email.base64mime',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\base64mime.py',
|
||||
'PYMODULE'),
|
||||
('email.charset',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\charset.py',
|
||||
'PYMODULE'),
|
||||
('email.contentmanager',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\contentmanager.py',
|
||||
'PYMODULE'),
|
||||
('email.encoders',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\encoders.py',
|
||||
'PYMODULE'),
|
||||
('email.errors',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\errors.py',
|
||||
'PYMODULE'),
|
||||
('email.feedparser',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\feedparser.py',
|
||||
'PYMODULE'),
|
||||
('email.generator',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\generator.py',
|
||||
'PYMODULE'),
|
||||
('email.header',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\header.py',
|
||||
'PYMODULE'),
|
||||
('email.headerregistry',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\headerregistry.py',
|
||||
'PYMODULE'),
|
||||
('email.iterators',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\iterators.py',
|
||||
'PYMODULE'),
|
||||
('email.message',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\message.py',
|
||||
'PYMODULE'),
|
||||
('email.parser',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\parser.py',
|
||||
'PYMODULE'),
|
||||
('email.policy',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\policy.py',
|
||||
'PYMODULE'),
|
||||
('email.quoprimime',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\quoprimime.py',
|
||||
'PYMODULE'),
|
||||
('email.utils',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\email\\utils.py',
|
||||
'PYMODULE'),
|
||||
('fnmatch',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\fnmatch.py',
|
||||
'PYMODULE'),
|
||||
('fractions',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\fractions.py',
|
||||
'PYMODULE'),
|
||||
('ftplib',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\ftplib.py',
|
||||
'PYMODULE'),
|
||||
('getopt',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\getopt.py',
|
||||
'PYMODULE'),
|
||||
('getpass',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\getpass.py',
|
||||
'PYMODULE'),
|
||||
('gettext',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\gettext.py',
|
||||
'PYMODULE'),
|
||||
('glob',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\glob.py',
|
||||
'PYMODULE'),
|
||||
('gzip',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\gzip.py',
|
||||
'PYMODULE'),
|
||||
('hashlib',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\hashlib.py',
|
||||
'PYMODULE'),
|
||||
('http',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\http\\__init__.py',
|
||||
'PYMODULE'),
|
||||
('http.client',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\http\\client.py',
|
||||
'PYMODULE'),
|
||||
('http.cookiejar',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\http\\cookiejar.py',
|
||||
'PYMODULE'),
|
||||
('importlib',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\__init__.py',
|
||||
'PYMODULE'),
|
||||
('importlib._abc',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\_abc.py',
|
||||
'PYMODULE'),
|
||||
('importlib._bootstrap',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\_bootstrap.py',
|
||||
'PYMODULE'),
|
||||
('importlib._bootstrap_external',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\_bootstrap_external.py',
|
||||
'PYMODULE'),
|
||||
('importlib.abc',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\abc.py',
|
||||
'PYMODULE'),
|
||||
('importlib.machinery',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\machinery.py',
|
||||
'PYMODULE'),
|
||||
('importlib.metadata',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\metadata\\__init__.py',
|
||||
'PYMODULE'),
|
||||
('importlib.metadata._adapters',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\metadata\\_adapters.py',
|
||||
'PYMODULE'),
|
||||
('importlib.metadata._collections',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\metadata\\_collections.py',
|
||||
'PYMODULE'),
|
||||
('importlib.metadata._functools',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\metadata\\_functools.py',
|
||||
'PYMODULE'),
|
||||
('importlib.metadata._itertools',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\metadata\\_itertools.py',
|
||||
'PYMODULE'),
|
||||
('importlib.metadata._meta',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\metadata\\_meta.py',
|
||||
'PYMODULE'),
|
||||
('importlib.metadata._text',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\metadata\\_text.py',
|
||||
'PYMODULE'),
|
||||
('importlib.readers',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\readers.py',
|
||||
'PYMODULE'),
|
||||
('importlib.resources',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\resources\\__init__.py',
|
||||
'PYMODULE'),
|
||||
('importlib.resources._adapters',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\resources\\_adapters.py',
|
||||
'PYMODULE'),
|
||||
('importlib.resources._common',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\resources\\_common.py',
|
||||
'PYMODULE'),
|
||||
('importlib.resources._functional',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\resources\\_functional.py',
|
||||
'PYMODULE'),
|
||||
('importlib.resources._itertools',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\resources\\_itertools.py',
|
||||
'PYMODULE'),
|
||||
('importlib.resources.abc',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\resources\\abc.py',
|
||||
'PYMODULE'),
|
||||
('importlib.resources.readers',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\resources\\readers.py',
|
||||
'PYMODULE'),
|
||||
('importlib.util',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\importlib\\util.py',
|
||||
'PYMODULE'),
|
||||
('inspect',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\inspect.py',
|
||||
'PYMODULE'),
|
||||
('ipaddress',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\ipaddress.py',
|
||||
'PYMODULE'),
|
||||
('json',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\json\\__init__.py',
|
||||
'PYMODULE'),
|
||||
('json.decoder',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\json\\decoder.py',
|
||||
'PYMODULE'),
|
||||
('json.encoder',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\json\\encoder.py',
|
||||
'PYMODULE'),
|
||||
('json.scanner',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\json\\scanner.py',
|
||||
'PYMODULE'),
|
||||
('logging',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\logging\\__init__.py',
|
||||
'PYMODULE'),
|
||||
('lzma',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\lzma.py',
|
||||
'PYMODULE'),
|
||||
('mimetypes',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\mimetypes.py',
|
||||
'PYMODULE'),
|
||||
('netrc',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\netrc.py',
|
||||
'PYMODULE'),
|
||||
('nturl2path',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\nturl2path.py',
|
||||
'PYMODULE'),
|
||||
('numbers',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\numbers.py',
|
||||
'PYMODULE'),
|
||||
('opcode',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\opcode.py',
|
||||
'PYMODULE'),
|
||||
('pathlib',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\pathlib\\__init__.py',
|
||||
'PYMODULE'),
|
||||
('pathlib._abc',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\pathlib\\_abc.py',
|
||||
'PYMODULE'),
|
||||
('pathlib._local',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\pathlib\\_local.py',
|
||||
'PYMODULE'),
|
||||
('pickle',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\pickle.py',
|
||||
'PYMODULE'),
|
||||
('pprint',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\pprint.py',
|
||||
'PYMODULE'),
|
||||
('py_compile',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\py_compile.py',
|
||||
'PYMODULE'),
|
||||
('quopri',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\quopri.py',
|
||||
'PYMODULE'),
|
||||
('random',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\random.py',
|
||||
'PYMODULE'),
|
||||
('selectors',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\selectors.py',
|
||||
'PYMODULE'),
|
||||
('shutil',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\shutil.py',
|
||||
'PYMODULE'),
|
||||
('signal',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\signal.py',
|
||||
'PYMODULE'),
|
||||
('socket',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\socket.py',
|
||||
'PYMODULE'),
|
||||
('ssl',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\ssl.py',
|
||||
'PYMODULE'),
|
||||
('statistics',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\statistics.py',
|
||||
'PYMODULE'),
|
||||
('string',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\string.py',
|
||||
'PYMODULE'),
|
||||
('stringprep',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\stringprep.py',
|
||||
'PYMODULE'),
|
||||
('subprocess',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\subprocess.py',
|
||||
'PYMODULE'),
|
||||
('tarfile',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\tarfile.py',
|
||||
'PYMODULE'),
|
||||
('tempfile',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\tempfile.py',
|
||||
'PYMODULE'),
|
||||
('textwrap',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\textwrap.py',
|
||||
'PYMODULE'),
|
||||
('threading',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\threading.py',
|
||||
'PYMODULE'),
|
||||
('token',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\token.py',
|
||||
'PYMODULE'),
|
||||
('tokenize',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\tokenize.py',
|
||||
'PYMODULE'),
|
||||
('tracemalloc',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\tracemalloc.py',
|
||||
'PYMODULE'),
|
||||
('typing',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\typing.py',
|
||||
'PYMODULE'),
|
||||
('urllib',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\urllib\\__init__.py',
|
||||
'PYMODULE'),
|
||||
('urllib.error',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\urllib\\error.py',
|
||||
'PYMODULE'),
|
||||
('urllib.parse',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\urllib\\parse.py',
|
||||
'PYMODULE'),
|
||||
('urllib.request',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\urllib\\request.py',
|
||||
'PYMODULE'),
|
||||
('urllib.response',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\urllib\\response.py',
|
||||
'PYMODULE'),
|
||||
('xml',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\xml\\__init__.py',
|
||||
'PYMODULE'),
|
||||
('xml.etree',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\xml\\etree\\__init__.py',
|
||||
'PYMODULE'),
|
||||
('xml.etree.ElementInclude',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\xml\\etree\\ElementInclude.py',
|
||||
'PYMODULE'),
|
||||
('xml.etree.ElementPath',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\xml\\etree\\ElementPath.py',
|
||||
'PYMODULE'),
|
||||
('xml.etree.ElementTree',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\xml\\etree\\ElementTree.py',
|
||||
'PYMODULE'),
|
||||
('xml.etree.cElementTree',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\xml\\etree\\cElementTree.py',
|
||||
'PYMODULE'),
|
||||
('xml.parsers',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\xml\\parsers\\__init__.py',
|
||||
'PYMODULE'),
|
||||
('xml.parsers.expat',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\xml\\parsers\\expat.py',
|
||||
'PYMODULE'),
|
||||
('xml.sax',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\xml\\sax\\__init__.py',
|
||||
'PYMODULE'),
|
||||
('xml.sax._exceptions',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\xml\\sax\\_exceptions.py',
|
||||
'PYMODULE'),
|
||||
('xml.sax.expatreader',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\xml\\sax\\expatreader.py',
|
||||
'PYMODULE'),
|
||||
('xml.sax.handler',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\xml\\sax\\handler.py',
|
||||
'PYMODULE'),
|
||||
('xml.sax.saxutils',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\xml\\sax\\saxutils.py',
|
||||
'PYMODULE'),
|
||||
('xml.sax.xmlreader',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\xml\\sax\\xmlreader.py',
|
||||
'PYMODULE'),
|
||||
('zipfile',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\zipfile\\__init__.py',
|
||||
'PYMODULE'),
|
||||
('zipfile._path',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\zipfile\\_path\\__init__.py',
|
||||
'PYMODULE'),
|
||||
('zipfile._path.glob',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\zipfile\\_path\\glob.py',
|
||||
'PYMODULE')])
|
BIN
build/generateVars/base_library.zip
Normal file
BIN
build/generateVars/base_library.zip
Normal file
Binary file not shown.
BIN
build/generateVars/generateVars.pkg
Normal file
BIN
build/generateVars/generateVars.pkg
Normal file
Binary file not shown.
BIN
build/generateVars/localpycs/pyimod01_archive.pyc
Normal file
BIN
build/generateVars/localpycs/pyimod01_archive.pyc
Normal file
Binary file not shown.
BIN
build/generateVars/localpycs/pyimod02_importers.pyc
Normal file
BIN
build/generateVars/localpycs/pyimod02_importers.pyc
Normal file
Binary file not shown.
BIN
build/generateVars/localpycs/pyimod03_ctypes.pyc
Normal file
BIN
build/generateVars/localpycs/pyimod03_ctypes.pyc
Normal file
Binary file not shown.
BIN
build/generateVars/localpycs/pyimod04_pywin32.pyc
Normal file
BIN
build/generateVars/localpycs/pyimod04_pywin32.pyc
Normal file
Binary file not shown.
BIN
build/generateVars/localpycs/struct.pyc
Normal file
BIN
build/generateVars/localpycs/struct.pyc
Normal file
Binary file not shown.
27
build/generateVars/warn-generateVars.txt
Normal file
27
build/generateVars/warn-generateVars.txt
Normal file
@ -0,0 +1,27 @@
|
||||
|
||||
This file lists modules PyInstaller was not able to find. This does not
|
||||
necessarily mean this module is required for running your program. Python and
|
||||
Python 3rd-party packages include a lot of conditional or optional modules. For
|
||||
example the module 'ntpath' only exists on Windows, whereas the module
|
||||
'posixpath' only exists on Posix systems.
|
||||
|
||||
Types if import:
|
||||
* top-level: imported at the top-level - look at these first
|
||||
* conditional: imported within an if-statement
|
||||
* delayed: imported within a function
|
||||
* optional: imported within a try-except-statement
|
||||
|
||||
IMPORTANT: Do NOT post this list to the issue-tracker. Use it as a basis for
|
||||
tracking down the missing module yourself. Thanks!
|
||||
|
||||
missing module named _frozen_importlib_external - imported by importlib._bootstrap (delayed), importlib (optional), importlib.abc (optional)
|
||||
excluded module named _frozen_importlib - imported by importlib (optional), importlib.abc (optional)
|
||||
missing module named 'collections.abc' - imported by traceback (top-level), typing (top-level), inspect (top-level), logging (top-level), importlib.resources.readers (top-level), selectors (top-level), tracemalloc (top-level), xml.etree.ElementTree (top-level), http.client (top-level)
|
||||
missing module named posix - imported by os (conditional, optional), posixpath (optional), shutil (conditional), importlib._bootstrap_external (conditional)
|
||||
missing module named resource - imported by posix (top-level)
|
||||
missing module named pwd - imported by posixpath (delayed, conditional, optional), shutil (delayed, optional), tarfile (optional), pathlib._local (optional), subprocess (delayed, conditional, optional), netrc (delayed, conditional), getpass (delayed, optional)
|
||||
missing module named grp - imported by shutil (delayed, optional), tarfile (optional), pathlib._local (optional), subprocess (delayed, conditional, optional)
|
||||
missing module named _scproxy - imported by urllib.request (conditional)
|
||||
missing module named termios - imported by getpass (optional)
|
||||
missing module named _posixsubprocess - imported by subprocess (conditional)
|
||||
missing module named fcntl - imported by subprocess (optional)
|
8214
build/generateVars/xref-generateVars.html
Normal file
8214
build/generateVars/xref-generateVars.html
Normal file
File diff suppressed because it is too large
Load Diff
BIN
build/libclang.dll
Normal file
BIN
build/libclang.dll
Normal file
Binary file not shown.
38
build/scanVars.spec
Normal file
38
build/scanVars.spec
Normal file
@ -0,0 +1,38 @@
|
||||
# -*- mode: python ; coding: utf-8 -*-
|
||||
|
||||
|
||||
a = Analysis(
|
||||
['..\\scanVars.py'],
|
||||
pathex=[],
|
||||
binaries=[('F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools/build/libclang.dll', '.')],
|
||||
datas=[],
|
||||
hiddenimports=[],
|
||||
hookspath=[],
|
||||
hooksconfig={},
|
||||
runtime_hooks=[],
|
||||
excludes=[],
|
||||
noarchive=False,
|
||||
optimize=0,
|
||||
)
|
||||
pyz = PYZ(a.pure)
|
||||
|
||||
exe = EXE(
|
||||
pyz,
|
||||
a.scripts,
|
||||
a.binaries,
|
||||
a.datas,
|
||||
[],
|
||||
name='scanVars',
|
||||
debug=False,
|
||||
bootloader_ignore_signals=False,
|
||||
strip=False,
|
||||
upx=True,
|
||||
upx_exclude=[],
|
||||
runtime_tmpdir=None,
|
||||
console=True,
|
||||
disable_windowed_traceback=False,
|
||||
argv_emulation=False,
|
||||
target_arch=None,
|
||||
codesign_identity=None,
|
||||
entitlements_file=None,
|
||||
)
|
2091
build/scanVars/Analysis-00.toc
Normal file
2091
build/scanVars/Analysis-00.toc
Normal file
File diff suppressed because it is too large
Load Diff
291
build/scanVars/EXE-00.toc
Normal file
291
build/scanVars/EXE-00.toc
Normal file
@ -0,0 +1,291 @@
|
||||
('F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\scanVars.exe',
|
||||
True,
|
||||
False,
|
||||
False,
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\bootloader\\images\\icon-console.ico',
|
||||
None,
|
||||
False,
|
||||
False,
|
||||
b'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\n<assembly xmlns='
|
||||
b'"urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">\n <trustInfo x'
|
||||
b'mlns="urn:schemas-microsoft-com:asm.v3">\n <security>\n <requested'
|
||||
b'Privileges>\n <requestedExecutionLevel level="asInvoker" uiAccess='
|
||||
b'"false"/>\n </requestedPrivileges>\n </security>\n </trustInfo>\n '
|
||||
b'<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">\n <'
|
||||
b'application>\n <supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f'
|
||||
b'0}"/>\n <supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"/>\n '
|
||||
b' <supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"/>\n <s'
|
||||
b'upportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"/>\n <supporte'
|
||||
b'dOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"/>\n </application>\n <'
|
||||
b'/compatibility>\n <application xmlns="urn:schemas-microsoft-com:asm.v3">'
|
||||
b'\n <windowsSettings>\n <longPathAware xmlns="http://schemas.micros'
|
||||
b'oft.com/SMI/2016/WindowsSettings">true</longPathAware>\n </windowsSett'
|
||||
b'ings>\n </application>\n <dependency>\n <dependentAssembly>\n <ass'
|
||||
b'emblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version='
|
||||
b'"6.0.0.0" processorArchitecture="*" publicKeyToken="6595b64144ccf1df" langua'
|
||||
b'ge="*"/>\n </dependentAssembly>\n </dependency>\n</assembly>',
|
||||
True,
|
||||
False,
|
||||
None,
|
||||
None,
|
||||
None,
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\scanVars.pkg',
|
||||
[('pyi-contents-directory _internal', '', 'OPTION'),
|
||||
('PYZ-00.pyz',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\PYZ-00.pyz',
|
||||
'PYZ'),
|
||||
('struct',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\localpycs\\struct.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod01_archive',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\localpycs\\pyimod01_archive.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod02_importers',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\localpycs\\pyimod02_importers.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod03_ctypes',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\localpycs\\pyimod03_ctypes.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod04_pywin32',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\localpycs\\pyimod04_pywin32.pyc',
|
||||
'PYMODULE'),
|
||||
('pyiboot01_bootstrap',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\loader\\pyiboot01_bootstrap.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_inspect',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_inspect.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_setuptools',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_setuptools.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_pkgutil',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_pkgutil.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_multiprocessing',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_multiprocessing.py',
|
||||
'PYSOURCE'),
|
||||
('scanVars',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\scanVars.py',
|
||||
'PYSOURCE'),
|
||||
('libclang.dll',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\libclang.dll',
|
||||
'BINARY'),
|
||||
('python313.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\python313.dll',
|
||||
'BINARY'),
|
||||
('select.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\select.pyd',
|
||||
'EXTENSION'),
|
||||
('_multiprocessing.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_multiprocessing.pyd',
|
||||
'EXTENSION'),
|
||||
('pyexpat.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\pyexpat.pyd',
|
||||
'EXTENSION'),
|
||||
('_ssl.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_ssl.pyd',
|
||||
'EXTENSION'),
|
||||
('_hashlib.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_hashlib.pyd',
|
||||
'EXTENSION'),
|
||||
('unicodedata.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\unicodedata.pyd',
|
||||
'EXTENSION'),
|
||||
('_decimal.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_decimal.pyd',
|
||||
'EXTENSION'),
|
||||
('_socket.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_socket.pyd',
|
||||
'EXTENSION'),
|
||||
('_lzma.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_lzma.pyd',
|
||||
'EXTENSION'),
|
||||
('_bz2.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_bz2.pyd',
|
||||
'EXTENSION'),
|
||||
('_ctypes.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_ctypes.pyd',
|
||||
'EXTENSION'),
|
||||
('_queue.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_queue.pyd',
|
||||
'EXTENSION'),
|
||||
('_overlapped.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_overlapped.pyd',
|
||||
'EXTENSION'),
|
||||
('_asyncio.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_asyncio.pyd',
|
||||
'EXTENSION'),
|
||||
('_wmi.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_wmi.pyd',
|
||||
'EXTENSION'),
|
||||
('_elementtree.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_elementtree.pyd',
|
||||
'EXTENSION'),
|
||||
('api-ms-win-crt-math-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-math-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-conio-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-conio-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-environment-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-environment-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-stdio-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-stdio-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-string-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-string-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-time-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-time-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-process-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-process-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-filesystem-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-filesystem-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-runtime-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-runtime-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-heap-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-heap-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-convert-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-convert-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('VCRUNTIME140.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\VCRUNTIME140.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-locale-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-locale-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-utility-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-utility-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('libssl-3.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\libssl-3.dll',
|
||||
'BINARY'),
|
||||
('libcrypto-3.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\libcrypto-3.dll',
|
||||
'BINARY'),
|
||||
('libffi-8.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\libffi-8.dll',
|
||||
'BINARY'),
|
||||
('VCRUNTIME140_1.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\VCRUNTIME140_1.dll',
|
||||
'BINARY'),
|
||||
('ucrtbase.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\ucrtbase.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l2-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-file-l2-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-libraryloader-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-libraryloader-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processthreads-l1-1-1.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-processthreads-l1-1-1.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-synch-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-synch-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-sysinfo-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-sysinfo-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-namedpipe-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-namedpipe-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-profile-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-profile-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-handle-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-handle-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-heap-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-heap-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-errorhandling-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-errorhandling-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-memory-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-memory-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-interlocked-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-interlocked-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-string-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-string-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-debug-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-debug-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-timezone-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-timezone-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-datetime-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-datetime-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processthreads-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-processthreads-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-console-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-console-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-synch-l1-2-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-synch-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-rtlsupport-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-rtlsupport-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processenvironment-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-processenvironment-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-file-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l1-2-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-file-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-localization-l1-2-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-localization-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-util-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-util-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\WHEEL',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\WHEEL',
|
||||
'DATA'),
|
||||
('setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\INSTALLER',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\INSTALLER',
|
||||
'DATA'),
|
||||
('setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\RECORD',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\RECORD',
|
||||
'DATA'),
|
||||
('setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\top_level.txt',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\top_level.txt',
|
||||
'DATA'),
|
||||
('setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\LICENSE',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\LICENSE',
|
||||
'DATA'),
|
||||
('setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\REQUESTED',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\REQUESTED',
|
||||
'DATA'),
|
||||
('setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\METADATA',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\METADATA',
|
||||
'DATA'),
|
||||
('setuptools\\_vendor\\jaraco\\text\\Lorem ipsum.txt',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\jaraco\\text\\Lorem '
|
||||
'ipsum.txt',
|
||||
'DATA'),
|
||||
('base_library.zip',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\base_library.zip',
|
||||
'DATA')],
|
||||
[],
|
||||
False,
|
||||
False,
|
||||
1751897901,
|
||||
[('run.exe',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\bootloader\\Windows-64bit-intel\\run.exe',
|
||||
'EXECUTABLE')],
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\python313.dll')
|
269
build/scanVars/PKG-00.toc
Normal file
269
build/scanVars/PKG-00.toc
Normal file
@ -0,0 +1,269 @@
|
||||
('F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\scanVars.pkg',
|
||||
{'BINARY': True,
|
||||
'DATA': True,
|
||||
'EXECUTABLE': True,
|
||||
'EXTENSION': True,
|
||||
'PYMODULE': True,
|
||||
'PYSOURCE': True,
|
||||
'PYZ': False,
|
||||
'SPLASH': True,
|
||||
'SYMLINK': False},
|
||||
[('pyi-contents-directory _internal', '', 'OPTION'),
|
||||
('PYZ-00.pyz',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\PYZ-00.pyz',
|
||||
'PYZ'),
|
||||
('struct',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\localpycs\\struct.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod01_archive',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\localpycs\\pyimod01_archive.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod02_importers',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\localpycs\\pyimod02_importers.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod03_ctypes',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\localpycs\\pyimod03_ctypes.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod04_pywin32',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\localpycs\\pyimod04_pywin32.pyc',
|
||||
'PYMODULE'),
|
||||
('pyiboot01_bootstrap',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\loader\\pyiboot01_bootstrap.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_inspect',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_inspect.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_setuptools',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_setuptools.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_pkgutil',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_pkgutil.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_multiprocessing',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_multiprocessing.py',
|
||||
'PYSOURCE'),
|
||||
('scanVars',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\scanVars.py',
|
||||
'PYSOURCE'),
|
||||
('libclang.dll',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\libclang.dll',
|
||||
'BINARY'),
|
||||
('python313.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\python313.dll',
|
||||
'BINARY'),
|
||||
('select.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\select.pyd',
|
||||
'EXTENSION'),
|
||||
('_multiprocessing.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_multiprocessing.pyd',
|
||||
'EXTENSION'),
|
||||
('pyexpat.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\pyexpat.pyd',
|
||||
'EXTENSION'),
|
||||
('_ssl.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_ssl.pyd',
|
||||
'EXTENSION'),
|
||||
('_hashlib.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_hashlib.pyd',
|
||||
'EXTENSION'),
|
||||
('unicodedata.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\unicodedata.pyd',
|
||||
'EXTENSION'),
|
||||
('_decimal.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_decimal.pyd',
|
||||
'EXTENSION'),
|
||||
('_socket.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_socket.pyd',
|
||||
'EXTENSION'),
|
||||
('_lzma.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_lzma.pyd',
|
||||
'EXTENSION'),
|
||||
('_bz2.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_bz2.pyd',
|
||||
'EXTENSION'),
|
||||
('_ctypes.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_ctypes.pyd',
|
||||
'EXTENSION'),
|
||||
('_queue.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_queue.pyd',
|
||||
'EXTENSION'),
|
||||
('_overlapped.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_overlapped.pyd',
|
||||
'EXTENSION'),
|
||||
('_asyncio.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_asyncio.pyd',
|
||||
'EXTENSION'),
|
||||
('_wmi.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_wmi.pyd',
|
||||
'EXTENSION'),
|
||||
('_elementtree.pyd',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\_elementtree.pyd',
|
||||
'EXTENSION'),
|
||||
('api-ms-win-crt-math-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-math-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-conio-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-conio-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-environment-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-environment-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-stdio-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-stdio-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-string-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-string-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-time-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-time-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-process-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-process-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-filesystem-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-filesystem-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-runtime-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-runtime-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-heap-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-heap-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-convert-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-convert-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('VCRUNTIME140.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\VCRUNTIME140.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-locale-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-locale-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-utility-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-crt-utility-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('libssl-3.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\libssl-3.dll',
|
||||
'BINARY'),
|
||||
('libcrypto-3.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\libcrypto-3.dll',
|
||||
'BINARY'),
|
||||
('libffi-8.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\DLLs\\libffi-8.dll',
|
||||
'BINARY'),
|
||||
('VCRUNTIME140_1.dll',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\VCRUNTIME140_1.dll',
|
||||
'BINARY'),
|
||||
('ucrtbase.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\ucrtbase.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l2-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-file-l2-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-libraryloader-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-libraryloader-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processthreads-l1-1-1.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-processthreads-l1-1-1.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-synch-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-synch-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-sysinfo-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-sysinfo-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-namedpipe-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-namedpipe-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-profile-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-profile-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-handle-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-handle-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-heap-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-heap-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-errorhandling-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-errorhandling-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-memory-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-memory-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-interlocked-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-interlocked-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-string-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-string-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-debug-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-debug-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-timezone-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-timezone-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-datetime-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-datetime-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processthreads-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-processthreads-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-console-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-console-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-synch-l1-2-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-synch-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-rtlsupport-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-rtlsupport-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processenvironment-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-processenvironment-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-file-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l1-2-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-file-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-localization-l1-2-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-localization-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-util-l1-1-0.dll',
|
||||
'F:\\Work\\Programs\\Active-HDL-13-x64\\bin\\api-ms-win-core-util-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\WHEEL',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\WHEEL',
|
||||
'DATA'),
|
||||
('setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\INSTALLER',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\INSTALLER',
|
||||
'DATA'),
|
||||
('setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\RECORD',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\RECORD',
|
||||
'DATA'),
|
||||
('setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\top_level.txt',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\top_level.txt',
|
||||
'DATA'),
|
||||
('setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\LICENSE',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\LICENSE',
|
||||
'DATA'),
|
||||
('setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\REQUESTED',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\REQUESTED',
|
||||
'DATA'),
|
||||
('setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\METADATA',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\importlib_metadata-8.0.0.dist-info\\METADATA',
|
||||
'DATA'),
|
||||
('setuptools\\_vendor\\jaraco\\text\\Lorem ipsum.txt',
|
||||
'C:\\Users\\I\\AppData\\Local\\Programs\\Python\\Python313\\Lib\\site-packages\\setuptools\\_vendor\\jaraco\\text\\Lorem '
|
||||
'ipsum.txt',
|
||||
'DATA'),
|
||||
('base_library.zip',
|
||||
'F:\\Work\\Projects\\TMS\\TMS_new_bus\\Src\\DebugTools\\build\\scanVars\\base_library.zip',
|
||||
'DATA')],
|
||||
'python313.dll',
|
||||
False,
|
||||
False,
|
||||
False,
|
||||
[],
|
||||
None,
|
||||
None,
|
||||
None)
|
BIN
build/scanVars/PYZ-00.pyz
Normal file
BIN
build/scanVars/PYZ-00.pyz
Normal file
Binary file not shown.
1377
build/scanVars/PYZ-00.toc
Normal file
1377
build/scanVars/PYZ-00.toc
Normal file
File diff suppressed because it is too large
Load Diff
BIN
build/scanVars/base_library.zip
Normal file
BIN
build/scanVars/base_library.zip
Normal file
Binary file not shown.
BIN
build/scanVars/localpycs/pyimod01_archive.pyc
Normal file
BIN
build/scanVars/localpycs/pyimod01_archive.pyc
Normal file
Binary file not shown.
BIN
build/scanVars/localpycs/pyimod02_importers.pyc
Normal file
BIN
build/scanVars/localpycs/pyimod02_importers.pyc
Normal file
Binary file not shown.
BIN
build/scanVars/localpycs/pyimod03_ctypes.pyc
Normal file
BIN
build/scanVars/localpycs/pyimod03_ctypes.pyc
Normal file
Binary file not shown.
BIN
build/scanVars/localpycs/pyimod04_pywin32.pyc
Normal file
BIN
build/scanVars/localpycs/pyimod04_pywin32.pyc
Normal file
Binary file not shown.
BIN
build/scanVars/localpycs/struct.pyc
Normal file
BIN
build/scanVars/localpycs/struct.pyc
Normal file
Binary file not shown.
BIN
build/scanVars/scanVars.pkg
Normal file
BIN
build/scanVars/scanVars.pkg
Normal file
Binary file not shown.
54
build/scanVars/warn-scanVars.txt
Normal file
54
build/scanVars/warn-scanVars.txt
Normal file
@ -0,0 +1,54 @@
|
||||
|
||||
This file lists modules PyInstaller was not able to find. This does not
|
||||
necessarily mean this module is required for running your program. Python and
|
||||
Python 3rd-party packages include a lot of conditional or optional modules. For
|
||||
example the module 'ntpath' only exists on Windows, whereas the module
|
||||
'posixpath' only exists on Posix systems.
|
||||
|
||||
Types if import:
|
||||
* top-level: imported at the top-level - look at these first
|
||||
* conditional: imported within an if-statement
|
||||
* delayed: imported within a function
|
||||
* optional: imported within a try-except-statement
|
||||
|
||||
IMPORTANT: Do NOT post this list to the issue-tracker. Use it as a basis for
|
||||
tracking down the missing module yourself. Thanks!
|
||||
|
||||
missing module named pwd - imported by posixpath (delayed, conditional, optional), shutil (delayed, optional), tarfile (optional), pathlib._local (optional), subprocess (delayed, conditional, optional), setuptools._distutils.util (delayed, conditional, optional), netrc (delayed, conditional), getpass (delayed, optional), setuptools._vendor.backports.tarfile (optional), setuptools._distutils.archive_util (optional), http.server (delayed, optional)
|
||||
missing module named grp - imported by shutil (delayed, optional), tarfile (optional), pathlib._local (optional), subprocess (delayed, conditional, optional), setuptools._vendor.backports.tarfile (optional), setuptools._distutils.archive_util (optional)
|
||||
missing module named 'collections.abc' - imported by traceback (top-level), typing (top-level), inspect (top-level), logging (top-level), importlib.resources.readers (top-level), selectors (top-level), tracemalloc (top-level), setuptools (top-level), setuptools._distutils.filelist (top-level), setuptools._distutils.util (top-level), setuptools._vendor.jaraco.functools (top-level), setuptools._vendor.more_itertools.more (top-level), setuptools._vendor.more_itertools.recipes (top-level), setuptools._distutils._modified (top-level), setuptools._distutils.compat (top-level), setuptools._distutils.spawn (top-level), setuptools._distutils.compilers.C.base (top-level), setuptools._distutils.fancy_getopt (top-level), setuptools._reqs (top-level), http.client (top-level), setuptools.discovery (top-level), setuptools.dist (top-level), setuptools._distutils.command.bdist (top-level), setuptools._distutils.core (top-level), setuptools._distutils.cmd (top-level), setuptools._distutils.dist (top-level), configparser (top-level), setuptools._distutils.extension (top-level), setuptools.config.setupcfg (top-level), setuptools.config.expand (top-level), setuptools.config.pyprojecttoml (top-level), setuptools.config._apply_pyprojecttoml (top-level), tomllib._parser (top-level), setuptools._vendor.tomli._parser (top-level), setuptools.command.egg_info (top-level), setuptools._distutils.command.build (top-level), setuptools._distutils.command.sdist (top-level), setuptools.glob (top-level), setuptools.command._requirestxt (top-level), setuptools.command.bdist_wheel (top-level), setuptools._vendor.wheel.cli.convert (top-level), setuptools._vendor.wheel.cli.tags (top-level), setuptools._vendor.typing_extensions (top-level), xml.etree.ElementTree (top-level), setuptools._distutils.command.build_ext (top-level), _pyrepl.types (top-level), _pyrepl.readline (top-level), asyncio.base_events (top-level), asyncio.coroutines (top-level), setuptools._distutils.compilers.C.msvc (top-level)
|
||||
missing module named _posixsubprocess - imported by subprocess (conditional), multiprocessing.util (delayed)
|
||||
missing module named fcntl - imported by subprocess (optional), _pyrepl.unix_console (top-level)
|
||||
missing module named _posixshmem - imported by multiprocessing.resource_tracker (conditional), multiprocessing.shared_memory (conditional)
|
||||
missing module named _scproxy - imported by urllib.request (conditional)
|
||||
missing module named termios - imported by getpass (optional), tty (top-level), _pyrepl.pager (delayed, optional), _pyrepl.unix_console (top-level), _pyrepl.fancy_termios (top-level), _pyrepl.unix_eventqueue (top-level)
|
||||
missing module named multiprocessing.BufferTooShort - imported by multiprocessing (top-level), multiprocessing.connection (top-level)
|
||||
missing module named multiprocessing.AuthenticationError - imported by multiprocessing (top-level), multiprocessing.connection (top-level)
|
||||
missing module named _frozen_importlib_external - imported by importlib._bootstrap (delayed), importlib (optional), importlib.abc (optional), zipimport (top-level)
|
||||
excluded module named _frozen_importlib - imported by importlib (optional), importlib.abc (optional), zipimport (top-level)
|
||||
missing module named posix - imported by os (conditional, optional), posixpath (optional), shutil (conditional), importlib._bootstrap_external (conditional), _pyrepl.unix_console (delayed, optional)
|
||||
missing module named resource - imported by posix (top-level)
|
||||
missing module named multiprocessing.get_context - imported by multiprocessing (top-level), multiprocessing.pool (top-level), multiprocessing.managers (top-level), multiprocessing.sharedctypes (top-level)
|
||||
missing module named multiprocessing.TimeoutError - imported by multiprocessing (top-level), multiprocessing.pool (top-level)
|
||||
missing module named multiprocessing.set_start_method - imported by multiprocessing (top-level), multiprocessing.spawn (top-level)
|
||||
missing module named multiprocessing.get_start_method - imported by multiprocessing (top-level), multiprocessing.spawn (top-level)
|
||||
missing module named pyimod02_importers - imported by C:\Users\I\AppData\Local\Programs\Python\Python313\Lib\site-packages\PyInstaller\hooks\rthooks\pyi_rth_pkgutil.py (delayed)
|
||||
missing module named typing_extensions.Buffer - imported by setuptools._vendor.typing_extensions (top-level), setuptools._vendor.wheel.wheelfile (conditional)
|
||||
missing module named typing_extensions.Literal - imported by setuptools._vendor.typing_extensions (top-level), setuptools.config._validate_pyproject.formats (conditional)
|
||||
missing module named typing_extensions.Self - imported by setuptools._vendor.typing_extensions (top-level), setuptools.config.expand (conditional), setuptools.config.pyprojecttoml (conditional), setuptools.config._validate_pyproject.error_reporting (conditional)
|
||||
missing module named typing_extensions.deprecated - imported by setuptools._vendor.typing_extensions (top-level), setuptools._distutils.sysconfig (conditional), setuptools._distutils.command.bdist (conditional)
|
||||
missing module named typing_extensions.TypeAlias - imported by setuptools._vendor.typing_extensions (top-level), setuptools._distutils.compilers.C.base (conditional), setuptools._reqs (conditional), setuptools.warnings (conditional), setuptools._path (conditional), setuptools._distutils.dist (conditional), setuptools.config.setupcfg (conditional), setuptools.config._apply_pyprojecttoml (conditional), setuptools.dist (conditional), setuptools.command.bdist_egg (conditional), setuptools.compat.py311 (conditional)
|
||||
missing module named typing_extensions.Unpack - imported by setuptools._vendor.typing_extensions (top-level), setuptools._distutils.util (conditional), setuptools._distutils.compilers.C.base (conditional), setuptools._distutils.cmd (conditional)
|
||||
missing module named typing_extensions.TypeVarTuple - imported by setuptools._vendor.typing_extensions (top-level), setuptools._distutils.util (conditional), setuptools._distutils.compilers.C.base (conditional), setuptools._distutils.cmd (conditional)
|
||||
missing module named asyncio.DefaultEventLoopPolicy - imported by asyncio (delayed, conditional), asyncio.events (delayed, conditional)
|
||||
missing module named vms_lib - imported by platform (delayed, optional)
|
||||
missing module named 'java.lang' - imported by platform (delayed, optional)
|
||||
missing module named java - imported by platform (delayed)
|
||||
missing module named usercustomize - imported by site (delayed, optional)
|
||||
missing module named sitecustomize - imported by site (delayed, optional)
|
||||
missing module named _curses - imported by curses (top-level), curses.has_key (top-level), _pyrepl.curses (optional)
|
||||
missing module named readline - imported by site (delayed, optional), rlcompleter (optional), code (delayed, conditional, optional)
|
||||
missing module named _typeshed - imported by setuptools._distutils.dist (conditional), setuptools.glob (conditional), setuptools.compat.py311 (conditional)
|
||||
missing module named _manylinux - imported by packaging._manylinux (delayed, optional), setuptools._vendor.packaging._manylinux (delayed, optional), setuptools._vendor.wheel.vendored.packaging._manylinux (delayed, optional)
|
||||
missing module named importlib_resources - imported by setuptools._vendor.jaraco.text (optional)
|
||||
missing module named trove_classifiers - imported by setuptools.config._validate_pyproject.formats (optional)
|
18924
build/scanVars/xref-scanVars.html
Normal file
18924
build/scanVars/xref-scanVars.html
Normal file
File diff suppressed because it is too large
Load Diff
290
debug_tools.c
Normal file
290
debug_tools.c
Normal file
@ -0,0 +1,290 @@
|
||||
#include "debug_tools.h"
|
||||
#include "IQmathLib.h"
|
||||
|
||||
static int getDebugVar(DebugVar_t *var, long *int_var, float *float_var);
|
||||
static int convertDebugVarToIQx(DebugVar_t *var, long *ret_var, DebugVarIQType_t iq_type_final);
|
||||
|
||||
DebugVarIQType_t dbg_type = t_iq24;
|
||||
|
||||
long Debug_ReadVar(DebugVar_t *var, DebugVarIQType_t iq_type_final)
|
||||
{
|
||||
long tmp_var;
|
||||
if((var->ptr_type == pt_struct) || (var->ptr_type == pt_union) || (var->ptr_type == pt_unknown))
|
||||
return;
|
||||
|
||||
convertDebugVarToIQx(var, &tmp_var, dbg_type);
|
||||
|
||||
return tmp_var;
|
||||
}
|
||||
|
||||
static int convertDebugVarToIQx(DebugVar_t *var, long *ret_var, DebugVarIQType_t iq_type_final)
|
||||
{
|
||||
long iq_numb, iq_united, iq_final;
|
||||
float float_numb;
|
||||
|
||||
if(getDebugVar(var, &iq_numb, &float_numb) == 1)
|
||||
return 1;
|
||||
|
||||
// ïðèâåäåíèå ê îäíîìó IQ
|
||||
switch(var->iq_type)
|
||||
{
|
||||
case t_iq_none:
|
||||
if(var->ptr_type == pt_float)
|
||||
{
|
||||
iq_united = _IQ(float_numb);
|
||||
}
|
||||
else
|
||||
{
|
||||
iq_united = _IQ(iq_numb);
|
||||
}
|
||||
break;
|
||||
case t_iq1:
|
||||
iq_united = _IQ1toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq2:
|
||||
iq_united = _IQ2toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq3:
|
||||
iq_united = _IQ3toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq4:
|
||||
iq_united = _IQ4toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq5:
|
||||
iq_united = _IQ5toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq6:
|
||||
iq_united = _IQ6toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq7:
|
||||
iq_united = _IQ7toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq8:
|
||||
iq_united = _IQ8toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq9:
|
||||
iq_united = _IQ9toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq10:
|
||||
iq_united = _IQ10toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq11:
|
||||
iq_united = _IQ11toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq12:
|
||||
iq_united = _IQ12toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq13:
|
||||
iq_united = _IQ13toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq14:
|
||||
iq_united = _IQ14toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq15:
|
||||
iq_united = _IQ15toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq16:
|
||||
iq_united = _IQ16toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq17:
|
||||
iq_united = _IQ17toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq18:
|
||||
iq_united = _IQ18toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq19:
|
||||
iq_united = _IQ19toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq20:
|
||||
iq_united = _IQ20toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq21:
|
||||
iq_united = _IQ21toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq22:
|
||||
iq_united = _IQ22toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq23:
|
||||
iq_united = _IQ23toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq24:
|
||||
iq_united = _IQ24toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq25:
|
||||
iq_united = _IQ25toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq26:
|
||||
iq_united = _IQ26toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq27:
|
||||
iq_united = _IQ27toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq28:
|
||||
iq_united = _IQ28toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq29:
|
||||
iq_united = _IQ29toIQ(iq_numb);
|
||||
break;
|
||||
case t_iq30:
|
||||
iq_united = _IQ30toIQ(iq_numb);
|
||||
break;
|
||||
}
|
||||
|
||||
// ïðèâåäåíèå îáùåãî IQ ê çàïðàøèâàåìîìó
|
||||
switch(iq_type_final)
|
||||
{
|
||||
case t_iq_none:
|
||||
iq_final = (int)_IQtoF(iq_united);
|
||||
break;
|
||||
case t_iq1:
|
||||
iq_final = _IQtoIQ1(iq_united);
|
||||
break;
|
||||
case t_iq2:
|
||||
iq_final = _IQtoIQ2(iq_united);
|
||||
break;
|
||||
case t_iq3:
|
||||
iq_final = _IQtoIQ3(iq_united);
|
||||
break;
|
||||
case t_iq4:
|
||||
iq_final = _IQtoIQ4(iq_united);
|
||||
break;
|
||||
case t_iq5:
|
||||
iq_final = _IQtoIQ5(iq_united);
|
||||
break;
|
||||
case t_iq6:
|
||||
iq_final = _IQtoIQ6(iq_united);
|
||||
break;
|
||||
case t_iq7:
|
||||
iq_final = _IQtoIQ7(iq_united);
|
||||
break;
|
||||
case t_iq8:
|
||||
iq_final = _IQtoIQ8(iq_united);
|
||||
break;
|
||||
case t_iq9:
|
||||
iq_final = _IQtoIQ9(iq_united);
|
||||
break;
|
||||
case t_iq10:
|
||||
iq_final = _IQtoIQ10(iq_united);
|
||||
break;
|
||||
case t_iq11:
|
||||
iq_final = _IQtoIQ11(iq_united);
|
||||
break;
|
||||
case t_iq12:
|
||||
iq_final = _IQtoIQ12(iq_united);
|
||||
break;
|
||||
case t_iq13:
|
||||
iq_final = _IQtoIQ13(iq_united);
|
||||
break;
|
||||
case t_iq14:
|
||||
iq_final = _IQtoIQ14(iq_united);
|
||||
break;
|
||||
case t_iq15:
|
||||
iq_final = _IQtoIQ15(iq_united);
|
||||
break;
|
||||
case t_iq16:
|
||||
iq_final = _IQtoIQ16(iq_united);
|
||||
break;
|
||||
case t_iq17:
|
||||
iq_final = _IQtoIQ17(iq_united);
|
||||
break;
|
||||
case t_iq18:
|
||||
iq_final = _IQtoIQ18(iq_united);
|
||||
break;
|
||||
case t_iq19:
|
||||
iq_final = _IQtoIQ19(iq_united);
|
||||
break;
|
||||
case t_iq20:
|
||||
iq_final = _IQtoIQ20(iq_united);
|
||||
break;
|
||||
case t_iq21:
|
||||
iq_final = _IQtoIQ21(iq_united);
|
||||
break;
|
||||
case t_iq22:
|
||||
iq_final = _IQtoIQ22(iq_united);
|
||||
break;
|
||||
case t_iq23:
|
||||
iq_final = _IQtoIQ23(iq_united);
|
||||
break;
|
||||
case t_iq24:
|
||||
iq_final = _IQtoIQ24(iq_united);
|
||||
break;
|
||||
case t_iq25:
|
||||
iq_final = _IQtoIQ25(iq_united);
|
||||
break;
|
||||
case t_iq26:
|
||||
iq_final = _IQtoIQ26(iq_united);
|
||||
break;
|
||||
case t_iq27:
|
||||
iq_final = _IQtoIQ27(iq_united);
|
||||
break;
|
||||
case t_iq28:
|
||||
iq_final = _IQtoIQ28(iq_united);
|
||||
break;
|
||||
case t_iq29:
|
||||
iq_final = _IQtoIQ29(iq_united);
|
||||
break;
|
||||
case t_iq30:
|
||||
iq_final = _IQtoIQ30(iq_united);
|
||||
break;
|
||||
}
|
||||
|
||||
*ret_var = iq_final;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
static int getDebugVar(DebugVar_t *var, long *int_var, float *float_var)
|
||||
{
|
||||
if (!var || !int_var || !float_var)
|
||||
return 1; // îøèáêà: null óêàçàòåëü
|
||||
|
||||
switch (var->ptr_type)
|
||||
{
|
||||
case pt_int8: // signed char
|
||||
*int_var = *((signed char *)var->Ptr);
|
||||
break;
|
||||
|
||||
case pt_int16: // int
|
||||
*int_var = *((int *)var->Ptr);
|
||||
break;
|
||||
|
||||
case pt_int32: // long
|
||||
*int_var = *((long *)var->Ptr);
|
||||
break;
|
||||
|
||||
case pt_uint8: // unsigned char
|
||||
*int_var = *((unsigned char *)var->Ptr);
|
||||
break;
|
||||
|
||||
case pt_uint16: // unsigned int
|
||||
*int_var = *((unsigned int *)var->Ptr);
|
||||
break;
|
||||
|
||||
case pt_uint32: // unsigned long
|
||||
*int_var = *((unsigned long *)var->Ptr);
|
||||
break;
|
||||
|
||||
case pt_float: // float
|
||||
*float_var = *((float *)var->Ptr);
|
||||
break;
|
||||
|
||||
// äëÿ óêàçàòåëåé è ìàññèâîâ íå ïîääåðæèâàåòñÿ ÷òåíèå
|
||||
// case pt_ptr_int8:
|
||||
// case pt_ptr_int16:
|
||||
// case pt_ptr_int32:
|
||||
// case pt_ptr_uint8:
|
||||
// case pt_ptr_uint16:
|
||||
// case pt_ptr_uint32:
|
||||
// case pt_arr_int8:
|
||||
// case pt_arr_int16:
|
||||
// case pt_arr_int32:
|
||||
// case pt_arr_uint8:
|
||||
// case pt_arr_uint16:
|
||||
// case pt_arr_uint32:
|
||||
default:
|
||||
return 1;
|
||||
}
|
||||
|
||||
return 0; // óñïåõ
|
||||
}
|
81
debug_tools.h
Normal file
81
debug_tools.h
Normal file
@ -0,0 +1,81 @@
|
||||
#ifndef DEBUG_TOOLS
|
||||
#define DEBUG_TOOLS
|
||||
#include "IQmathLib.h"
|
||||
#include "DSP281x_Device.h"
|
||||
|
||||
typedef enum
|
||||
{
|
||||
pt_unknown, // unknown
|
||||
pt_int8, // signed char
|
||||
pt_int16, // int
|
||||
pt_int32, // long
|
||||
pt_uint8, // unsigned char
|
||||
pt_uint16, // unsigned int
|
||||
pt_uint32, // unsigned long
|
||||
pt_float, // float
|
||||
pt_struct, // struct
|
||||
pt_union, // struct
|
||||
// pt_ptr_int8, // signed char*
|
||||
// pt_ptr_int16, // int*
|
||||
// pt_ptr_int32, // long*
|
||||
// pt_ptr_uint8, // unsigned char*
|
||||
// pt_ptr_uint16, // unsigned int*
|
||||
// pt_ptr_uint32, // unsigned long*
|
||||
// pt_arr_int8, // signed char[]
|
||||
// pt_arr_int16, // int[]
|
||||
// pt_arr_int32, // long[]
|
||||
// pt_arr_uint8, // unsigned char[]
|
||||
// pt_arr_uint16, // unsigned int[]
|
||||
// pt_arr_uint32, // unsigned long[]
|
||||
}DebugVarPtrType_t;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
t_iq_none,
|
||||
t_iq,
|
||||
t_iq1,
|
||||
t_iq2,
|
||||
t_iq3,
|
||||
t_iq4,
|
||||
t_iq5,
|
||||
t_iq6,
|
||||
t_iq7,
|
||||
t_iq8,
|
||||
t_iq9,
|
||||
t_iq10,
|
||||
t_iq11,
|
||||
t_iq12,
|
||||
t_iq13,
|
||||
t_iq14,
|
||||
t_iq15,
|
||||
t_iq16,
|
||||
t_iq17,
|
||||
t_iq18,
|
||||
t_iq19,
|
||||
t_iq20,
|
||||
t_iq21,
|
||||
t_iq22,
|
||||
t_iq23,
|
||||
t_iq24,
|
||||
t_iq25,
|
||||
t_iq26,
|
||||
t_iq27,
|
||||
t_iq28,
|
||||
t_iq29,
|
||||
t_iq30
|
||||
}DebugVarIQType_t;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
char* Ptr;
|
||||
DebugVarPtrType_t ptr_type;
|
||||
DebugVarIQType_t iq_type;
|
||||
char name[10];
|
||||
}DebugVar_t;
|
||||
|
||||
|
||||
extern int DebugVar_Qnt;
|
||||
extern DebugVar_t dbg_vars[];
|
||||
long Debug_ReadVar(DebugVar_t *var, DebugVarIQType_t iq_type_final);
|
||||
|
||||
#endif //DEBUG_TOOLS
|
328
debug_vars.c
Normal file
328
debug_vars.c
Normal file
@ -0,0 +1,328 @@
|
||||
// Ýòîò ôàéë ñãåíåðèðîâàí àâòîìàòè÷åñêè
|
||||
#include "debug_tools.h"
|
||||
|
||||
|
||||
// Èíêëþäû äëÿ äîñòóïà ê ïåðåìåííûì
|
||||
#include "RS_Functions_modbus.h"
|
||||
#include "xp_project.h"
|
||||
#include "v_pwm24.h"
|
||||
#include "adc_tools.h"
|
||||
#include "vector.h"
|
||||
#include "errors.h"
|
||||
#include "f281xpwm.h"
|
||||
#include "pwm_vector_regul.h"
|
||||
#include "log_can.h"
|
||||
#include "xp_write_xpwm_time.h"
|
||||
#include "rotation_speed.h"
|
||||
#include "teta_calc.h"
|
||||
#include "dq_to_alphabeta_cos.h"
|
||||
#include "RS_Functions.h"
|
||||
#include "x_parallel_bus.h"
|
||||
#include "x_serial_bus.h"
|
||||
#include "xp_rotation_sensor.h"
|
||||
#include "xp_controller.h"
|
||||
#include "Spartan2E_Functions.h"
|
||||
#include "xPeriphSP6_loader.h"
|
||||
#include "svgen_dq.h"
|
||||
#include "detect_phase_break2.h"
|
||||
#include "log_params.h"
|
||||
#include "global_time.h"
|
||||
#include "CAN_Setup.h"
|
||||
#include "CRC_Functions.h"
|
||||
#include "log_to_memory.h"
|
||||
#include "pid_reg3.h"
|
||||
#include "IQmathLib.h"
|
||||
#include "doors_control.h"
|
||||
#include "isolation.h"
|
||||
#include "main22220.h"
|
||||
#include "optical_bus.h"
|
||||
#include "alarm_log_can.h"
|
||||
#include "bender.h"
|
||||
#include "can_watercool.h"
|
||||
#include "detect_phase_break.h"
|
||||
#include "modbus_read_table.h"
|
||||
#include "rmp_cntl_my1.h"
|
||||
|
||||
|
||||
// Ýêñòåðíû äëÿ äîñòóïà ê ïåðåìåííûì
|
||||
extern int ADC0finishAddr;
|
||||
extern int ADC0startAddr;
|
||||
extern int ADC1finishAddr;
|
||||
extern int ADC1startAddr;
|
||||
extern int ADC2finishAddr;
|
||||
extern int ADC2startAddr;
|
||||
extern int ADC_f[2][16];
|
||||
extern int ADC_sf[2][16];
|
||||
extern int ADDR_FOR_ALL;
|
||||
extern int BUSY;
|
||||
extern BENDER Bender[2];
|
||||
extern int CAN_answer_wait[32];
|
||||
extern int CAN_count_cycle_input_units[8];
|
||||
extern int CAN_no_answer[32];
|
||||
extern int CAN_refresh_cicle[32];
|
||||
extern int CAN_request_sent[32];
|
||||
extern int CAN_timeout[32];
|
||||
extern int CAN_timeout_cicle[32];
|
||||
extern int CNTRL_ADDR;
|
||||
extern const int CNTRL_ADDR_UNIVERSAL;
|
||||
extern _iq CONST_15;
|
||||
extern _iq CONST_23;
|
||||
extern int CanOpenUnites[30];
|
||||
extern int CanTimeOutErrorTR;
|
||||
extern XControll_reg Controll;
|
||||
extern int Dpwm;
|
||||
extern int Dpwm2;
|
||||
extern int Dpwm4;
|
||||
extern int EvaTimer1InterruptCount;
|
||||
extern int EvaTimer2InterruptCount;
|
||||
extern int EvbTimer3InterruptCount;
|
||||
extern int EvbTimer4InterruptCount;
|
||||
extern int Fpwm;
|
||||
extern int IN0finishAddr;
|
||||
extern int IN0startAddr;
|
||||
extern int IN1finishAddr;
|
||||
extern int IN1startAddr;
|
||||
extern int IN2finishAddr;
|
||||
extern int IN2startAddr;
|
||||
extern float IQ_OUT_NOM;
|
||||
extern long I_OUT_1_6_NOMINAL_IQ;
|
||||
extern long I_OUT_1_8_NOMINAL_IQ;
|
||||
extern float I_OUT_NOMINAL;
|
||||
extern long I_OUT_NOMINAL_IQ;
|
||||
extern long I_ZPT_NOMINAL_IQ;
|
||||
extern _iq Id_out_max_full;
|
||||
extern _iq Id_out_max_low_speed;
|
||||
extern _iq Iq_out_max;
|
||||
extern _iq Iq_out_nom;
|
||||
extern const unsigned long K_LEM_ADC[20];
|
||||
extern float KmodTerm;
|
||||
extern int ROTfinishAddr;
|
||||
extern unsigned int RS_Len[70];
|
||||
extern const unsigned int R_ADC[20];
|
||||
extern int RotPlaneStartAddr;
|
||||
extern _iq SQRT_32;
|
||||
extern int Unites[8][128];
|
||||
extern int VAR_FREQ_PWM_XTICS;
|
||||
extern int VAR_PERIOD_MAX_XTICS;
|
||||
extern int VAR_PERIOD_MIN_BR_XTICS;
|
||||
extern int VAR_PERIOD_MIN_XTICS;
|
||||
extern int Zpwm;
|
||||
extern WINDING a;
|
||||
extern volatile AddrToSent addrToSent;
|
||||
extern unsigned int adr_read_from_modbus3;
|
||||
extern ALARM_LOG_CAN alarm_log_can;
|
||||
extern ALARM_LOG_CAN_SETUP alarm_log_can_setup;
|
||||
extern ANALOG_VALUE analog;
|
||||
extern int ar_sa_all[3][6][4][7];
|
||||
extern _iq ar_tph[7];
|
||||
extern int block_size_counter_fast;
|
||||
extern int block_size_counter_slow;
|
||||
extern _iq break_result_1;
|
||||
extern _iq break_result_2;
|
||||
extern _iq break_result_3;
|
||||
extern _iq break_result_4;
|
||||
extern Byte byte;
|
||||
extern long c_s;
|
||||
extern int calibration1;
|
||||
extern int calibration2;
|
||||
extern test_functions callfunc;
|
||||
extern CANOPEN_CAN_SETUP canopen_can_setup;
|
||||
extern unsigned int capnum0;
|
||||
extern unsigned int capnum1;
|
||||
extern unsigned int capnum2;
|
||||
extern unsigned int capnum3;
|
||||
extern unsigned int chNum;
|
||||
extern BREAK_PHASE_I chanell1;
|
||||
extern BREAK_PHASE_I chanell2;
|
||||
extern int cmd_3_or_16;
|
||||
extern int compress_size;
|
||||
extern ControlReg controlReg;
|
||||
extern COS_FI_STRUCT cos_fi;
|
||||
extern unsigned int count_error_sync;
|
||||
extern int count_modbus_table_changed;
|
||||
extern int count_run_pch;
|
||||
extern WORD crc_16_tab[256];
|
||||
extern char crypt[34];
|
||||
extern int cur_position_buf_modbus16_can;
|
||||
extern CYCLE cycle[32];
|
||||
extern int delta_capnum;
|
||||
extern int delta_error;
|
||||
extern volatile DOORS_STATUS doors;
|
||||
extern int enable_can;
|
||||
extern int enable_can_recive_after_units_box;
|
||||
extern _iq err_level_adc;
|
||||
extern _iq err_level_adc_on_go;
|
||||
extern unsigned int err_main;
|
||||
extern int err_modbus16;
|
||||
extern int err_modbus3;
|
||||
extern ERRORS errors;
|
||||
extern FLAG f;
|
||||
extern volatile int fail;
|
||||
extern FAULTS faults;
|
||||
extern FIFO fifo;
|
||||
extern ANALOG_VALUE filter;
|
||||
extern int flag_buf;
|
||||
extern int flag_enable_can_from_mpu;
|
||||
extern int flag_enable_can_from_terminal;
|
||||
extern int flag_on_off_pch;
|
||||
extern unsigned int flag_received_first_mess_from_MPU;
|
||||
extern unsigned int flag_reverse;
|
||||
extern unsigned int flag_send_answer_rs;
|
||||
extern int flag_test_tabe_filled;
|
||||
extern int flag_we_int_pwm_on;
|
||||
extern _iq freq1;
|
||||
extern float freqTerm;
|
||||
extern GLOBAL_TIME global_time;
|
||||
extern int hb_logs_data;
|
||||
extern int i;
|
||||
extern BREAK2_PHASE i1_out;
|
||||
extern BREAK2_PHASE i2_out;
|
||||
extern int init_log[3];
|
||||
extern _iq19 iq19_k_norm_ADC[20];
|
||||
extern _iq19 iq19_zero_ADC[20];
|
||||
extern _iq iq_alfa_coef;
|
||||
extern _iq iq_k_norm_ADC[20];
|
||||
extern IQ_LOGSPARAMS iq_logpar;
|
||||
extern _iq iq_max;
|
||||
extern _iq iq_norm_ADC[20];
|
||||
extern ISOLATION isolation1;
|
||||
extern ISOLATION isolation2;
|
||||
extern _iq k1;
|
||||
extern float kI_D;
|
||||
extern float kI_D_Inv31;
|
||||
extern float kI_Q;
|
||||
extern float kI_Q_Inv31;
|
||||
extern float kP_D;
|
||||
extern float kP_D_Inv31;
|
||||
extern float kP_Q;
|
||||
extern float kP_Q_Inv31;
|
||||
extern _iq koef_Base_stop_run;
|
||||
extern _iq koef_Iabc_filter;
|
||||
extern _iq koef_Im_filter;
|
||||
extern _iq koef_Im_filter_long;
|
||||
extern _iq koef_K_stop_run;
|
||||
extern _iq koef_Krecup;
|
||||
extern _iq koef_Min_recup;
|
||||
extern _iq koef_TemperBSU_long_filter;
|
||||
extern _iq koef_Ud_fast_filter;
|
||||
extern _iq koef_Ud_long_filter;
|
||||
extern _iq koef_Wlong;
|
||||
extern _iq koef_Wout_filter;
|
||||
extern _iq koef_Wout_filter_long;
|
||||
extern long koeff_Fs_filter;
|
||||
extern long koeff_Idq_filter;
|
||||
extern _iq koeff_Iq_filter;
|
||||
extern long koeff_Iq_filter_slow;
|
||||
extern long koeff_Ud_filter;
|
||||
extern long koeff_Uq_filter;
|
||||
extern volatile unsigned long length;
|
||||
extern _iq level_on_off_break[13][2];
|
||||
extern logcan_TypeDef log_can;
|
||||
extern LOG_CAN_SETUP log_can_setup;
|
||||
extern TYPE_LOG_PARAMS log_params;
|
||||
extern long logbuf_sync1[10];
|
||||
extern LOGSPARAMS logpar;
|
||||
extern int m_PWM;
|
||||
extern MAILBOXS_CAN_SETUP mailboxs_can_setup;
|
||||
extern int manufactorerAndProductID;
|
||||
extern MODBUS_REG_STRUCT * modbus_table_can_in;
|
||||
extern MODBUS_REG_STRUCT * modbus_table_can_out;
|
||||
extern MODBUS_REG_STRUCT modbus_table_in[450];
|
||||
extern MODBUS_REG_STRUCT modbus_table_out[450];
|
||||
extern MODBUS_REG_STRUCT * modbus_table_rs_in;
|
||||
extern MODBUS_REG_STRUCT * modbus_table_rs_out;
|
||||
extern MODBUS_REG_STRUCT modbus_table_test[450];
|
||||
extern MPU_CAN_SETUP mpu_can_setup;
|
||||
extern NEW_CYCLE_FIFO new_cycle_fifo;
|
||||
extern int no_write;
|
||||
extern int no_write_slow;
|
||||
extern int number_modbus_table_changed;
|
||||
extern OPTICAL_BUS_DATA optical_read_data;
|
||||
extern OPTICAL_BUS_DATA optical_write_data;
|
||||
extern MODBUS_REG_STRUCT options_controller[200];
|
||||
extern _iq pidCur_Ki;
|
||||
extern PIDREG3 pidD;
|
||||
extern PIDREG3 pidD2;
|
||||
extern PIDREG3 pidFvect;
|
||||
extern int pidFvectKi_test;
|
||||
extern int pidFvectKp_test;
|
||||
extern PIDREG3 pidPvect;
|
||||
extern PIDREG3 pidQ;
|
||||
extern PIDREG3 pidQ2;
|
||||
extern PIDREG_KOEFFICIENTS pidReg_koeffs;
|
||||
extern PIDREG3 pidTetta;
|
||||
extern POWER_RATIO power_ratio;
|
||||
extern int prev_flag_buf;
|
||||
extern unsigned int prev_status_received;
|
||||
extern T_project project;
|
||||
extern PWMGEND pwmd;
|
||||
extern T_controller_read r_c_sbus;
|
||||
extern T_controller_read r_controller;
|
||||
extern FIFO refo;
|
||||
extern TMS_TO_TERMINAL_STRUCT reply;
|
||||
extern TMS_TO_TERMINAL_TEST_ALL_STRUCT reply_test_all;
|
||||
extern long return_var;
|
||||
extern RMP_MY1 rmp_freq;
|
||||
extern RMP_MY1 rmp_wrot;
|
||||
extern T_rotation_sensor rotation_sensor;
|
||||
extern ROTOR_VALUE rotor;
|
||||
extern RS_DATA_STRUCT rs_a;
|
||||
extern RS_DATA_STRUCT rs_b;
|
||||
extern unsigned int sincronisationFault;
|
||||
extern char size_cmd15;
|
||||
extern char size_cmd16;
|
||||
extern int size_fast_done;
|
||||
extern int size_slow_done;
|
||||
extern int stop_log;
|
||||
extern int stop_log_slow;
|
||||
extern SVGENDQ svgen_dq_1;
|
||||
extern SVGENDQ svgen_dq_2;
|
||||
extern SVGEN_PWM24 svgen_pwm24_1;
|
||||
extern SVGEN_PWM24 svgen_pwm24_2;
|
||||
extern unsigned int temp;
|
||||
extern _iq temperature_limit_koeff;
|
||||
extern INVERTER_TEMPERATURES temperature_warning_BI1;
|
||||
extern INVERTER_TEMPERATURES temperature_warning_BI2;
|
||||
extern RECTIFIER_TEMPERATURES temperature_warning_BV1;
|
||||
extern RECTIFIER_TEMPERATURES temperature_warning_BV2;
|
||||
extern TERMINAL_CAN_SETUP terminal_can_setup;
|
||||
extern TETTA_CALC tetta_calc;
|
||||
extern int timCNT_alg;
|
||||
extern int timCNT_prev;
|
||||
extern unsigned int time;
|
||||
extern float time_alg;
|
||||
extern long time_pause_enable_can_from_mpu;
|
||||
extern long time_pause_enable_can_from_terminal;
|
||||
extern int time_pause_logs;
|
||||
extern int time_pause_titles;
|
||||
extern volatile int tryNumb;
|
||||
extern UNITES_CAN_SETUP unites_can_setup;
|
||||
extern long var_numb;
|
||||
extern VECTOR_CONTROL vect_control;
|
||||
extern WaterCooler water_cooler;
|
||||
extern _iq winding_displacement;
|
||||
extern Word word;
|
||||
extern WordReversed wordReversed;
|
||||
extern WordToReverse wordToReverse;
|
||||
extern X_PARALLEL_BUS x_parallel_bus_project;
|
||||
extern X_SERIAL_BUS x_serial_bus_project;
|
||||
extern unsigned int xeeprom_controll_fast;
|
||||
extern unsigned int xeeprom_controll_store;
|
||||
extern XPWM_TIME xpwm_time;
|
||||
extern _iq zadan_Id_min;
|
||||
extern int zero_ADC[20];
|
||||
|
||||
|
||||
// Îïðåäåëåíèå ìàññèâà ñ óêàçàòåëÿìè íà ïåðåìåííûå äëÿ îòëàäêè
|
||||
int DebugVar_Qnt = 8;
|
||||
#pragma DATA_SECTION(dbg_vars,".dbgvar_info")
|
||||
DebugVar_t dbg_vars[] = {\
|
||||
{(char *)&ADC0finishAddr , pt_int16 , t_iq_none , "ADC0finishAddr" }, \
|
||||
{(char *)&ADC0startAddr , pt_int16 , t_iq_none , "ADC0startAddr" }, \
|
||||
{(char *)&ADC1finishAddr , pt_int16 , t_iq_none , "ADC1finishAddr" }, \
|
||||
{(char *)&ADC1startAddr , pt_int16 , t_iq_none , "ADC1startAddr" }, \
|
||||
{(char *)&ADC2finishAddr , pt_int16 , t_iq_none , "ADC2finishAddr" }, \
|
||||
{(char *)&ADC2startAddr , pt_int16 , t_iq_none , "ADC2startAddr" }, \
|
||||
{(char *)&ADC_f , pt_int16 , t_iq_none , "ADC_f" }, \
|
||||
{(char *)&ADC_sf , pt_int16 , t_iq_none , "ADC_sf" }, \
|
||||
};
|
BIN
generateVars.exe
Normal file
BIN
generateVars.exe
Normal file
Binary file not shown.
374
generateVars.py
Normal file
374
generateVars.py
Normal file
@ -0,0 +1,374 @@
|
||||
# build command
|
||||
# pyinstaller --onefile --distpath . --workpath ./build --specpath ./build generateVars.py
|
||||
# start script
|
||||
# generateVars.exe F:\Work\Projects\TMS\TMS_new_bus\ Src/DebugTools/vars.xml Src/DebugTools
|
||||
|
||||
import sys
|
||||
import os
|
||||
import re
|
||||
import xml.etree.ElementTree as ET
|
||||
from pathlib import Path
|
||||
import argparse
|
||||
|
||||
|
||||
# === Словарь соответствия типов XML → DebugVarType_t ===
|
||||
type_map = dict([
|
||||
*[(k, 'pt_int8') for k in ('signed char', 'char')],
|
||||
*[(k, 'pt_int16') for k in ('int', 'int16', 'short')],
|
||||
*[(k, 'pt_int32') for k in ('long', 'int32', '_iqx')],
|
||||
*[(k, 'pt_int64') for k in ('long long', 'int64')],
|
||||
|
||||
*[(k, 'pt_uint8') for k in ('unsigned char',)],
|
||||
*[(k, 'pt_uint16') for k in ('unsigned int', 'unsigned short', 'Uint16')],
|
||||
*[(k, 'pt_uint32') for k in ('unsigned long', 'Uint32')],
|
||||
*[(k, 'pt_uint64') for k in ('unsigned long long', 'Uint64')],
|
||||
|
||||
('struct', 'pt_struct'),
|
||||
('union', 'pt_union'),
|
||||
|
||||
*[(k, 'pt_ptr_int8') for k in ('signed char*', 'char*')],
|
||||
*[(k, 'pt_ptr_int16') for k in ('int*', 'short*')],
|
||||
*[(k, 'pt_ptr_int32') for k in ('long*',)],
|
||||
*[(k, 'pt_ptr_uint8') for k in ('unsigned char*',)],
|
||||
*[(k, 'pt_ptr_uint16') for k in ('unsigned int*', 'unsigned short*')],
|
||||
*[(k, 'pt_ptr_uint32') for k in ('unsigned long*',)],
|
||||
('unsigned long long*', 'pt_int64'),
|
||||
|
||||
('struct*', 'pt_ptr_struct'),
|
||||
('union*', 'pt_ptr_union'),
|
||||
|
||||
|
||||
*[(k, 'pt_arr_int8') for k in ('signed char[]', 'char[]')],
|
||||
*[(k, 'pt_arr_int16') for k in ('int[]', 'short[]')],
|
||||
*[(k, 'pt_arr_int32') for k in ('long[]',)],
|
||||
*[(k, 'pt_arr_uint8') for k in ('unsigned char[]',)],
|
||||
*[(k, 'pt_arr_uint16') for k in ('unsigned int[]', 'unsigned short[]')],
|
||||
*[(k, 'pt_arr_uint32') for k in ('unsigned long[]',)],
|
||||
|
||||
*[(k, 'pt_float') for k in ('float', 'float32')],
|
||||
|
||||
('struct[]', 'pt_arr_struct'),
|
||||
('union[]', 'pt_arr_union'),
|
||||
])
|
||||
|
||||
def map_type_to_pt(typename, varname=None, typedef_map=None):
|
||||
typename_orig = typename.strip()
|
||||
|
||||
# Убираем const и volatile (чтобы не мешали проверке)
|
||||
for qualifier in ('const', 'volatile'):
|
||||
typename_orig = typename_orig.replace(qualifier, '')
|
||||
typename_orig = typename_orig.strip()
|
||||
|
||||
# Проверка наличия массива [] или указателя *
|
||||
is_array = bool(re.search(r'\[.*\]', typename_orig))
|
||||
is_ptr = '*' in typename_orig
|
||||
|
||||
# Убираем все [] и * для получения базового типа
|
||||
typename_base = re.sub(r'\[.*?\]', '', typename_orig).replace('*', '').strip()
|
||||
typedef_maybe = typename_base
|
||||
if typename_base.startswith('struct'):
|
||||
typename_base = 'struct'
|
||||
if typename_base.startswith('union'):
|
||||
typename_base = 'union'
|
||||
|
||||
# Добавляем [] или * к базовому типу для поиска
|
||||
if is_array:
|
||||
typename_base = typename_base + '[]'
|
||||
elif is_ptr:
|
||||
typename_base = typename_base + '*'
|
||||
else:
|
||||
typename_base = typename_base
|
||||
|
||||
if typename_base in type_map:
|
||||
return type_map[typename_base]
|
||||
|
||||
|
||||
if '_iq' in typename_base and '_iqx' in type_map:
|
||||
return type_map['_iqx']
|
||||
|
||||
# Если есть typedef_map — пробуем по нему
|
||||
if typedef_map and typedef_maybe in typedef_map:
|
||||
resolved = typedef_map[typedef_maybe].strip()
|
||||
|
||||
# Убираем const и volatile
|
||||
for qualifier in ('const', 'volatile'):
|
||||
resolved = resolved.replace(qualifier, '')
|
||||
resolved = resolved.strip()
|
||||
|
||||
# Получаем базовый тип из typedef-а
|
||||
base_t = re.sub(r'\[.*?\]', '', resolved).replace('*', '').strip()
|
||||
|
||||
if base_t.startswith('struct'):
|
||||
base_t = 'struct'
|
||||
if base_t.startswith('union'):
|
||||
base_t = 'union'
|
||||
|
||||
if is_array:
|
||||
base_t += '[]'
|
||||
elif is_ptr:
|
||||
base_t += '*'
|
||||
|
||||
# Пробуем по базовому имени
|
||||
if base_t in type_map:
|
||||
return type_map[base_t]
|
||||
if '_iq' in base_t and '_iqx' in type_map:
|
||||
return type_map['_iqx']
|
||||
|
||||
|
||||
return 'pt_unknown'
|
||||
|
||||
|
||||
|
||||
def get_iq_define(vtype):
|
||||
# Убираем все скобки массива, например: _iq[5] → _iq
|
||||
vtype = re.sub(r'\[.*?\]', '', vtype).strip()
|
||||
|
||||
if '_iq' in vtype:
|
||||
# Преобразуем _iqXX в t_iqXX
|
||||
return 't' + vtype[vtype.index('_iq'):]
|
||||
else:
|
||||
return 't_iq_none'
|
||||
|
||||
|
||||
|
||||
def read_vars_from_xml(proj_path, xml_rel_path):
|
||||
xml_full_path = os.path.join(proj_path, xml_rel_path)
|
||||
xml_full_path = os.path.normpath(xml_full_path)
|
||||
|
||||
tree = ET.parse(xml_full_path)
|
||||
root = tree.getroot()
|
||||
|
||||
vars_section = root.find("variables")
|
||||
includes_section = root.find("includes")
|
||||
externs_section = root.find("externs")
|
||||
|
||||
unique_vars = {}
|
||||
vars_need_extern = {}
|
||||
|
||||
# Читаем переменные из <variables>
|
||||
for var in vars_section.findall("var"):
|
||||
name = var.attrib["name"]
|
||||
var_info = {}
|
||||
|
||||
# Обрабатываем дочерние элементы (type, file, extern, static и т.п.)
|
||||
for child in var:
|
||||
text = child.text.strip() if child.text else ""
|
||||
# Конвертируем "true"/"false" в bool для extern и static
|
||||
if child.tag in ("extern", "static"):
|
||||
var_info[child.tag] = (text.lower() == "true")
|
||||
else:
|
||||
var_info[child.tag] = text
|
||||
if child.tag == "enable":
|
||||
var_info["enable"] = (text.lower() == "true")
|
||||
|
||||
# Обрабатываем путь к файлу (если есть)
|
||||
if "file" in var_info:
|
||||
file_rel = var_info["file"]
|
||||
file_full = os.path.normpath(os.path.join(proj_path, file_rel))
|
||||
var_info["file"] = file_full
|
||||
|
||||
unique_vars[name] = var_info
|
||||
|
||||
# Читаем include-файлы (относительные) и преобразуем в полные пути
|
||||
include_files = []
|
||||
for node in includes_section.findall("file"):
|
||||
rel_path = node.text
|
||||
full_path = os.path.normpath(os.path.join(proj_path, rel_path))
|
||||
include_files.append(full_path)
|
||||
|
||||
# Читаем extern переменные из <externs>
|
||||
for var in externs_section.findall("var"):
|
||||
name = var.attrib["name"]
|
||||
type_ = var.find("type").text
|
||||
file_rel = var.find("file").text
|
||||
file_full = os.path.normpath(os.path.join(proj_path, file_rel))
|
||||
vars_need_extern[name] = {
|
||||
"type": type_,
|
||||
"file": file_full
|
||||
}
|
||||
|
||||
return unique_vars, include_files, vars_need_extern
|
||||
|
||||
|
||||
|
||||
|
||||
def generate_vars_file(proj_path, xml_path, output_dir):
|
||||
output_dir = os.path.join(proj_path, output_dir)
|
||||
os.makedirs(output_dir, exist_ok=True)
|
||||
output_path = os.path.join(output_dir, 'debug_vars.c')
|
||||
|
||||
# Генерируем новые переменные
|
||||
vars, includes, externs = read_vars_from_xml(proj_path, xml_path)
|
||||
|
||||
# Сортируем новые переменные по алфавиту по имени
|
||||
sorted_new_debug_vars = dict(sorted(vars.items()))
|
||||
|
||||
|
||||
# Считываем существующие переменные
|
||||
existing_debug_vars = {}
|
||||
if os.path.isfile(output_path):
|
||||
with open(output_path, 'r', encoding='utf-8', errors='ignore') as f:
|
||||
old_lines = f.readlines()
|
||||
for line in old_lines:
|
||||
m = re.match(r'\s*{.*?,\s+.*?,\s+.*?,\s+"([_a-zA-Z][_a-zA-Z0-9]*)"\s*},', line)
|
||||
if m:
|
||||
varname = m.group(1)
|
||||
existing_debug_vars[varname] = line.strip()
|
||||
|
||||
new_debug_vars = {}
|
||||
for vname, info in vars.items():
|
||||
vtype = info["type"]
|
||||
is_extern = info["extern"]
|
||||
is_static = info.get("static", False)
|
||||
if is_static:
|
||||
continue # пропускаем static переменные
|
||||
|
||||
# Можно добавить проверку enable — если есть и False, пропускаем переменную
|
||||
if "enable" in info and info["enable"] is False:
|
||||
continue
|
||||
|
||||
path = info["file"]
|
||||
|
||||
if vname in existing_debug_vars:
|
||||
continue
|
||||
|
||||
iq_type = get_iq_define(vtype)
|
||||
pt_type = map_type_to_pt(vtype, vname)
|
||||
|
||||
# Дополнительные поля, например комментарий
|
||||
comment = info.get("comment", "")
|
||||
|
||||
if pt_type not in ('pt_struct', 'pt_union'):
|
||||
formated_name = f'"{vname}"'
|
||||
# Добавим комментарий после записи, если он есть
|
||||
comment_str = f' // {comment}' if comment else ''
|
||||
line = f'{{(char *)&{vname:<41} , {pt_type:<21} , {iq_type:<21} , {formated_name:<42}}}, \\{comment_str}'
|
||||
new_debug_vars[vname] = line
|
||||
|
||||
else:
|
||||
continue
|
||||
# Если тип переменной — структура, добавляем поля
|
||||
base_type = vtype.split()[0]
|
||||
# Удаляем символы указателей '*' и всю квадратную скобку с содержимым (например [10])
|
||||
base_type = re.sub(r'\*|\[[^\]]*\]', '', base_type).strip()
|
||||
if base_type in all_structs:
|
||||
add_struct_fields(new_debug_vars, vname, base_type, all_structs, existing_debug_vars)
|
||||
|
||||
|
||||
# Объединяем все переменные
|
||||
all_debug_lines = [str(v) for v in existing_debug_vars.values()] + [str(v) for v in new_debug_vars.values()]
|
||||
|
||||
out_lines = []
|
||||
out_lines.append("// Этот файл сгенерирован автоматически")
|
||||
out_lines.append(f'#include "debug_tools.h"')
|
||||
|
||||
out_lines.append('\n\n// Инклюды для доступа к переменным')
|
||||
for incf in includes:
|
||||
filename = os.path.basename(incf)
|
||||
out_lines.append(f'#include "{filename}"')
|
||||
|
||||
|
||||
out_lines.append('\n\n// Экстерны для доступа к переменным')
|
||||
for vname, info in externs.items():
|
||||
vtype = info["type"].strip()
|
||||
|
||||
is_static = info.get("static", False) # <-- добавлено
|
||||
if is_static:
|
||||
continue # пропускаем static переменные
|
||||
|
||||
# Попытка выделить размер массива из типа, например int[20]
|
||||
array_match = re.match(r'^(.*?)(\s*\[.*\])$', vtype)
|
||||
if array_match:
|
||||
base_type = array_match.group(1).strip()
|
||||
array_size = array_match.group(2).strip()
|
||||
out_lines.append(f'extern {base_type} {vname}{array_size};')
|
||||
else:
|
||||
# Если не массив — обычный extern
|
||||
out_lines.append(f'extern {vtype} {vname};')
|
||||
|
||||
out_lines.append(f'\n\n// Определение массива с указателями на переменные для отладки')
|
||||
out_lines.append(f'int DebugVar_Qnt = {len(all_debug_lines)};')
|
||||
out_lines.append('#pragma DATA_SECTION(dbg_vars,".dbgvar_info")')
|
||||
out_lines.append('DebugVar_t dbg_vars[] = {\\')
|
||||
out_lines.extend(all_debug_lines)
|
||||
out_lines.append('};')
|
||||
out_lines.append('')
|
||||
# Выберем кодировку для записи файла
|
||||
# Если встречается несколько, возьмем первую из set
|
||||
enc_to_write = 'cp1251'
|
||||
|
||||
#print("== GLOBAL VARS FOUND ==")
|
||||
#for vname, (vtype, path) in vars_in_c.items():
|
||||
#print(f"{vtype:<20} {vname:<40} // {path}")
|
||||
|
||||
|
||||
with open(output_path, 'w', encoding=enc_to_write) as f:
|
||||
f.write('\n'.join(out_lines))
|
||||
|
||||
print(f'Файл debug_vars.c сгенерирован в кодировке, переменных: {len(all_debug_lines)}')
|
||||
|
||||
|
||||
#generate_vars_file("E:/.WORK/TMS/TMS_new_bus/", "Src/DebugTools/vars.xml", "E:/.WORK/TMS/TMS_new_bus/Src/DebugTools/")
|
||||
|
||||
|
||||
def main():
|
||||
parser = argparse.ArgumentParser(
|
||||
description="Generate debug_vars.c from project XML and output directory.",
|
||||
epilog="""\
|
||||
Usage example:
|
||||
%(prog)s /absolute/path/to/project /absolute/path/to/project/Src/DebugTools/vars.xml /absolute/path/to/project/Src/DebugTools/
|
||||
""",
|
||||
formatter_class=argparse.RawDescriptionHelpFormatter,
|
||||
add_help=False
|
||||
)
|
||||
parser.add_argument("proj_path", help="Absolute path to the project root directory")
|
||||
parser.add_argument("xml_path", help="Absolute path to the XML file (must be inside project)")
|
||||
parser.add_argument("output_dir", help="Absolute path to output directory (must be inside project)")
|
||||
parser.add_argument("-h", "--help", action="store_true", help="Show this help message and exit")
|
||||
|
||||
# Show help if requested
|
||||
if "-h" in sys.argv or "--help" in sys.argv:
|
||||
parser.print_help()
|
||||
sys.exit(0)
|
||||
|
||||
# Check minimum args count
|
||||
if len(sys.argv) < 4:
|
||||
print("Error: insufficient arguments.\n")
|
||||
print("Usage example:")
|
||||
print(f" {os.path.basename(sys.argv[0])} /absolute/path/to/project /absolute/path/to/project/Src/DebugTools/vars.xml /absolute/path/to/project/Src/DebugTools/\n")
|
||||
sys.exit(1)
|
||||
|
||||
args = parser.parse_args()
|
||||
|
||||
# Normalize absolute paths
|
||||
proj_path = os.path.abspath(args.proj_path)
|
||||
xml_path_abs = os.path.abspath(args.xml_path)
|
||||
output_dir_abs = os.path.abspath(args.output_dir)
|
||||
|
||||
# Check proj_path is directory
|
||||
if not os.path.isdir(proj_path):
|
||||
print(f"Error: Project path '{proj_path}' is not a directory or does not exist.")
|
||||
sys.exit(1)
|
||||
# Check xml_path inside proj_path
|
||||
if not xml_path_abs.startswith(proj_path + os.sep):
|
||||
print(f"Error: XML path '{xml_path_abs}' is not inside the project path '{proj_path}'.")
|
||||
sys.exit(1)
|
||||
# Check output_dir inside proj_path
|
||||
if not output_dir_abs.startswith(proj_path + os.sep):
|
||||
print(f"Error: Output directory '{output_dir_abs}' is not inside the project path '{proj_path}'.")
|
||||
sys.exit(1)
|
||||
|
||||
# Convert xml_path and output_dir to relative paths *relative to proj_path*
|
||||
xml_path_rel = os.path.relpath(xml_path_abs, proj_path)
|
||||
output_dir_rel = os.path.relpath(output_dir_abs, proj_path)
|
||||
|
||||
if not os.path.isdir(proj_path):
|
||||
print(f"Error: Project path '{proj_path}' не является директорией или не существует.")
|
||||
sys.exit(1)
|
||||
|
||||
generate_vars_file(proj_path, xml_path_rel, output_dir_rel)
|
||||
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
143
parseMakefile.py
Normal file
143
parseMakefile.py
Normal file
@ -0,0 +1,143 @@
|
||||
import os
|
||||
import re
|
||||
|
||||
|
||||
def strip_single_line_comments(code):
|
||||
# Удалим // ... до конца строки
|
||||
return re.sub(r'//.*?$', '', code, flags=re.MULTILINE)
|
||||
|
||||
def read_file_try_encodings(filepath):
|
||||
for enc in ['utf-8', 'cp1251']:
|
||||
try:
|
||||
with open(filepath, 'r', encoding=enc) as f:
|
||||
content = f.read()
|
||||
content = strip_single_line_comments(content) # <=== ВАЖНО
|
||||
return content, enc
|
||||
except UnicodeDecodeError:
|
||||
continue
|
||||
raise UnicodeDecodeError(f"Не удалось прочитать файл {filepath} с кодировками utf-8 и cp1251")
|
||||
|
||||
def find_all_includes_recursive(c_files, include_dirs, processed_files=None):
|
||||
"""
|
||||
Рекурсивно ищет все include-файлы начиная с заданных c_files.
|
||||
Возвращает множество ПОЛНЫХ ПУТЕЙ к найденным include-файлам.
|
||||
|
||||
include_dirs — список директорий, в которых ищем include-файлы.
|
||||
processed_files — множество уже обработанных файлов (для избежания циклов).
|
||||
"""
|
||||
if processed_files is None:
|
||||
processed_files = set()
|
||||
|
||||
include_files = set()
|
||||
include_pattern = re.compile(r'#include\s+"([^"]+)"')
|
||||
|
||||
for cfile in c_files:
|
||||
norm_path = os.path.normpath(cfile)
|
||||
if norm_path in processed_files:
|
||||
continue
|
||||
processed_files.add(norm_path)
|
||||
|
||||
content, _ = read_file_try_encodings(cfile)
|
||||
includes = include_pattern.findall(content)
|
||||
for inc in includes:
|
||||
# Ищем полный путь к include-файлу в include_dirs
|
||||
inc_full_path = None
|
||||
for dir_ in include_dirs:
|
||||
candidate = os.path.normpath(os.path.join(dir_, inc))
|
||||
if os.path.isfile(candidate):
|
||||
inc_full_path = os.path.abspath(candidate)
|
||||
break
|
||||
|
||||
if inc_full_path:
|
||||
include_files.add(inc_full_path)
|
||||
|
||||
# Рекурсивный обход вложенных includes
|
||||
if inc_full_path not in processed_files:
|
||||
nested_includes = find_all_includes_recursive(
|
||||
[inc_full_path], include_dirs, processed_files
|
||||
)
|
||||
include_files.update(nested_includes)
|
||||
|
||||
return include_files
|
||||
|
||||
|
||||
def parse_makefile(makefile_path):
|
||||
makefile_dir = os.path.dirname(makefile_path)
|
||||
project_root = os.path.dirname(makefile_dir) # поднялись из Debug
|
||||
|
||||
with open(makefile_path, 'r', encoding='utf-8') as f:
|
||||
lines = f.readlines()
|
||||
|
||||
objs_lines = []
|
||||
collecting = False
|
||||
|
||||
for line in lines:
|
||||
stripped = line.strip()
|
||||
if stripped.startswith("ORDERED_OBJS") and "+=" in stripped:
|
||||
parts = stripped.split("\\")
|
||||
first_part = parts[0]
|
||||
idx = first_part.find("+=")
|
||||
tail = first_part[idx+2:].strip()
|
||||
if tail:
|
||||
objs_lines.append(tail)
|
||||
collecting = True
|
||||
if len(parts) > 1:
|
||||
for p in parts[1:]:
|
||||
p = p.strip()
|
||||
if p:
|
||||
objs_lines.append(p)
|
||||
continue
|
||||
|
||||
if collecting:
|
||||
if stripped.endswith("\\"):
|
||||
objs_lines.append(stripped[:-1].strip())
|
||||
else:
|
||||
objs_lines.append(stripped)
|
||||
collecting = False
|
||||
|
||||
objs_str = ' '.join(objs_lines)
|
||||
|
||||
objs_str = re.sub(r"\$\([^)]+\)", "", objs_str)
|
||||
|
||||
objs = []
|
||||
for part in objs_str.split():
|
||||
part = part.strip()
|
||||
if part.startswith('"') and part.endswith('"'):
|
||||
part = part[1:-1]
|
||||
if part:
|
||||
objs.append(part)
|
||||
|
||||
c_files = []
|
||||
include_dirs = set()
|
||||
|
||||
for obj_path in objs:
|
||||
if "DebugTools" in obj_path:
|
||||
continue
|
||||
if "v120" in obj_path:
|
||||
continue
|
||||
|
||||
if obj_path.startswith("Debug\\") or obj_path.startswith("Debug/"):
|
||||
rel_path = obj_path.replace("Debug\\", "Src\\").replace("Debug/", "Src/")
|
||||
else:
|
||||
rel_path = obj_path
|
||||
|
||||
abs_path = os.path.normpath(os.path.join(project_root, rel_path))
|
||||
|
||||
root, ext = os.path.splitext(abs_path)
|
||||
if ext.lower() == ".obj":
|
||||
c_path = root + ".c"
|
||||
else:
|
||||
c_path = abs_path
|
||||
|
||||
# Сохраняем только .c файлы
|
||||
if c_path.lower().endswith(".c"):
|
||||
c_files.append(c_path)
|
||||
dir_path = os.path.dirname(c_path)
|
||||
if dir_path and "DebugTools" not in dir_path:
|
||||
include_dirs.add(dir_path)
|
||||
|
||||
|
||||
h_files = find_all_includes_recursive(c_files, include_dirs)
|
||||
|
||||
|
||||
return sorted(c_files), sorted(h_files), sorted(include_dirs)
|
BIN
scanVars.exe
Normal file
BIN
scanVars.exe
Normal file
Binary file not shown.
820
scanVars.py
Normal file
820
scanVars.py
Normal file
@ -0,0 +1,820 @@
|
||||
# build command
|
||||
# pyinstaller --onefile scanVars.py --add-binary "F:\Work\Projects\TMS\TMS_new_bus\Src\DebugTools/build/libclang.dll;." --distpath . --workpath ./build --specpath ./build
|
||||
# start script
|
||||
# scanVars.exe F:\Work\Projects\TMS\TMS_new_bus\ F:\Work\Projects\TMS\TMS_new_bus\Debug\makefile
|
||||
|
||||
import os
|
||||
import sys
|
||||
import re
|
||||
import clang.cindex
|
||||
from clang import cindex
|
||||
import xml.etree.ElementTree as ET
|
||||
from xml.dom import minidom
|
||||
from parseMakefile import parse_makefile
|
||||
from collections import deque
|
||||
import argparse
|
||||
BITFIELD_WIDTHS = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32}
|
||||
|
||||
|
||||
# Укажи полный путь к libclang.dll — поменяй на свой путь или оставь относительный
|
||||
dll_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), "build/libclang.dll")
|
||||
|
||||
if hasattr(sys, '_MEIPASS'):
|
||||
dll_path = os.path.join(sys._MEIPASS, "libclang.dll")
|
||||
cindex.Config.set_library_file(dll_path)
|
||||
else:
|
||||
cindex.Config.set_library_file(r"..\libclang.dll") # путь для запуска без упаковки
|
||||
|
||||
index = cindex.Index.create()
|
||||
PRINT_LEVEL = 2
|
||||
|
||||
PRINT_ERROR = 1 # 0 = ничего, 1 = ошибки, 2 = статус, 3 = отладка
|
||||
PRINT_STATUS = 2 # 0 = ничего, 1 = ошибки, 2 = статус, 3 = отладка
|
||||
PRINT_DEBUG = 3 # 0 = ничего, 1 = ошибки, 2 = статус, 3 = отладка
|
||||
|
||||
def optional_printf(level, msg):
|
||||
"""
|
||||
Выводит сообщение, если заданный уровень level меньше или равен текущему уровню DEBUG_LEVEL.
|
||||
:param level: int — уровень важности сообщения # 0 = ничего, 1 = статус, 2 = подробно, 3 = отладка
|
||||
:param msg: str — текст сообщения
|
||||
"""
|
||||
if level <= PRINT_LEVEL:
|
||||
print(msg)
|
||||
|
||||
def get_canonical_typedef_file(var_type, include_dirs):
|
||||
"""
|
||||
Рекурсивно спускаемся к базовому типу, чтобы найти typedef-декларацию,
|
||||
возвращаем файл заголовка, если он есть и в include_dirs.
|
||||
"""
|
||||
# unwrap array, pointer, typedef, etc, пока не дойдём до базового типа
|
||||
t = var_type
|
||||
while True:
|
||||
# если массив, достаём тип элементов
|
||||
if t.kind == clang.cindex.TypeKind.CONSTANTARRAY or t.kind == clang.cindex.TypeKind.INCOMPLETEARRAY:
|
||||
t = t.element_type
|
||||
continue
|
||||
# если указатель — достаём тип, на который он указывает
|
||||
if t.kind == clang.cindex.TypeKind.POINTER:
|
||||
t = t.get_pointee()
|
||||
continue
|
||||
# если typedef — unwrap до underlying type
|
||||
if t.get_declaration().kind == clang.cindex.CursorKind.TYPEDEF_DECL:
|
||||
typedef_decl = t.get_declaration()
|
||||
if typedef_decl and typedef_decl.location and typedef_decl.location.file:
|
||||
typedef_header = str(typedef_decl.location.file)
|
||||
# Проверяем, внутри ли include_dirs
|
||||
path_abs = os.path.abspath(typedef_header)
|
||||
for inc in include_dirs:
|
||||
try:
|
||||
inc_abs = os.path.abspath(inc)
|
||||
if os.path.commonpath([path_abs, inc_abs]) == inc_abs and typedef_header.endswith('.h'):
|
||||
return os.path.normpath(typedef_header)
|
||||
except ValueError:
|
||||
continue
|
||||
# Если не нашли, пытаемся получить underlying type дальше
|
||||
t = t.get_canonical() # underlying type без typedef-ов
|
||||
continue
|
||||
# Если дошли до типа без typedef-а — возвращаем None
|
||||
break
|
||||
return None
|
||||
|
||||
def analyze_variables_across_files(c_files, h_files, include_dirs):
|
||||
optional_printf(PRINT_STATUS, "Starting analysis of variables across files...")
|
||||
index = clang.cindex.Index.create()
|
||||
args = [f"-I{inc}" for inc in include_dirs]
|
||||
|
||||
unique_vars = {} # имя переменной → словарь с инфой
|
||||
h_files_needed = set()
|
||||
vars_need_extern = {} # имя переменной → словарь без поля 'extern'
|
||||
|
||||
def is_inside_includes(path, include_dirs):
|
||||
path_abs = os.path.abspath(path)
|
||||
for inc in include_dirs:
|
||||
try:
|
||||
inc_abs = os.path.abspath(inc)
|
||||
if os.path.commonpath([path_abs, inc_abs]) == inc_abs:
|
||||
return True
|
||||
except ValueError:
|
||||
continue
|
||||
return False
|
||||
|
||||
|
||||
def parse_file(file_path):
|
||||
optional_printf(PRINT_DEBUG, f"\tParsing file: {file_path}")
|
||||
try:
|
||||
tu = index.parse(file_path, args=args)
|
||||
except Exception as e:
|
||||
optional_printf(PRINT_ERROR, f"\t\tFailed to parse {file_path}: {e}")
|
||||
return []
|
||||
|
||||
vars_in_file = []
|
||||
|
||||
def visit(node):
|
||||
def is_system_var(var_name: str) -> bool:
|
||||
# Проверяем, начинается ли имя с "_" и содержит заглавные буквы или служебные символы
|
||||
return bool(re.match(r"^_[_A-Z]", var_name))
|
||||
|
||||
if node.kind == clang.cindex.CursorKind.VAR_DECL:
|
||||
if node.semantic_parent.kind == clang.cindex.CursorKind.TRANSLATION_UNIT:
|
||||
is_extern = (node.storage_class == clang.cindex.StorageClass.EXTERN)
|
||||
is_static = (node.storage_class == clang.cindex.StorageClass.STATIC)
|
||||
var_type = node.type.spelling
|
||||
|
||||
# Проверка, есть ли определение
|
||||
definition = node.get_definition()
|
||||
if is_extern and definition is None:
|
||||
# Переменная extern без определения — игнорируем
|
||||
return
|
||||
|
||||
if is_system_var(node.spelling):
|
||||
return # игнорируем только явно известные служебные переменные
|
||||
if node.spelling == 'HUGE': # еще одна служеюная, которую хз как выделять
|
||||
return
|
||||
|
||||
# Проверяем, является ли тип указателем на функцию
|
||||
# Признак: в типе есть '(' и ')' и '*', например: "void (*)(int)"
|
||||
if "(" in var_type and "*" in var_type and ")" in var_type:
|
||||
# Пропускаем указатели на функции
|
||||
return
|
||||
|
||||
vars_in_file.append({
|
||||
"name": node.spelling,
|
||||
"type": var_type,
|
||||
"extern": is_extern,
|
||||
"static": is_static,
|
||||
"file": file_path
|
||||
})
|
||||
|
||||
# Если переменная extern и находится в .h — добавляем в includes
|
||||
if is_extern and file_path.endswith('.h') and is_inside_includes(file_path):
|
||||
h_files_needed.add(os.path.normpath(file_path))
|
||||
|
||||
# Добавляем файл с typedef, если есть
|
||||
typedef_header = get_canonical_typedef_file(node.type, include_dirs)
|
||||
if typedef_header:
|
||||
h_files_needed.add(typedef_header)
|
||||
|
||||
|
||||
|
||||
for child in node.get_children():
|
||||
visit(child)
|
||||
|
||||
visit(tu.cursor)
|
||||
return vars_in_file
|
||||
|
||||
optional_printf(PRINT_STATUS, "Parsing header files (.h)...")
|
||||
for h in h_files:
|
||||
vars_in_h = parse_file(h)
|
||||
for v in vars_in_h:
|
||||
name = v["name"]
|
||||
if name not in unique_vars:
|
||||
unique_vars[name] = {
|
||||
"type": v["type"],
|
||||
"extern": v["extern"],
|
||||
"static": v["static"],
|
||||
"file": v["file"]
|
||||
}
|
||||
|
||||
optional_printf(PRINT_STATUS, "Parsing source files (.c)...")
|
||||
for c in c_files:
|
||||
vars_in_c = parse_file(c)
|
||||
for v in vars_in_c:
|
||||
name = v["name"]
|
||||
if name in unique_vars:
|
||||
unique_vars[name].update({
|
||||
"type": v["type"],
|
||||
"extern": v["extern"],
|
||||
"static": v["static"],
|
||||
"file": v["file"]
|
||||
})
|
||||
else:
|
||||
unique_vars[name] = {
|
||||
"type": v["type"],
|
||||
"extern": v["extern"],
|
||||
"static": v["static"],
|
||||
"file": v["file"]
|
||||
}
|
||||
|
||||
optional_printf(PRINT_STATUS, "Checking which variables need explicit extern declaration...")
|
||||
for name, info in unique_vars.items():
|
||||
if not info["extern"] and not info["static"] and info["file"].endswith('.c'):
|
||||
extern_declared = False
|
||||
for h in h_files_needed:
|
||||
if h in unique_vars and unique_vars[h]["name"] == name and unique_vars[h]["extern"]:
|
||||
extern_declared = True
|
||||
break
|
||||
if not extern_declared:
|
||||
vars_need_extern[name] = {
|
||||
"type": info["type"],
|
||||
"file": info["file"]
|
||||
}
|
||||
|
||||
optional_printf(PRINT_STATUS, "Analysis complete.")
|
||||
optional_printf(PRINT_STATUS, f"\tTotal unique variables found: {len(unique_vars)}")
|
||||
optional_printf(PRINT_STATUS, f"\tHeader files with extern variables and declarations: {len(h_files_needed)}")
|
||||
optional_printf(PRINT_STATUS, f"\tVariables that need explicit extern declaration: {len(vars_need_extern)}\n")
|
||||
|
||||
return unique_vars, list(h_files_needed), vars_need_extern
|
||||
|
||||
|
||||
def resolve_typedef(typedefs, typename):
|
||||
"""
|
||||
Рекурсивно раскрывает typedef, пока не дойдёт до "примитивного" типа.
|
||||
Если typename нет в typedefs — возвращаем typename как есть.
|
||||
"""
|
||||
seen = set()
|
||||
current = typename
|
||||
while current in typedefs and current not in seen:
|
||||
seen.add(current)
|
||||
current = typedefs[current]
|
||||
return current
|
||||
|
||||
def analyze_typedefs_and_struct(typedefs, structs):
|
||||
optional_printf(PRINT_STATUS, "Resolving typedefs and expanding struct field types...")
|
||||
|
||||
def simplify_type_name(typename):
|
||||
# Убираем ключевые слова типа "struct ", "union ", "enum " для поиска в typedefs и structs
|
||||
if isinstance(typename, str):
|
||||
for prefix in ("struct ", "union ", "enum "):
|
||||
if typename.startswith(prefix):
|
||||
return typename[len(prefix):]
|
||||
return typename
|
||||
|
||||
def strip_ptr_and_array(typename):
|
||||
"""
|
||||
Убирает указатели и массивные скобки из типа,
|
||||
чтобы найти базовый тип (например, для typedef или struct).
|
||||
"""
|
||||
if not isinstance(typename, str):
|
||||
return typename
|
||||
|
||||
# Убираем [] и всё, что внутри скобок
|
||||
typename = re.sub(r'\[.*?\]', '', typename)
|
||||
|
||||
# Убираем звёздочки и пробелы рядом
|
||||
typename = typename.replace('*', '').strip()
|
||||
|
||||
return typename
|
||||
|
||||
|
||||
def resolve_typedef_rec(typename, depth=0):
|
||||
if depth > 50:
|
||||
optional_printf(PRINT_ERROR, f"Possible typedef recursion limit reached on '{typename}'")
|
||||
return typename
|
||||
|
||||
if not isinstance(typename, str):
|
||||
return typename
|
||||
|
||||
simple_name = typename
|
||||
|
||||
if simple_name in typedefs:
|
||||
underlying = typedefs[simple_name]
|
||||
|
||||
# Если раскрытие не меняет результат — считаем раскрытие завершённым
|
||||
if normalize_type_name(underlying) == normalize_type_name(typename):
|
||||
return underlying
|
||||
|
||||
return resolve_typedef_rec(underlying, depth + 1)
|
||||
else:
|
||||
return typename
|
||||
|
||||
|
||||
def resolve_struct_fields(fields, depth=0):
|
||||
if depth > 50:
|
||||
optional_printf(PRINT_ERROR, f"Possible struct recursion limit reached")
|
||||
return fields
|
||||
|
||||
if not isinstance(fields, dict):
|
||||
return fields
|
||||
|
||||
resolved_fields = {}
|
||||
|
||||
for fname, ftype in fields.items():
|
||||
base_type = strip_ptr_and_array(ftype)
|
||||
original_type = ftype # Сохраняем оригинальный вид типа
|
||||
|
||||
if base_type in structs:
|
||||
# Рекурсивно раскрываем вложенную структуру
|
||||
nested = resolve_struct_fields(structs[base_type], depth + 1)
|
||||
nested["__type__"] = original_type
|
||||
resolved_fields[fname] = nested
|
||||
else:
|
||||
resolved_fields[fname] = original_type # сохраняем оригинал
|
||||
|
||||
return resolved_fields
|
||||
|
||||
|
||||
""" # Сначала раскрываем typedef в именах структур и в полях
|
||||
substituted_structs = {}
|
||||
for sname, fields in structs.items():
|
||||
resolved_sname = resolve_typedef_rec(sname) # раскрываем имя структуры
|
||||
substituted_fields = {}
|
||||
for fname, ftype in fields.items():
|
||||
resolved_type = resolve_typedef_rec(ftype) # раскрываем тип поля
|
||||
substituted_fields[fname] = resolved_type
|
||||
substituted_structs[resolved_sname] = substituted_fields """
|
||||
|
||||
# Теперь раскрываем вложенные структуры
|
||||
resolved_structs = {}
|
||||
for sname, fields in structs.items():
|
||||
if "(unnamed" in sname:
|
||||
optional_printf(4, f" Skipping anonymous struct/union: {sname}")
|
||||
continue
|
||||
if sname == 'T_project':
|
||||
a = 1
|
||||
resolved_fields = resolve_struct_fields(fields)
|
||||
resolved_structs[sname] = resolved_fields
|
||||
optional_printf(PRINT_DEBUG, f"\tStruct {sname} resolved")
|
||||
|
||||
# Раскрываем typedef'ы в отдельном шаге
|
||||
resolved_typedefs = {}
|
||||
for tname in typedefs:
|
||||
resolved = resolve_typedef_rec(tname)
|
||||
resolved_typedefs[tname] = resolved
|
||||
optional_printf(4, f"\tTypedef {tname} resolved")
|
||||
|
||||
return resolved_typedefs, resolved_structs
|
||||
|
||||
def normalize_type_name(type_name: str) -> str:
|
||||
# Приводим тип к виду "union (unnamed union at ...)" или "struct (unnamed struct at ...)"
|
||||
m = re.match(r'^(union|struct) \((unnamed)( union| struct)? at .+\)$', type_name)
|
||||
if m:
|
||||
kind = m.group(1)
|
||||
unnamed = m.group(2)
|
||||
extra = m.group(3)
|
||||
if extra is None:
|
||||
type_name = f"{kind} ({unnamed} {kind} at {type_name.split(' at ')[1]}"
|
||||
return type_name
|
||||
|
||||
def contains_anywhere_in_node(node, target: str) -> bool:
|
||||
"""
|
||||
Рекурсивно ищет target во всех строковых значениях текущего узла и его потомков.
|
||||
"""
|
||||
for attr in dir(node):
|
||||
try:
|
||||
val = getattr(node, attr)
|
||||
if isinstance(val, str) and target in val:
|
||||
return True
|
||||
elif hasattr(val, 'spelling') and target in val.spelling:
|
||||
return True
|
||||
except Exception:
|
||||
continue
|
||||
|
||||
for child in node.get_children():
|
||||
if contains_anywhere_in_node(child, target):
|
||||
return True
|
||||
|
||||
return False
|
||||
|
||||
|
||||
def analyze_typedefs_and_structs_across_files(c_files, include_dirs):
|
||||
optional_printf(PRINT_STATUS, "Starting analysis of typedefs and structs across files...")
|
||||
index = clang.cindex.Index.create()
|
||||
args = [f"-I{inc}" for inc in include_dirs]
|
||||
|
||||
unique_typedefs_raw = {}
|
||||
unique_structs_raw = {}
|
||||
|
||||
def parse_file(file_path):
|
||||
optional_printf(PRINT_DEBUG, f"\tParsing file: {file_path}")
|
||||
try:
|
||||
tu = index.parse(file_path, args=args)
|
||||
except Exception as e:
|
||||
optional_printf(PRINT_ERROR, f"\t\tFailed to parse {file_path}: {e}")
|
||||
return {}, {}
|
||||
|
||||
typedefs = {}
|
||||
structs = {}
|
||||
|
||||
def visit(node):
|
||||
if node.kind == clang.cindex.CursorKind.TYPEDEF_DECL:
|
||||
name = node.spelling
|
||||
underlying = node.underlying_typedef_type.spelling
|
||||
typedefs[name] = underlying
|
||||
|
||||
elif node.kind in (clang.cindex.CursorKind.STRUCT_DECL, clang.cindex.CursorKind.UNION_DECL):
|
||||
prefix = "struct " if node.kind == clang.cindex.CursorKind.STRUCT_DECL else "union "
|
||||
|
||||
raw_name = node.spelling
|
||||
normalized_name = normalize_type_name(raw_name)
|
||||
|
||||
# struct_name всегда с префиксом
|
||||
if node.spelling and "unnamed" not in normalized_name:
|
||||
struct_name = f"{prefix}{normalized_name}"
|
||||
else:
|
||||
struct_name = normalized_name
|
||||
|
||||
# Поиск typedef, соответствующего этой структуре
|
||||
typedef_name_for_struct = None
|
||||
for tname, underlying in typedefs.items():
|
||||
if normalize_type_name(underlying) == struct_name:
|
||||
typedef_name_for_struct = tname
|
||||
break
|
||||
|
||||
# Если нашли typedef → заменим struct_name на него
|
||||
final_name = typedef_name_for_struct if typedef_name_for_struct else struct_name
|
||||
|
||||
fields = {}
|
||||
for c in node.get_children():
|
||||
if c.kind == clang.cindex.CursorKind.FIELD_DECL:
|
||||
ftype = c.type.spelling
|
||||
bit_width = c.get_bitfield_width()
|
||||
if bit_width > 0:
|
||||
ftype += f" (bitfield:{bit_width})"
|
||||
fields[c.spelling] = ftype
|
||||
|
||||
if fields:
|
||||
structs[final_name] = fields
|
||||
|
||||
# Если это был struct с typedef, удалим старое имя (например, struct TS_project)
|
||||
if typedef_name_for_struct and struct_name in structs:
|
||||
del structs[struct_name]
|
||||
|
||||
for child in node.get_children():
|
||||
visit(child)
|
||||
|
||||
|
||||
|
||||
|
||||
visit(tu.cursor)
|
||||
return typedefs, structs
|
||||
|
||||
for c_file in c_files:
|
||||
typedefs_in_file, structs_in_file = parse_file(c_file)
|
||||
for name, underlying in typedefs_in_file.items():
|
||||
if name not in unique_typedefs_raw:
|
||||
unique_typedefs_raw[name] = underlying
|
||||
for sname, fields in structs_in_file.items():
|
||||
if sname not in unique_structs_raw:
|
||||
unique_structs_raw[sname] = fields
|
||||
|
||||
# Теперь раскроем typedef и структуры, учитывая вложения
|
||||
resolved_typedefs, resolved_structs = analyze_typedefs_and_struct(unique_typedefs_raw, unique_structs_raw)
|
||||
|
||||
optional_printf(PRINT_STATUS, "Analysis complete.")
|
||||
optional_printf(PRINT_STATUS, f"\tTotal unique typedefs found: {len(resolved_typedefs)}")
|
||||
optional_printf(PRINT_STATUS, f"\tTotal unique structs found: {len(resolved_structs)}\n")
|
||||
|
||||
return resolved_typedefs, resolved_structs
|
||||
|
||||
|
||||
def read_vars_from_xml(xml_path):
|
||||
xml_full_path = os.path.normpath(xml_path)
|
||||
vars_data = {}
|
||||
|
||||
if not os.path.exists(xml_full_path):
|
||||
return vars_data # пусто, если файла нет
|
||||
|
||||
tree = ET.parse(xml_full_path)
|
||||
root = tree.getroot()
|
||||
|
||||
vars_elem = root.find('variables')
|
||||
if vars_elem is None:
|
||||
return vars_data
|
||||
|
||||
for var_elem in vars_elem.findall('var'):
|
||||
name = var_elem.get('name')
|
||||
if not name:
|
||||
continue
|
||||
|
||||
enable_text = var_elem.findtext('enable', 'false').lower()
|
||||
enable = (enable_text == 'true')
|
||||
|
||||
shortname = var_elem.findtext('shortname', name)
|
||||
pt_type = var_elem.findtext('pt_type', '')
|
||||
iq_type = var_elem.findtext('iq_type', '')
|
||||
return_type = var_elem.findtext('return_type', 'int')
|
||||
|
||||
include_text = var_elem.findtext('include', 'false').lower()
|
||||
include = (include_text == 'true')
|
||||
|
||||
extern_text = var_elem.findtext('extern', 'false').lower()
|
||||
extern = (extern_text == 'true')
|
||||
|
||||
vars_data[name] = {
|
||||
'enable': enable,
|
||||
'shortname': shortname,
|
||||
'pt_type': pt_type,
|
||||
'iq_type': iq_type,
|
||||
'return_type': return_type,
|
||||
'include': include,
|
||||
'extern': extern,
|
||||
}
|
||||
|
||||
return vars_data
|
||||
|
||||
|
||||
def generate_xml_output(proj_path, xml_path, unique_vars, h_files_needed, vars_need_extern, structs_xml_path=None, makefile_path=None):
|
||||
|
||||
xml_full_path = os.path.normpath(xml_path)
|
||||
|
||||
# Проверяем, существует ли файл, только тогда читаем из него
|
||||
existing_vars_data = {}
|
||||
if os.path.isfile(xml_full_path):
|
||||
existing_vars_data = read_vars_from_xml(xml_full_path)
|
||||
|
||||
# --- Новый блок: формируем атрибуты корневого тега ---
|
||||
analysis_attrs = {"proj_path": proj_path}
|
||||
if makefile_path:
|
||||
analysis_attrs["makefile_path"] = makefile_path
|
||||
if structs_xml_path:
|
||||
analysis_attrs["structs_path"] = structs_xml_path
|
||||
|
||||
root = ET.Element("analysis", attrib=analysis_attrs)
|
||||
|
||||
vars_elem = ET.SubElement(root, "variables")
|
||||
|
||||
# Объединяем старые и новые переменные
|
||||
combined_vars = {}
|
||||
if existing_vars_data:
|
||||
combined_vars.update(existing_vars_data)
|
||||
|
||||
for name, info in unique_vars.items():
|
||||
if name not in combined_vars:
|
||||
combined_vars[name] = {
|
||||
'enable': info.get('enable', False),
|
||||
'shortname': info.get('shortname', name),
|
||||
'pt_type': info.get('pt_type', ''),
|
||||
'iq_type': info.get('iq_type', ''),
|
||||
'return_type': info.get('return_type', 'int'),
|
||||
'type': info.get('type', 'unknown'),
|
||||
'file': info.get('file', ''),
|
||||
'extern': info.get('extern', False),
|
||||
'static': info.get('static', False),
|
||||
}
|
||||
else:
|
||||
# При необходимости можно обновить поля, например:
|
||||
# combined_vars[name].update(info)
|
||||
pass
|
||||
|
||||
# Записываем переменные с новыми полями
|
||||
for name, info in combined_vars.items():
|
||||
var_elem = ET.SubElement(vars_elem, "var", name=name)
|
||||
ET.SubElement(var_elem, "enable").text = str(info.get('enable', False)).lower()
|
||||
ET.SubElement(var_elem, "shortname").text = info.get('shortname', name)
|
||||
ET.SubElement(var_elem, "pt_type").text = info.get('pt_type', '')
|
||||
ET.SubElement(var_elem, "iq_type").text = info.get('iq_type', '')
|
||||
ET.SubElement(var_elem, "return_type").text = info.get('return_type', 'int')
|
||||
|
||||
ET.SubElement(var_elem, "type").text = info.get('type', 'unknown')
|
||||
rel_file = os.path.relpath(info.get('file', ''), proj_path) if info.get('file') else ''
|
||||
ET.SubElement(var_elem, "file").text = rel_file.replace("\\", "/") if rel_file else ''
|
||||
ET.SubElement(var_elem, "extern").text = str(info.get('extern', False)).lower()
|
||||
ET.SubElement(var_elem, "static").text = str(info.get('static', False)).lower()
|
||||
|
||||
# Секция includes (файлы)
|
||||
includes_elem = ET.SubElement(root, "includes")
|
||||
for path in h_files_needed:
|
||||
rel_path = os.path.relpath(path, proj_path)
|
||||
includes_elem_file = ET.SubElement(includes_elem, "file")
|
||||
includes_elem_file.text = rel_path.replace("\\", "/")
|
||||
|
||||
# Секция externs (переменные с extern)
|
||||
externs_elem = ET.SubElement(root, "externs")
|
||||
for name, info in vars_need_extern.items():
|
||||
var_elem = ET.SubElement(externs_elem, "var", name=name)
|
||||
ET.SubElement(var_elem, "type").text = info.get("type", "unknown")
|
||||
rel_file = os.path.relpath(info.get("file", ""), proj_path)
|
||||
ET.SubElement(var_elem, "file").text = rel_file.replace("\\", "/")
|
||||
|
||||
# Форматирование с отступами
|
||||
rough_string = ET.tostring(root, encoding="utf-8")
|
||||
reparsed = minidom.parseString(rough_string)
|
||||
pretty_xml = reparsed.toprettyxml(indent=" ")
|
||||
|
||||
with open(xml_full_path, "w", encoding="utf-8") as f:
|
||||
f.write(pretty_xml)
|
||||
|
||||
optional_printf(PRINT_STATUS, f"[XML] Variables saved to {xml_full_path}")
|
||||
|
||||
|
||||
def write_typedefs_and_structs_to_xml(proj_path, xml_path, typedefs, structs):
|
||||
def create_struct_element(parent_elem, struct_name, fields):
|
||||
struct_elem = ET.SubElement(parent_elem, "struct", name=struct_name)
|
||||
|
||||
for field_name, field_type in fields.items():
|
||||
if isinstance(field_type, dict):
|
||||
# Вложенная структура
|
||||
nested_elem = ET.SubElement(struct_elem, "field", name=field_name)
|
||||
# Сохраняем оригинальный тип (например: T_innerStruct[4], T_innerStruct*)
|
||||
if "__type__" in field_type:
|
||||
nested_elem.set("type", field_type["__type__"])
|
||||
else:
|
||||
nested_elem.set("type", "anonymous")
|
||||
|
||||
# Рекурсивно добавляем поля вложенной структуры
|
||||
create_struct_element(nested_elem, field_name, {
|
||||
k: v for k, v in field_type.items() if k != "__type__"
|
||||
})
|
||||
else:
|
||||
# Примитивное поле
|
||||
ET.SubElement(struct_elem, "field", name=field_name, type=field_type)
|
||||
|
||||
# Полный путь к xml файлу
|
||||
xml_full_path = os.path.normpath(xml_path)
|
||||
root = ET.Element("analysis")
|
||||
|
||||
# <structs>
|
||||
structs_elem = ET.SubElement(root, "structs")
|
||||
for struct_name, fields in sorted(structs.items()):
|
||||
create_struct_element(structs_elem, struct_name, fields)
|
||||
|
||||
# <typedefs>
|
||||
typedefs_elem = ET.SubElement(root, "typedefs")
|
||||
for name, underlying in sorted(typedefs.items()):
|
||||
ET.SubElement(typedefs_elem, "typedef", name=name, type=underlying)
|
||||
|
||||
# Преобразуем в красиво отформатированную XML-строку
|
||||
rough_string = ET.tostring(root, encoding="utf-8")
|
||||
reparsed = minidom.parseString(rough_string)
|
||||
pretty_xml = reparsed.toprettyxml(indent=" ")
|
||||
|
||||
with open(xml_full_path, "w", encoding="utf-8") as f:
|
||||
f.write(pretty_xml)
|
||||
|
||||
print(f"[XML] Typedefs and structs saved to: {xml_full_path}")
|
||||
|
||||
def topo_sort(graph):
|
||||
indegree = {}
|
||||
for node in graph:
|
||||
indegree.setdefault(node, 0)
|
||||
for neigh in graph[node]:
|
||||
indegree[neigh] = indegree.get(neigh, 0) + 1
|
||||
|
||||
queue = deque([node for node in indegree if indegree[node] == 0])
|
||||
sorted_list = []
|
||||
|
||||
while queue:
|
||||
node = queue.popleft()
|
||||
sorted_list.append(node)
|
||||
for neigh in graph.get(node, []):
|
||||
indegree[neigh] -= 1
|
||||
if indegree[neigh] == 0:
|
||||
queue.append(neigh)
|
||||
|
||||
if len(sorted_list) != len(indegree):
|
||||
print("Warning: include graph has cycles or disconnected components.")
|
||||
return sorted_list
|
||||
|
||||
def get_sorted_headers(c_files, h_files, include_dirs):
|
||||
index = clang.cindex.Index.create()
|
||||
args = [f"-I{inc}" for inc in include_dirs]
|
||||
|
||||
# Собираем граф зависимостей для заголовочных файлов
|
||||
include_graph = {}
|
||||
|
||||
# Проходим по всем исходникам и заголовкам, чтобы получить полный граф
|
||||
all_files_to_parse = set(c_files) | set(h_files)
|
||||
|
||||
for f in all_files_to_parse:
|
||||
try:
|
||||
tu = index.parse(f, args=args)
|
||||
except Exception as e:
|
||||
print(f"Failed to parse {f}: {e}")
|
||||
continue
|
||||
for include in tu.get_includes():
|
||||
inc_file = str(include.include)
|
||||
src_file = str(include.source)
|
||||
if not inc_file or not src_file:
|
||||
continue
|
||||
# Фокусируемся только на заголовочных файлах из списка h_files
|
||||
if src_file not in include_graph:
|
||||
include_graph[src_file] = set()
|
||||
include_graph[src_file].add(inc_file)
|
||||
|
||||
# Оставляем только заголовочные файлы из h_files, чтобы получить их зависимости
|
||||
h_files_set = set(h_files)
|
||||
filtered_graph = {}
|
||||
for src, incs in include_graph.items():
|
||||
if src in h_files_set:
|
||||
# Оставляем зависимости, которые тоже из h_files
|
||||
filtered_graph[src] = set(filter(lambda x: x in h_files_set, incs))
|
||||
|
||||
# Теперь топологическая сортировка заголовков
|
||||
sorted_h_files = topo_sort(filtered_graph)
|
||||
|
||||
# В случае если какие-то h_files не попали в граф (нет зависимостей) — добавим их в конец
|
||||
missing_headers = h_files_set - set(sorted_h_files)
|
||||
sorted_h_files.extend(sorted(missing_headers))
|
||||
|
||||
return sorted_h_files
|
||||
|
||||
|
||||
def build_include_graph(tu):
|
||||
# Возвращает dict: ключ — файл, значение — set файлов, которые он включает
|
||||
graph = {}
|
||||
for include in tu.get_includes():
|
||||
included_file = str(include.include)
|
||||
including_file = str(include.source)
|
||||
if including_file not in graph:
|
||||
graph[including_file] = set()
|
||||
graph[including_file].add(included_file)
|
||||
return graph
|
||||
|
||||
def topo_sort(graph):
|
||||
from collections import deque
|
||||
|
||||
indegree = {}
|
||||
for node in graph:
|
||||
indegree.setdefault(node, 0)
|
||||
for neigh in graph[node]:
|
||||
indegree[neigh] = indegree.get(neigh, 0) + 1
|
||||
|
||||
queue = deque([node for node in indegree if indegree[node] == 0])
|
||||
sorted_list = []
|
||||
|
||||
while queue:
|
||||
node = queue.popleft()
|
||||
sorted_list.append(node)
|
||||
for neigh in graph.get(node, []):
|
||||
indegree[neigh] -= 1
|
||||
if indegree[neigh] == 0:
|
||||
queue.append(neigh)
|
||||
|
||||
if len(sorted_list) != len(indegree):
|
||||
# Цикл или недостающие файлы
|
||||
print("Warning: include graph has cycles or disconnected components.")
|
||||
return sorted_list
|
||||
|
||||
|
||||
|
||||
def main():
|
||||
sys.stdout.reconfigure(line_buffering=True)
|
||||
global PRINT_LEVEL
|
||||
|
||||
parser = argparse.ArgumentParser(
|
||||
description="Analyze C project variables, typedefs, and structs using Clang.",
|
||||
epilog="""\
|
||||
Usage example:
|
||||
%(prog)s /path/to/project /path/to/Makefile /absolute/path/to/output_vars.xml
|
||||
""",
|
||||
formatter_class=argparse.RawDescriptionHelpFormatter,
|
||||
add_help=False
|
||||
)
|
||||
parser.add_argument("proj_path", help="Absolute path to the project root directory")
|
||||
parser.add_argument("makefile_path", help="Absolute path to the makefile to parse")
|
||||
parser.add_argument("output_xml", help="Absolute path to output XML file for variables")
|
||||
|
||||
parser.add_argument("-h", "--help", action="store_true", help="Show this help message and exit")
|
||||
parser.add_argument("-v", "--verbose", type=int, choices=range(0,6), default=2,
|
||||
help="Set verbosity level from 0 (quiet) to 5 (most detailed), default=2")
|
||||
|
||||
if "-h" in sys.argv or "--help" in sys.argv:
|
||||
parser.print_help()
|
||||
print("\nUsage example:")
|
||||
print(f" {os.path.basename(sys.argv[0])} /path/to/project /path/to/Makefile /absolute/path/to/output_vars.xml")
|
||||
sys.exit(0)
|
||||
|
||||
if len(sys.argv) < 4:
|
||||
print("Error: insufficient arguments.\n")
|
||||
print("Usage example:")
|
||||
print(f" {os.path.basename(sys.argv[0])} /path/to/project /path/to/Makefile /absolute/path/to/output_vars.xml")
|
||||
sys.exit(1)
|
||||
|
||||
args = parser.parse_args()
|
||||
|
||||
PRINT_LEVEL = args.verbose
|
||||
|
||||
proj_path = os.path.normpath(args.proj_path)
|
||||
makefile_path = os.path.normpath(args.makefile_path)
|
||||
output_xml = os.path.normpath(args.output_xml)
|
||||
|
||||
# Проверка абсолютности путей
|
||||
for path, name in [(proj_path, "Project path"), (makefile_path, "Makefile path"), (output_xml, "Output XML path")]:
|
||||
if not os.path.isabs(path):
|
||||
print(f"Error: {name} '{path}' is not an absolute path.")
|
||||
sys.exit(1)
|
||||
|
||||
if not os.path.isdir(proj_path):
|
||||
print(f"Error: Project path '{proj_path}' is not a directory or does not exist.")
|
||||
sys.exit(1)
|
||||
if not os.path.isfile(makefile_path):
|
||||
print(f"Error: Makefile path '{makefile_path}' does not exist.")
|
||||
sys.exit(1)
|
||||
|
||||
c_files, h_files, include_dirs = parse_makefile(makefile_path)
|
||||
|
||||
vars, includes, externs = analyze_variables_across_files(c_files, h_files, include_dirs)
|
||||
typedefs, structs = analyze_typedefs_and_structs_across_files(c_files, include_dirs)
|
||||
|
||||
vars = dict(sorted(vars.items()))
|
||||
includes = get_sorted_headers(c_files, includes, include_dirs)
|
||||
externs = dict(sorted(externs.items()))
|
||||
typedefs = dict(sorted(typedefs.items()))
|
||||
structs = dict(sorted(structs.items()))
|
||||
print('create structs')
|
||||
# Определяем путь к файлу с структурами рядом с output_xml
|
||||
structs_xml = os.path.join(os.path.dirname(output_xml), "structs.xml")
|
||||
|
||||
# Записываем структуры в structs_xml
|
||||
write_typedefs_and_structs_to_xml(proj_path, structs_xml, typedefs, structs)
|
||||
|
||||
print('create vars')
|
||||
# Передаем путь к structs.xml относительно proj_path в vars.xml
|
||||
# Модифицируем generate_xml_output так, чтобы принимать и путь к structs.xml (относительный)
|
||||
generate_xml_output(proj_path, output_xml, vars, includes, externs, structs_xml, makefile_path)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
|
570
setupVars.py
Normal file
570
setupVars.py
Normal file
@ -0,0 +1,570 @@
|
||||
import sys
|
||||
import os
|
||||
import subprocess
|
||||
import xml.etree.ElementTree as ET
|
||||
from generateVars import map_type_to_pt, get_iq_define, type_map
|
||||
from enum import IntEnum
|
||||
|
||||
from PySide6.QtWidgets import (
|
||||
QApplication, QWidget, QTableWidget, QTableWidgetItem,
|
||||
QCheckBox, QComboBox, QLineEdit, QVBoxLayout, QHBoxLayout, QPushButton,
|
||||
QCompleter, QAbstractItemView, QLabel, QMessageBox, QFileDialog, QTextEdit
|
||||
)
|
||||
from PySide6.QtGui import QTextCursor
|
||||
from PySide6.QtCore import Qt, QProcess
|
||||
|
||||
class rows(IntEnum):
|
||||
include = 0
|
||||
name = 1
|
||||
type = 2
|
||||
pt_type = 3
|
||||
iq_type = 4
|
||||
ret_type = 5
|
||||
short_name = 6
|
||||
|
||||
# 1. Парсим vars.xml
|
||||
def make_absolute_path(path, base_path):
|
||||
if not os.path.isabs(path):
|
||||
return os.path.abspath(os.path.join(base_path, path))
|
||||
return os.path.abspath(path)
|
||||
|
||||
def parse_vars(filename):
|
||||
tree = ET.parse(filename)
|
||||
root = tree.getroot()
|
||||
|
||||
vars_list = []
|
||||
variables_elem = root.find('variables')
|
||||
if variables_elem is not None:
|
||||
for var in variables_elem.findall('var'):
|
||||
name = var.attrib.get('name', '')
|
||||
vars_list.append({
|
||||
'name': name,
|
||||
'enable': var.findtext('enable', 'false'),
|
||||
'shortname': var.findtext('shortname', name),
|
||||
'pt_type': var.findtext('pt_type', 'pt_unknown'),
|
||||
'iq_type': var.findtext('iq_type', 'iq_none'),
|
||||
'return_type': var.findtext('return_type', 'int'),
|
||||
'type': var.findtext('type', 'unknown'),
|
||||
'file': var.findtext('file', ''),
|
||||
'extern': var.findtext('extern', 'false') == 'true',
|
||||
'static': var.findtext('static', 'false') == 'true',
|
||||
})
|
||||
|
||||
return vars_list
|
||||
|
||||
# 2. Парсим structSup.xml
|
||||
def parse_structs(filename):
|
||||
tree = ET.parse(filename)
|
||||
root = tree.getroot()
|
||||
|
||||
structs = {}
|
||||
typedef_map = {}
|
||||
|
||||
# --- Считываем структуры ---
|
||||
structs_elem = root.find('structs')
|
||||
if structs_elem is not None:
|
||||
for struct in structs_elem.findall('struct'):
|
||||
name = struct.attrib['name']
|
||||
fields = {}
|
||||
for field in struct.findall('field'):
|
||||
fname = field.attrib.get('name')
|
||||
ftype = field.attrib.get('type')
|
||||
if fname and ftype:
|
||||
fields[fname] = ftype
|
||||
structs[name] = fields
|
||||
|
||||
# --- Считываем typedef-ы ---
|
||||
typedefs_elem = root.find('typedefs')
|
||||
if typedefs_elem is not None:
|
||||
for typedef in typedefs_elem.findall('typedef'):
|
||||
name = typedef.attrib.get('name')
|
||||
target_type = typedef.attrib.get('type')
|
||||
if name and target_type:
|
||||
typedef_map[name.strip()] = target_type.strip()
|
||||
|
||||
return structs, typedef_map
|
||||
|
||||
|
||||
|
||||
class ProcessOutputWindow(QWidget):
|
||||
def __init__(self, command, args):
|
||||
super().__init__()
|
||||
self.setWindowTitle("Поиск переменных...")
|
||||
self.resize(600, 400)
|
||||
|
||||
self.layout = QVBoxLayout(self)
|
||||
self.output_edit = QTextEdit()
|
||||
self.output_edit.setReadOnly(True)
|
||||
self.layout.addWidget(self.output_edit)
|
||||
|
||||
self.btn_close = QPushButton("Закрыть")
|
||||
self.btn_close.setEnabled(False)
|
||||
self.btn_close.clicked.connect(self.close)
|
||||
self.layout.addWidget(self.btn_close)
|
||||
|
||||
self.process = QProcess(self)
|
||||
self.process.setProcessChannelMode(QProcess.MergedChannels)
|
||||
self.process.readyReadStandardOutput.connect(self.handle_stdout)
|
||||
self.process.finished.connect(self.process_finished)
|
||||
|
||||
self.process.start(command, args)
|
||||
|
||||
def handle_stdout(self):
|
||||
data = self.process.readAllStandardOutput()
|
||||
text = data.data().decode('utf-8')
|
||||
self.output_edit.append(text)
|
||||
|
||||
def process_finished(self):
|
||||
self.output_edit.append("\n--- Процесс завершён ---")
|
||||
self.btn_close.setEnabled(True)
|
||||
|
||||
# 3. UI: таблица с переменными
|
||||
class VarEditor(QWidget):
|
||||
def __init__(self):
|
||||
super().__init__()
|
||||
self.vars_list = []
|
||||
self.structs = {}
|
||||
self.typedef_map = {}
|
||||
self.structs_xml_path = None # сюда запишем путь из <structs_xml>
|
||||
self.initUI()
|
||||
|
||||
def initUI(self):
|
||||
self.setWindowTitle("Variable Editor")
|
||||
|
||||
# --- Поля ввода пути проекта и XML ---
|
||||
|
||||
# XML Output
|
||||
xml_layout = QHBoxLayout()
|
||||
xml_layout.addWidget(QLabel("XML Output:"))
|
||||
self.xml_output_edit = QLineEdit()
|
||||
xml_layout.addWidget(self.xml_output_edit)
|
||||
self.xml_output_edit.returnPressed.connect(self.read_xml_file)
|
||||
btn_xml_browse = QPushButton("...")
|
||||
btn_xml_browse.setFixedWidth(30)
|
||||
xml_layout.addWidget(btn_xml_browse)
|
||||
btn_xml_browse.clicked.connect(self.browse_xml_output)
|
||||
|
||||
# Project Path
|
||||
proj_layout = QHBoxLayout()
|
||||
proj_layout.addWidget(QLabel("Project Path:"))
|
||||
self.proj_path_edit = QLineEdit()
|
||||
proj_layout.addWidget(self.proj_path_edit)
|
||||
btn_proj_browse = QPushButton("...")
|
||||
btn_proj_browse.setFixedWidth(30)
|
||||
proj_layout.addWidget(btn_proj_browse)
|
||||
btn_proj_browse.clicked.connect(self.browse_proj_path)
|
||||
|
||||
# Makefile Path
|
||||
makefile_layout = QHBoxLayout()
|
||||
makefile_layout.addWidget(QLabel("Makefile Path (relative path):"))
|
||||
self.makefile_edit = QLineEdit()
|
||||
makefile_layout.addWidget(self.makefile_edit)
|
||||
btn_makefile_browse = QPushButton("...")
|
||||
btn_makefile_browse.setFixedWidth(30)
|
||||
makefile_layout.addWidget(btn_makefile_browse)
|
||||
btn_makefile_browse.clicked.connect(self.browse_makefile)
|
||||
|
||||
|
||||
|
||||
# Source Output File/Directory
|
||||
source_output_layout = QHBoxLayout()
|
||||
source_output_layout.addWidget(QLabel("Source Output File:"))
|
||||
self.source_output_edit = QLineEdit()
|
||||
source_output_layout.addWidget(self.source_output_edit)
|
||||
btn_source_output_browse = QPushButton("...")
|
||||
btn_source_output_browse.setFixedWidth(30)
|
||||
source_output_layout.addWidget(btn_source_output_browse)
|
||||
btn_source_output_browse.clicked.connect(self.browse_source_output)
|
||||
|
||||
|
||||
self.btn_update_vars = QPushButton("Обновить данные о переменных")
|
||||
self.btn_update_vars.clicked.connect(self.update_vars_data)
|
||||
|
||||
# Таблица переменных
|
||||
self.table = QTableWidget(len(self.vars_list), 7)
|
||||
self.table.setHorizontalHeaderLabels([
|
||||
'Include',
|
||||
'Name',
|
||||
'Origin Type',
|
||||
'Pointer Type',
|
||||
'IQ Type',
|
||||
'Return Type',
|
||||
'Short Name'
|
||||
])
|
||||
self.table.setEditTriggers(QAbstractItemView.AllEditTriggers)
|
||||
|
||||
# Кнопка сохранения
|
||||
btn_save = QPushButton("Build")
|
||||
btn_save.clicked.connect(self.save_build)
|
||||
|
||||
# Основной layout
|
||||
layout = QVBoxLayout()
|
||||
layout.addLayout(xml_layout)
|
||||
layout.addLayout(proj_layout)
|
||||
layout.addLayout(makefile_layout)
|
||||
layout.addWidget(self.btn_update_vars)
|
||||
layout.addWidget(self.table)
|
||||
layout.addWidget(btn_save)
|
||||
layout.addLayout(source_output_layout)
|
||||
|
||||
self.setLayout(layout)
|
||||
|
||||
def update_vars_data(self):
|
||||
proj_path = self.proj_path_edit.text().strip()
|
||||
xml_path = self.xml_output_edit.text().strip()
|
||||
|
||||
proj_path = os.path.abspath(self.proj_path_edit.text().strip())
|
||||
makefile_path = make_absolute_path(self.makefile_edit.text().strip(), proj_path)
|
||||
|
||||
if not proj_path or not xml_path:
|
||||
QMessageBox.warning(self, "Ошибка", "Пожалуйста, укажите пути проекта и XML.")
|
||||
return
|
||||
|
||||
if not os.path.isfile(makefile_path):
|
||||
QMessageBox.warning(self, "Ошибка", f"Makefile не найден по пути:\n{makefile_path}")
|
||||
return
|
||||
|
||||
scanvars_exe = "scanVars.exe"
|
||||
args = [proj_path, makefile_path, xml_path]
|
||||
|
||||
# Создаем и показываем окно с выводом процесса
|
||||
self.proc_win = ProcessOutputWindow(scanvars_exe, args)
|
||||
self.proc_win.show()
|
||||
|
||||
# Можно подписаться на сигнал завершения процесса, если хочешь обновить UI после
|
||||
self.proc_win.process.finished.connect(lambda exitCode, exitStatus: self.after_scanvars_finished(exitCode, exitStatus))
|
||||
|
||||
|
||||
def save_build(self):
|
||||
vars_out = []
|
||||
for row in range(self.table.rowCount()):
|
||||
include_cb = self.table.cellWidget(row, rows.include)
|
||||
if not include_cb.isChecked():
|
||||
continue
|
||||
name_edit = self.table.cellWidget(row, rows.name)
|
||||
pt_type_combo = self.table.cellWidget(row, rows.pt_type)
|
||||
iq_combo = self.table.cellWidget(row, rows.iq_type)
|
||||
ret_combo = self.table.cellWidget(row, rows.ret_type)
|
||||
short_name_edit = self.table.cellWidget(row, rows.short_name)
|
||||
|
||||
var_data = {
|
||||
'name': name_edit.text(),
|
||||
'type': 'pt_' + pt_type_combo.currentText(),
|
||||
'iq_type': iq_combo.currentText(),
|
||||
'return_type': ret_combo.currentText() if ret_combo.currentText() else 'int',
|
||||
'short_name': short_name_edit.text(),
|
||||
}
|
||||
vars_out.append(var_data)
|
||||
|
||||
# Здесь нужно указать абсолютные пути к проекту, xml и output (замени на свои)
|
||||
proj_path = self.proj_path_edit.text().strip()
|
||||
xml_path = self.xml_output_edit.text().strip()
|
||||
output_dir_c_file = self.source_output_edit.text().strip()
|
||||
|
||||
# Путь к твоему exe, например
|
||||
exe_path = r"generateVars.exe"
|
||||
|
||||
# Формируем список аргументов
|
||||
cmd = [exe_path, proj_path, xml_path, output_dir_c_file]
|
||||
|
||||
try:
|
||||
# Запускаем exe и ждём завершения
|
||||
result = subprocess.run(cmd, capture_output=True, text=True, check=True)
|
||||
except subprocess.CalledProcessError as e:
|
||||
print("Error calling script:", e)
|
||||
print("stderr:", e.stderr)
|
||||
|
||||
def browse_proj_path(self):
|
||||
dir_path = QFileDialog.getExistingDirectory(self, "Выберите папку проекта")
|
||||
if dir_path:
|
||||
self.proj_path_edit.setText(dir_path)
|
||||
|
||||
def read_xml_file(self):
|
||||
file_path = self.xml_output_edit.text().strip()
|
||||
if file_path and not os.path.isfile(file_path):
|
||||
return
|
||||
|
||||
self.vars_list = parse_vars(file_path)
|
||||
try:
|
||||
tree = ET.parse(file_path)
|
||||
root = tree.getroot()
|
||||
|
||||
proj_path = self.proj_path_edit.text().strip()
|
||||
|
||||
if not proj_path:
|
||||
# Если в поле ничего нет, пробуем взять из XML
|
||||
proj_path_from_xml = root.attrib.get('proj_path', '').strip()
|
||||
if proj_path_from_xml and os.path.isdir(proj_path_from_xml):
|
||||
proj_path = proj_path_from_xml
|
||||
self.proj_path_edit.setText(proj_path_from_xml)
|
||||
else:
|
||||
QMessageBox.warning(
|
||||
self,
|
||||
"Внимание",
|
||||
"Путь к проекту (proj_path) не найден или не существует.\n"
|
||||
"Пожалуйста, укажите его вручную в поле 'Project Path'."
|
||||
)
|
||||
else:
|
||||
if not os.path.isdir(proj_path):
|
||||
QMessageBox.warning(
|
||||
self,
|
||||
"Внимание",
|
||||
f"Указанный путь к проекту не существует:\n{proj_path}\n"
|
||||
"Пожалуйста, исправьте путь в поле 'Project Path'."
|
||||
)
|
||||
|
||||
|
||||
# --- makefile_path из атрибута ---
|
||||
makefile_path = root.attrib.get('makefile_path', '').strip()
|
||||
makefile_path_full = make_absolute_path(makefile_path, proj_path)
|
||||
if makefile_path_full and os.path.isfile(makefile_path_full):
|
||||
self.makefile_edit.setText(makefile_path)
|
||||
|
||||
# --- structs_path из атрибута ---
|
||||
structs_path = root.attrib.get('structs_path', '').strip()
|
||||
structs_path_full = make_absolute_path(structs_path, proj_path)
|
||||
if structs_path_full and os.path.isfile(structs_path_full):
|
||||
self.structs_xml_path = structs_path_full
|
||||
self.structs, self.typedef_map = parse_structs(structs_path_full)
|
||||
else:
|
||||
self.structs_xml_path = None
|
||||
|
||||
self.update_table()
|
||||
except Exception as e:
|
||||
QMessageBox.warning(self, "Ошибка", f"Ошибка при чтении XML:\n{e}")
|
||||
|
||||
def browse_xml_output(self):
|
||||
file_path, _ = QFileDialog.getSaveFileName(
|
||||
self,
|
||||
"Выберите XML файл",
|
||||
filter="XML files (*.xml);;All Files (*)"
|
||||
)
|
||||
self.xml_output_edit.setText(file_path)
|
||||
self.read_xml_file()
|
||||
|
||||
|
||||
def browse_xml_struct(self):
|
||||
file_path, _ = QFileDialog.getSaveFileName(self, "Выберите XML файл", filter="XML files (*.xml);;All Files (*)")
|
||||
if file_path:
|
||||
self.xml_output_edit.setText(file_path)
|
||||
if os.path.isfile(file_path):
|
||||
self.structs, self.typedef_map = parse_structs(file_path)
|
||||
|
||||
def browse_makefile(self):
|
||||
file_path, _ = QFileDialog.getOpenFileName(
|
||||
self, "Выберите Makefile", filter="Makefile (makefile);;All Files (*)"
|
||||
)
|
||||
if file_path:
|
||||
self.makefile_edit.setText(file_path)
|
||||
|
||||
def browse_source_output(self):
|
||||
dir_path = QFileDialog.getExistingDirectory(self, "Выберите папку для debug_vars.c")
|
||||
if dir_path:
|
||||
self.source_output_edit.setText(dir_path)
|
||||
|
||||
def after_scanvars_finished(self, exitCode, exitStatus):
|
||||
xml_path = self.xml_output_edit.text().strip()
|
||||
if not os.path.isfile(xml_path):
|
||||
QMessageBox.critical(self, "Ошибка", f"Файл не найден: {xml_path}")
|
||||
return
|
||||
|
||||
try:
|
||||
# Читаем структуры, если задан путь
|
||||
if self.structs_xml_path and os.path.isfile(self.structs_xml_path):
|
||||
try:
|
||||
self.structs, self.typedef_map = parse_structs(self.structs_xml_path)
|
||||
# При необходимости обновите UI или сделайте что-то с self.structs
|
||||
except Exception as e:
|
||||
QMessageBox.warning(self, "Внимание", f"Не удалось загрузить структуры из {self.structs_xml_path}:\n{e}")
|
||||
|
||||
self.vars_list = parse_vars(xml_path)
|
||||
self.update_table()
|
||||
|
||||
|
||||
except Exception as e:
|
||||
QMessageBox.critical(self, "Ошибка", f"Не удалось загрузить переменные:\n{e}")
|
||||
|
||||
def update_table(self):
|
||||
self.type_options = list(dict.fromkeys(type_map.values()))
|
||||
self.display_type_options = [t.replace('pt_', '') for t in self.type_options]
|
||||
iq_types = ['iq_none', 'iq'] + [f'iq{i}' for i in range(1, 31)]
|
||||
self.table.setRowCount(len(self.vars_list))
|
||||
|
||||
for row, var in enumerate(self.vars_list):
|
||||
cb = QCheckBox()
|
||||
enable_str = var.get('enable', 'false')
|
||||
cb.setChecked(enable_str.lower() == 'true')
|
||||
self.table.setCellWidget(row, rows.include, cb)
|
||||
|
||||
name_edit = QLineEdit(var['name'])
|
||||
if var['type'] in self.structs:
|
||||
completer = QCompleter(self.structs[var['type']].keys())
|
||||
completer.setCaseSensitivity(Qt.CaseInsensitive)
|
||||
name_edit.setCompleter(completer)
|
||||
self.table.setCellWidget(row, rows.name, name_edit)
|
||||
|
||||
# Type (origin)
|
||||
origin_type = var.get('type', '').strip()
|
||||
origin_item = QTableWidgetItem(origin_type)
|
||||
origin_item.setFlags(Qt.ItemIsSelectable | Qt.ItemIsEnabled) # read-only
|
||||
self.table.setItem(row, rows.type, origin_item)
|
||||
|
||||
pt_type_combo = QComboBox()
|
||||
pt_type_combo.addItems(self.display_type_options)
|
||||
internal_type = map_type_to_pt(var['type'], var['name'], self.typedef_map)
|
||||
display_type = internal_type.replace('pt_', '')
|
||||
if display_type in self.display_type_options:
|
||||
pt_type_combo.setCurrentText(display_type)
|
||||
else:
|
||||
pt_type_combo.addItem(display_type)
|
||||
pt_type_combo.setCurrentText(display_type)
|
||||
self.table.setCellWidget(row, rows.pt_type, pt_type_combo)
|
||||
|
||||
iq_combo = QComboBox()
|
||||
iq_combo.addItems(iq_types)
|
||||
iq_type = get_iq_define(var['type']) # Получаем IQ-тип, например 'iq24'
|
||||
display_type = iq_type.replace('t_', '')
|
||||
if iq_type in iq_types:
|
||||
iq_combo.setCurrentText(display_type)
|
||||
else:
|
||||
iq_combo.addItem(display_type)
|
||||
iq_combo.setCurrentText(display_type)
|
||||
self.table.setCellWidget(row, rows.iq_type, iq_combo)
|
||||
|
||||
ret_combo = QComboBox()
|
||||
ret_combo.addItems(iq_types)
|
||||
self.table.setCellWidget(row, rows.ret_type, ret_combo)
|
||||
|
||||
short_name_edit = QLineEdit(var['name'])
|
||||
self.table.setCellWidget(row, rows.short_name, short_name_edit)
|
||||
|
||||
cb.stateChanged.connect(self.save_table_to_xml)
|
||||
name_edit.textChanged.connect(self.save_table_to_xml)
|
||||
pt_type_combo.currentTextChanged.connect(self.save_table_to_xml)
|
||||
iq_combo.currentTextChanged.connect(self.save_table_to_xml)
|
||||
ret_combo.currentTextChanged.connect(self.save_table_to_xml)
|
||||
short_name_edit.textChanged.connect(self.save_table_to_xml)
|
||||
|
||||
|
||||
def save_table_to_xml(self):
|
||||
def make_relative_path(abs_path, base_path):
|
||||
try:
|
||||
return os.path.relpath(abs_path, base_path).replace("\\", "/")
|
||||
except ValueError:
|
||||
return abs_path.replace("\\", "/")
|
||||
|
||||
xml_path = self.xml_output_edit.text().strip()
|
||||
proj_path = self.proj_path_edit.text().strip()
|
||||
makefile_path = self.makefile_edit.text().strip()
|
||||
|
||||
if not xml_path or not os.path.isfile(xml_path):
|
||||
print("XML файл не найден или путь пустой")
|
||||
return
|
||||
|
||||
try:
|
||||
tree = ET.parse(xml_path)
|
||||
root = tree.getroot()
|
||||
|
||||
# Обновим атрибуты с относительными путями
|
||||
if os.path.isdir(proj_path):
|
||||
root.set("proj_path", proj_path.replace("\\", "/"))
|
||||
|
||||
if os.path.isfile(makefile_path):
|
||||
rel_makefile = make_relative_path(makefile_path, proj_path)
|
||||
root.set("makefile_path", rel_makefile)
|
||||
|
||||
if self.structs_xml_path and os.path.isfile(self.structs_xml_path):
|
||||
rel_struct_path = make_relative_path(self.structs_xml_path, proj_path)
|
||||
root.set("structs_path", rel_struct_path)
|
||||
|
||||
|
||||
vars_elem = root.find('variables')
|
||||
if vars_elem is None:
|
||||
# Если блока нет, создаём
|
||||
vars_elem = ET.SubElement(root, 'variables')
|
||||
|
||||
original_info = {}
|
||||
for var_elem in vars_elem.findall('var'):
|
||||
name = var_elem.attrib.get('name')
|
||||
if name:
|
||||
original_info[name] = {
|
||||
'type': var_elem.findtext('type', ''),
|
||||
'file': var_elem.findtext('file', ''),
|
||||
'extern': var_elem.findtext('extern', ''),
|
||||
'static': var_elem.findtext('static', '')
|
||||
}
|
||||
# Собираем данные из таблицы
|
||||
updated_vars = []
|
||||
for row in range(self.table.rowCount()):
|
||||
cb = self.table.cellWidget(row, 0)
|
||||
name_edit = self.table.cellWidget(row, 1)
|
||||
pt_type_combo = self.table.cellWidget(row, 3)
|
||||
iq_combo = self.table.cellWidget(row, 4)
|
||||
ret_combo = self.table.cellWidget(row, 5)
|
||||
short_name_edit = self.table.cellWidget(row, 6)
|
||||
|
||||
var_name = name_edit.text()
|
||||
|
||||
# Берём оригинальные type и file из словаря, если есть
|
||||
orig_type = original_info.get(var_name, {}).get('type', '')
|
||||
orig_file = original_info.get(var_name, {}).get('file', '')
|
||||
orig_extern = original_info.get(var_name, {}).get('extern', '')
|
||||
orig_static = original_info.get(var_name, {}).get('static', '')
|
||||
|
||||
updated_vars.append({
|
||||
'name': var_name,
|
||||
'enable': cb.isChecked(),
|
||||
'shortname': short_name_edit.text(),
|
||||
'pt_type': 'pt_' + pt_type_combo.currentText(),
|
||||
'iq_type': iq_combo.currentText(),
|
||||
'return_type': ret_combo.currentText() or 'int',
|
||||
'type': orig_type,
|
||||
'file': orig_file,
|
||||
'extern': orig_extern,
|
||||
'static': orig_static,
|
||||
})
|
||||
|
||||
# Обновляем или добавляем по одному var в XML
|
||||
for v in updated_vars:
|
||||
var_elem = None
|
||||
for ve in vars_elem.findall('var'):
|
||||
if ve.attrib.get('name') == v['name']:
|
||||
var_elem = ve
|
||||
break
|
||||
if var_elem is None:
|
||||
var_elem = ET.SubElement(vars_elem, 'var', {'name': v['name']})
|
||||
|
||||
def set_sub_elem_text(parent, tag, text):
|
||||
el = parent.find(tag)
|
||||
if el is None:
|
||||
el = ET.SubElement(parent, tag)
|
||||
el.text = str(text)
|
||||
|
||||
set_sub_elem_text(var_elem, 'enable', 'true' if v['enable'] else 'false')
|
||||
set_sub_elem_text(var_elem, 'shortname', v['shortname'])
|
||||
set_sub_elem_text(var_elem, 'pt_type', v['pt_type'])
|
||||
set_sub_elem_text(var_elem, 'iq_type', v['iq_type'])
|
||||
set_sub_elem_text(var_elem, 'return_type', v['return_type'])
|
||||
set_sub_elem_text(var_elem, 'type', v['type'])
|
||||
set_sub_elem_text(var_elem, 'file', v['file'])
|
||||
set_sub_elem_text(var_elem, 'extern', v['extern'])
|
||||
set_sub_elem_text(var_elem, 'static', v['static'])
|
||||
|
||||
# Сохраняем изменения
|
||||
tree.write(xml_path, encoding='utf-8', xml_declaration=True)
|
||||
|
||||
except Exception as e:
|
||||
print(f"Ошибка при сохранении XML: {e}")
|
||||
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
app = QApplication(sys.argv)
|
||||
|
||||
editor = VarEditor()
|
||||
editor.resize(900, 600)
|
||||
editor.show()
|
||||
|
||||
sys.exit(app.exec())
|
||||
|
||||
|
20181
structs.xml
Normal file
20181
structs.xml
Normal file
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user