2021-02-05 20:00:17 +00:00
|
|
|
version: '3'
|
|
|
|
|
2022-02-12 22:48:50 +00:00
|
|
|
includes:
|
|
|
|
build: ./scripts/tasks/Taskfile_{{OS}}.yml
|
2022-02-09 01:23:06 +00:00
|
|
|
|
2021-02-05 20:00:17 +00:00
|
|
|
tasks:
|
2022-02-12 22:48:50 +00:00
|
|
|
# GENERAL
|
|
|
|
extract-jak1:
|
2022-04-20 22:20:59 +00:00
|
|
|
desc: "Extracts Jak 1 - NTSC - Black Label assets"
|
2022-03-11 00:25:01 +00:00
|
|
|
preconditions:
|
|
|
|
- sh: test -f {{.DECOMP_BIN_RELEASE_DIR}}/decompiler{{.EXE_FILE_EXTENSION}}
|
2022-05-06 22:19:37 +00:00
|
|
|
msg: "Couldn't locate decompiler executable in '{{.DECOMP_BIN_RELEASE_DIR}}/decompiler'"
|
2022-02-12 22:48:50 +00:00
|
|
|
cmds:
|
2022-02-14 03:09:34 +00:00
|
|
|
- '{{.DECOMP_BIN_RELEASE_DIR}}/decompiler "./decompiler/config/jak1_ntsc_black_label.jsonc" "./iso_data" "./decompiler_out" "decompile_code=false"'
|
2022-02-12 22:48:50 +00:00
|
|
|
boot-game:
|
2022-04-20 22:20:59 +00:00
|
|
|
desc: "Boots the game"
|
2022-03-11 00:25:01 +00:00
|
|
|
preconditions:
|
2022-04-12 22:48:27 +00:00
|
|
|
- sh: test -f {{.GK_BIN_RELEASE_DIR}}/gk{{.EXE_FILE_EXTENSION}}
|
2022-05-06 22:19:37 +00:00
|
|
|
msg: "Couldn't locate runtime executable in '{{.GK_BIN_RELEASE_DIR}}/gk'"
|
2022-02-12 22:48:50 +00:00
|
|
|
cmds:
|
2022-02-14 03:09:34 +00:00
|
|
|
- "{{.GK_BIN_RELEASE_DIR}}/gk -boot -fakeiso -debug -v"
|
2022-02-12 22:48:50 +00:00
|
|
|
run-game:
|
2022-04-20 22:20:59 +00:00
|
|
|
desc: "Start the game's runtime"
|
2022-03-11 00:25:01 +00:00
|
|
|
preconditions:
|
2022-04-12 22:48:27 +00:00
|
|
|
- sh: test -f {{.GK_BIN_RELEASE_DIR}}/gk{{.EXE_FILE_EXTENSION}}
|
2022-05-06 22:19:37 +00:00
|
|
|
msg: "Couldn't locate runtime executable in '{{.GK_BIN_RELEASE_DIR}}/gk'"
|
2022-02-12 22:48:50 +00:00
|
|
|
cmds:
|
2022-02-14 03:09:34 +00:00
|
|
|
- "{{.GK_BIN_RELEASE_DIR}}/gk -fakeiso -debug -v"
|
2022-03-21 00:29:44 +00:00
|
|
|
run-game-quiet:
|
|
|
|
preconditions:
|
2022-04-12 22:48:27 +00:00
|
|
|
- sh: test -f {{.GK_BIN_RELEASE_DIR}}/gk{{.EXE_FILE_EXTENSION}}
|
2022-05-06 22:19:37 +00:00
|
|
|
msg: "Couldn't locate runtime executable in '{{.GK_BIN_RELEASE_DIR}}/gk'"
|
2022-03-21 00:29:44 +00:00
|
|
|
cmds:
|
|
|
|
- "{{.GK_BIN_RELEASE_DIR}}/gk -fakeiso"
|
2022-02-12 22:48:50 +00:00
|
|
|
repl:
|
2022-04-20 22:20:59 +00:00
|
|
|
desc: "Start the REPL"
|
2022-02-12 22:48:50 +00:00
|
|
|
env:
|
|
|
|
OPENGOAL_DECOMP_DIR: "jak1/"
|
2022-03-11 00:25:01 +00:00
|
|
|
preconditions:
|
2022-04-12 22:48:27 +00:00
|
|
|
- sh: test -f {{.GOALC_BIN_RELEASE_DIR}}/goalc{{.EXE_FILE_EXTENSION}}
|
2022-05-06 22:19:37 +00:00
|
|
|
msg: "Couldn't locate compiler executable in '{{.GOALC_BIN_RELEASE_DIR}}/goalc'"
|
2022-02-12 22:48:50 +00:00
|
|
|
cmds:
|
2022-02-14 03:09:34 +00:00
|
|
|
- "{{.GOALC_BIN_RELEASE_DIR}}/goalc"
|
2022-02-12 22:48:50 +00:00
|
|
|
# DEVELOPMENT
|
2021-02-05 20:00:17 +00:00
|
|
|
format:
|
2022-04-20 22:20:59 +00:00
|
|
|
desc: "Format code"
|
2021-02-05 20:00:17 +00:00
|
|
|
cmds:
|
2021-10-17 01:01:23 +00:00
|
|
|
- cmd: python ./third-party/run-clang-format/run-clang-format.py -r common decompiler game goalc test -i
|
|
|
|
# npm install -g prettier
|
2022-06-11 15:32:27 +00:00
|
|
|
- cmd: npx prettier --write ./decompiler/config/jak1_ntsc_black_label/*.jsonc
|
2021-10-17 01:01:23 +00:00
|
|
|
ignore_error: true
|
2021-11-14 03:41:15 +00:00
|
|
|
run-game-headless:
|
|
|
|
cmds:
|
2022-02-14 03:09:34 +00:00
|
|
|
- "{{.GK_BIN_RELEASE_DIR}}/gk -fakeiso -debug -nodisplay"
|
2022-02-07 03:37:12 +00:00
|
|
|
repl-lt:
|
|
|
|
env:
|
|
|
|
OPENGOAL_DECOMP_DIR: "jak1/"
|
|
|
|
cmds:
|
2022-05-06 22:19:37 +00:00
|
|
|
- "{{.GOALC_BIN_RELEASE_DIR}}/goalc --auto-lt"
|
2022-02-12 22:48:50 +00:00
|
|
|
# DECOMPILING
|
2021-05-08 02:56:37 +00:00
|
|
|
decomp:
|
|
|
|
cmds:
|
2022-02-14 03:09:34 +00:00
|
|
|
- '{{.DECOMP_BIN_RELEASE_DIR}}/decompiler "./decompiler/config/jak1_ntsc_black_label.jsonc" "./iso_data" "./decompiler_out"'
|
2021-05-08 02:56:37 +00:00
|
|
|
decomp-clean:
|
|
|
|
cmds:
|
|
|
|
- rm ./decompiler_out/**/*.asm
|
2021-05-09 21:03:58 +00:00
|
|
|
- rm ./decompiler_out/**/*disasm.gc
|
|
|
|
decomp-file:
|
|
|
|
cmds:
|
2021-09-20 01:45:14 +00:00
|
|
|
- python ./scripts/next-decomp-file.py --files "{{.FILES}}"
|
2021-05-09 21:03:58 +00:00
|
|
|
- task: decomp
|
|
|
|
decomp-list:
|
|
|
|
cmds:
|
2021-05-14 00:46:37 +00:00
|
|
|
- python ./scripts/next-decomp-file.py --list "{{.LIST}}"
|
|
|
|
vars:
|
|
|
|
LIST: '{{default "0" .LIST}}'
|
2021-05-15 23:42:23 +00:00
|
|
|
# python -m pip install -U watchdog[watchmedo]
|
|
|
|
decomp-watch:
|
|
|
|
cmds:
|
2021-09-20 01:45:14 +00:00
|
|
|
- watchmedo shell-command --drop --patterns="*.gc;*.jsonc" --recursive --command='task decomp-file FILES="{{.FILES}}"' ./decompiler/config/
|
2022-02-12 22:48:50 +00:00
|
|
|
# TESTS
|
2021-05-26 23:40:12 +00:00
|
|
|
offline-tests:
|
|
|
|
cmds:
|
2022-02-14 03:09:34 +00:00
|
|
|
- '{{.OFFLINETEST_BIN_RELEASE_DIR}}/offline-test "./iso_data/jak1"'
|
2021-06-07 03:01:30 +00:00
|
|
|
add-reference-test:
|
|
|
|
cmds:
|
|
|
|
- task: decomp-file
|
2021-09-20 01:45:14 +00:00
|
|
|
- python ./scripts/add-reference-test.py --file "{{.FILES}}"
|
2021-06-07 03:01:30 +00:00
|
|
|
- task: offline-tests
|
2021-09-07 01:10:19 +00:00
|
|
|
add-reference-test-no-decomp:
|
|
|
|
cmds:
|
2021-09-20 01:45:14 +00:00
|
|
|
- python ./scripts/add-reference-test.py --file "{{.FILES}}"
|
2021-09-07 01:10:19 +00:00
|
|
|
- task: offline-tests
|
2021-05-26 23:40:12 +00:00
|
|
|
update-reference-tests:
|
|
|
|
cmds:
|
2021-07-04 22:25:08 +00:00
|
|
|
- cmd: python ./scripts/default-file-or-folder.py --path failures
|
2022-02-14 03:09:34 +00:00
|
|
|
- cmd: '{{.OFFLINETEST_BIN_RELEASE_DIR}}/offline-test "./iso_data/jak1" --dump-mode'
|
2021-06-07 03:01:30 +00:00
|
|
|
ignore_error: true
|
2021-06-13 01:52:55 +00:00
|
|
|
- python ./scripts/update_decomp_reference.py ./failures ./test/decompiler/reference/
|
2021-05-26 23:40:12 +00:00
|
|
|
- task: offline-tests
|
2021-08-14 01:14:05 +00:00
|
|
|
find-label-types:
|
|
|
|
cmds:
|
2021-09-20 01:45:14 +00:00
|
|
|
- python ./scripts/next-decomp-file.py --files "{{.FILES}}"
|
2021-08-14 01:14:05 +00:00
|
|
|
- task: decomp
|
2021-09-20 01:45:14 +00:00
|
|
|
- python ./scripts/find-label-types.py --file "{{.FILES}}"
|
2021-09-06 18:29:06 +00:00
|
|
|
type-test:
|
|
|
|
cmds:
|
2022-02-14 03:09:34 +00:00
|
|
|
- cmd: '{{.GOALCTEST_BIN_RELEASE_DIR}}/goalc-test --gtest_brief=0 --gtest_filter="*MANUAL_TEST_TypeConsistencyWithBuildFirst*"'
|
2021-12-11 18:27:24 +00:00
|
|
|
ignore_error: true
|
2021-11-24 05:33:10 +00:00
|
|
|
check-gsrc-file:
|
|
|
|
cmds:
|
|
|
|
- python ./scripts/check-gsrc-file.py --files "{{.FILES}}"
|
2022-02-12 22:48:50 +00:00
|
|
|
# TOOLS
|
|
|
|
analyze-ee-memory:
|
|
|
|
cmds:
|
2022-02-14 03:09:34 +00:00
|
|
|
- '{{.MEMDUMP_BIN_RELEASE_DIR}}/memory_dump_tool "{{.FILE}}" ./ > ee-analysis.log'
|
2022-02-12 22:48:50 +00:00
|
|
|
watch-pcsx2:
|
|
|
|
cmds:
|
|
|
|
- watchmedo shell-command --drop --patterns="*.p2s" --recursive --command='task analyze-ee-memory FILE="${watch_src_path}"' "{{.SAVESTATE_DIR}}"
|
|
|
|
vars:
|
|
|
|
SAVESTATE_DIR: '{{default "." .SAVESTATE_DIR}}'
|
2021-09-20 01:45:14 +00:00
|
|
|
update-gsrc:
|
|
|
|
cmds:
|
|
|
|
- python ./scripts/next-decomp-file.py --files "{{.FILES}}"
|
|
|
|
- task: decomp
|
2021-11-24 05:33:10 +00:00
|
|
|
- task: find-label-types
|
2021-09-20 01:45:14 +00:00
|
|
|
- python ./scripts/update-goal-src.py --files "{{.FILES}}"
|
|
|
|
- task: type-test
|
2021-11-24 05:33:10 +00:00
|
|
|
- task: check-gsrc-file
|
2021-10-17 01:01:23 +00:00
|
|
|
cast-repl:
|
|
|
|
cmds:
|
|
|
|
- cmd: python ./scripts/cast-repl.py
|