mirror of
https://github.com/halo-re/halo.git
synced 2024-11-30 09:00:34 +00:00
Move tools into tools dir
This commit is contained in:
parent
671e1d9428
commit
b9c928a9c8
2
Makefile
2
Makefile
@ -14,6 +14,6 @@ $(REIMPLEMENTATION_EXE): .FORCE
|
||||
$(MAKE) -C src
|
||||
|
||||
$(OUTPUT_XBE): $(INPUT_XBE) $(REIMPLEMENTATION_EXE)
|
||||
./patch.py $(INPUT_XBE) $(REIMPLEMENTATION_EXE) $(OUTPUT_XBE)
|
||||
./tools/patch.py $(INPUT_XBE) $(REIMPLEMENTATION_EXE) $(OUTPUT_XBE)
|
||||
|
||||
.PHONY: .FORCE
|
||||
|
@ -62,10 +62,10 @@ $(CURDIR)/build_info.c:
|
||||
$(CC) $(CFLAGS) -MD -MP -MT '$@' -MF '$(patsubst %.obj,%.c.d,$@)' -c -o '$@' '$<'
|
||||
|
||||
$(CURDIR)/typechecks.c: $(CURDIR)/types.h
|
||||
python ../misc/gen-struct-checks.py $< > $@
|
||||
python ../tools/gen-struct-checks.py $< > $@
|
||||
|
||||
$(CURDIR)/decl_generated.h $(CURDIR)/halo.xbe.def $(CURDIR)/thunks.c: ../kb.json
|
||||
python ../knowledge.py \
|
||||
python ../tools/knowledge.py \
|
||||
--gen-header $(CURDIR)/decl_generated.h \
|
||||
--gen-def $(CURDIR)/halo.xbe.def \
|
||||
--gen-thunks $(CURDIR)/thunks.c
|
||||
|
@ -13,7 +13,7 @@ except ImportError:
|
||||
clang = None
|
||||
|
||||
log = logging.getLogger(__name__)
|
||||
root_dir = os.path.dirname(os.path.abspath(__file__))
|
||||
root_dir = os.path.abspath(os.path.join(os.path.dirname(os.path.abspath(__file__)), '..'))
|
||||
reg_filter_re = re.compile(r'@<(\w+)>')
|
||||
|
||||
def filter_reg_assignments(s: str) -> str:
|
||||
@ -232,8 +232,8 @@ __attribute__((section("thunks")))
|
||||
if s.addr:
|
||||
kb.name_to_addr[s.name] = s.addr
|
||||
|
||||
if os.path.exists('misc/load_truth.py'):
|
||||
from misc.load_truth import load_truth
|
||||
if os.path.exists(os.path.join(root_dir, 'tools', 'load_truth.py')):
|
||||
from load_truth import load_truth
|
||||
load_truth(kb)
|
||||
|
||||
kb.addr_to_symbol = {s.addr:s for s in kb.symbols}
|
@ -7,8 +7,8 @@ from typing import Mapping, Tuple, Optional, Sequence
|
||||
|
||||
import clang.cindex as clang
|
||||
|
||||
from misc import color
|
||||
from knowledge import KnowledgeBase
|
||||
import color
|
||||
from .knowledge import KnowledgeBase
|
||||
|
||||
|
||||
log = logging.getLogger(__name__)
|
@ -10,7 +10,7 @@ import argparse
|
||||
import pefile
|
||||
from xbe import Xbe, XbeSection, XbeSectionHeader, XbeKernelImage
|
||||
|
||||
from misc import color
|
||||
import color
|
||||
from knowledge import KnowledgeBase
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user