2020-08-23 19:43:26 +02:00
MAKEFLAGS += --no-builtin-rules
2020-03-17 00:31:30 -04:00
2022-05-01 00:03:22 +01:00
# Ensure the build fails if a piped command fails
SHELL = /bin/bash
.SHELLFLAGS = -o pipefail -c
2020-07-19 21:42:05 +02:00
# Build options can either be changed by modifying the makefile, or by building with 'make SETTING=value'
2024-01-31 17:51:33 +01:00
# currently, GCC is the only supported compiler
COMPILER := gcc
2024-01-05 14:27:19 -08:00
# Target game version. Currently only the following version is supported:
2024-01-31 17:51:33 +01:00
# gc-eu-mq-dbg GameCube Europe/PAL Master Quest Debug
2024-02-04 12:30:03 +01:00
# hackeroot-mq HackerOoT, based on gc-eu-mq-dbg (default)
2024-01-31 17:51:33 +01:00
#
2024-01-28 09:09:03 -08:00
# The following versions are work-in-progress and not yet matching:
# gc-eu-mq GameCube Europe/PAL Master Quest
2024-01-31 17:51:33 +01:00
#
2024-02-04 12:30:03 +01:00
# Note: choosing hackeroot-mq will enable HackerOoT features,
2024-01-31 17:51:33 +01:00
# if another version is chosen, this repo will be like
# zeldaret/main decomp but without the disassembly, decompilation
# and matching tools, including the IDO compiler
2024-02-04 12:30:03 +01:00
VERSION := hackeroot-mq
2024-01-31 17:51:33 +01:00
# Enable optimization flags to use GDB on Ares
ARES_GDB := 1
# Toggle release or debug mode. 1=Release, 0=Debug
# Note: currently only used for HackerOoT
RELEASE := 0
2024-02-04 01:45:13 +01:00
# Valid compression algorithms are 'yaz', 'lzo' and 'aplib'
2024-02-04 12:16:55 +01:00
COMPRESSION ?= yaz
2024-02-04 01:45:13 +01:00
COMPRESSION_TYPE ?= $( shell echo $( COMPRESSION) | tr '[:lower:]' '[:upper:]' )
2024-01-24 15:00:10 -03:00
# Number of threads to extract and compress with
N_THREADS := $( shell nproc)
2024-02-01 21:08:45 +01:00
# Check code syntax with host compiler
RUN_CC_CHECK := 1
2022-02-19 16:50:56 -05:00
CFLAGS ?=
CPPFLAGS ?=
i f e q ( $( COMPILER ) , g c c )
2024-01-31 17:51:33 +01:00
CFLAGS += -DCOMPILER_GCC -DNON_MATCHING -DAVOID_UB
CPPFLAGS += -DCOMPILER_GCC -DNON_MATCHING -DAVOID_UB
e l s e
$( error Unsupported compiler. Please use gcc as the COMPILER variable.)
2022-02-19 16:50:56 -05:00
e n d i f
2020-07-19 21:42:05 +02:00
2022-01-19 18:57:39 -05:00
# Set prefix to mips binutils binaries (mips-linux-gnu-ld => 'mips-linux-gnu-') - Change at your own risk!
# In nearly all cases, not having 'mips-linux-gnu-*' binaries on the PATH is indicative of missing dependencies
2024-04-17 02:46:52 +02:00
# Returns the path to the command $(1) if exists. Otherwise returns an empty string.
find-command = $( shell which $( 1) 2>/dev/null)
i f n e q ( $( call find -command ,mips 64-elf -ld ) , )
MIPS_BINUTILS_PREFIX := mips64-elf-
e l s e i f n e q ( $( call find -command ,mips -n 64-ld ) , )
MIPS_BINUTILS_PREFIX := mips-n64-
e l s e i f n e q ( $( call find -command ,mips 64-ld ) , )
MIPS_BINUTILS_PREFIX := mips64-
e l s e i f n e q ( $( call find -command ,mips -linux -gnu -ld ) , )
MIPS_BINUTILS_PREFIX := mips-linux-gnu-
e l s e i f n e q ( $( call find -command ,mips 64-linux -gnu -ld ) , )
MIPS_BINUTILS_PREFIX := mips64-linux-gnu-
e l s e i f n e q ( $( call find -command ,mips -ld ) , )
MIPS_BINUTILS_PREFIX := mips-
e l s e
$( error Unable to detect a suitable MIPS toolchain installed)
e n d i f
2022-01-19 18:57:39 -05:00
2024-01-05 14:27:19 -08:00
# Version-specific settings
2024-01-28 09:09:03 -08:00
i f e q ( $( VERSION ) , g c - e u - m q )
2024-01-29 07:36:41 -08:00
DEBUG := 0
2024-01-31 17:51:33 +01:00
HACKEROOT := 0
2024-01-28 09:09:03 -08:00
e l s e i f e q ( $( VERSION ) , g c - e u - m q - d b g )
2024-01-29 07:36:41 -08:00
DEBUG := 1
2024-01-31 17:51:33 +01:00
HACKEROOT := 0
2024-02-04 12:30:03 +01:00
e l s e i f e q ( $( VERSION ) , h a c k e r o o t - m q )
2024-01-31 17:51:33 +01:00
HACKEROOT := 1
2024-01-05 14:27:19 -08:00
e l s e
$( error Unsupported version $ ( VERSION ) )
e n d i f
2020-03-17 00:31:30 -04:00
PROJECT_DIR := $( dir $( realpath $( firstword $( MAKEFILE_LIST) ) ) )
2024-01-05 14:27:19 -08:00
BUILD_DIR := build/$( VERSION)
2024-01-28 09:09:03 -08:00
EXPECTED_DIR := expected/$( BUILD_DIR)
2024-02-04 19:59:09 -08:00
BASEROM_DIR := baseroms/$( VERSION)
2024-03-02 04:09:57 +01:00
EXTRACTED_DIR := extracted/$( VERSION)
2024-01-24 16:39:13 -08:00
VENV := .venv
2020-03-17 00:31:30 -04:00
2020-09-21 03:00:28 -04:00
MAKE = make
2024-03-29 08:03:28 -07:00
CPPFLAGS += -P -xc -fno-dollars-in-identifiers
2020-09-21 03:00:28 -04:00
2024-01-31 17:51:33 +01:00
# Set PACKAGE_VERSION define for printing commit hash
i f e q ( $( origin PACKAGE_VERSION ) , u n d e f i n e d )
PACKAGE_VERSION := $( shell git log -1 --pretty= %h | tr -d '\n' )
ifeq ( '$(PACKAGE_VERSION)' , '' )
PACKAGE_VERSION = Unknown version
endif
e n d i f
# Set PACKAGE_AUTHOR define for printing author's git name
i f e q ( $( origin PACKAGE_AUTHOR ) , u n d e f i n e d )
PACKAGE_AUTHOR := $( shell git config --get user.name)
ifeq ( '$(PACKAGE_AUTHOR)' , '' )
PACKAGE_AUTHOR = Unknown author
endif
e n d i f
# Make sure the build reports the correct version
$( shell touch src /boot /build .c )
2024-02-04 12:30:03 +01:00
i f e q ( $( VERSION ) , h a c k e r o o t - m q )
2024-02-02 16:59:44 +01:00
CFLAGS += -DENABLE_HACKEROOT= 1
CPPFLAGS += -DENABLE_HACKEROOT= 1
2024-01-31 17:51:33 +01:00
OPTFLAGS := -Os
ifeq ( $( RELEASE) ,1)
2024-02-02 16:59:44 +01:00
CFLAGS += -DRELEASE_ROM= 1 -DOOT_DEBUG= 0
CPPFLAGS += -DRELEASE_ROM= 1 -DOOT_DEBUG= 0
2024-01-31 17:51:33 +01:00
else
2024-02-02 16:59:44 +01:00
CFLAGS += -DRELEASE_ROM= 0 -DOOT_DEBUG= 1
CPPFLAGS += -DRELEASE_ROM= 0 -DOOT_DEBUG= 1
2024-01-31 17:51:33 +01:00
endif
2024-01-29 09:20:54 -08:00
e l s e
2024-01-31 17:51:33 +01:00
ifeq ( $( DEBUG) ,1)
CFLAGS += -DOOT_DEBUG= 1
CPPFLAGS += -DOOT_DEBUG= 1
OPTFLAGS := -O2
else
CFLAGS += -DNDEBUG -DOOT_DEBUG= 0
CPPFLAGS += -DNDEBUG -DOOT_DEBUG= 0
OPTFLAGS := -O2 -g3
endif
CFLAGS += -DENABLE_HACKEROOT= 0
CPPFLAGS += -DENABLE_HACKEROOT= 0
e n d i f
# Override optimization flags if using GDB
i f e q ( $( ARES_GDB ) , 1 )
OPTFLAGS := -Og -ggdb3
2024-01-29 09:20:54 -08:00
e n d i f
2024-01-31 17:51:33 +01:00
# Define author and package version for every OoT version
# Note: this won't be used if not using HackerOoT
2024-02-04 12:16:55 +01:00
CFLAGS += -DPACKAGE_AUTHOR= '$(PACKAGE_AUTHOR)' -DPACKAGE_VERSION= '$(PACKAGE_VERSION)' -DCOMPRESS_$( COMPRESSION_TYPE) = 1
CPPFLAGS += -DPACKAGE_AUTHOR= '$(PACKAGE_AUTHOR)' -DPACKAGE_VERSION= '$(PACKAGE_VERSION)' -DCOMPRESS_$( COMPRESSION_TYPE) = 1
2024-01-31 17:51:33 +01:00
OPTFLAGS += -ffast-math -fno-unsafe-math-optimizations
2020-09-21 03:00:28 -04:00
i f e q ( $( OS ) , W i n d o w s _ N T )
2021-01-20 20:46:25 +01:00
DETECTED_OS = windows
2020-09-21 03:00:28 -04:00
e l s e
UNAME_S := $( shell uname -s)
ifeq ( $( UNAME_S) ,Linux)
DETECTED_OS = linux
endif
ifeq ( $( UNAME_S) ,Darwin)
DETECTED_OS = macos
MAKE = gmake
endif
e n d i f
2024-04-20 02:23:18 +02:00
# Verbose toggle
V := @
i f e q ( V E R B O S E , 1 )
V =
e n d i f
# Colors
NO_COL := \0 33[ 0m
GREEN := \0 33[ 0; 32m
BLUE := \0 33[ 0; 36m
YELLOW := \0 33[ 0; 33m
2024-04-20 02:28:11 +02:00
BLINK := \0 33[ 32; 5m
2024-04-20 02:23:18 +02:00
PRINT := printf
# Generic print function for make rules
d e f i n e p r i n t
$( V) echo -e " $( GREEN) $( 1) $( YELLOW) $( 2) $( GREEN) -> $( BLUE) $( 3) $( NO_COL) "
e n d e f
2020-03-17 00:31:30 -04:00
#### Tools ####
2022-01-19 18:57:39 -05:00
i f n e q ( $( shell type $ ( MIPS_BINUTILS_PREFIX ) ld >/dev /null 2>/dev /null ; echo $ $ ?) , 0 )
2023-03-20 15:07:18 +00:00
$( error Unable to find $( MIPS_BINUTILS_PREFIX) ld. Please install or build MIPS binutils, commonly mips-linux-gnu. ( or set MIPS_BINUTILS_PREFIX if your MIPS binutils install uses another prefix) )
2020-03-17 00:31:30 -04:00
e n d i f
2022-02-19 16:50:56 -05:00
# Detect compiler and set variables appropriately.
i f e q ( $( COMPILER ) , g c c )
CC := $( MIPS_BINUTILS_PREFIX) gcc
e l s e
2024-01-31 17:51:33 +01:00
$( error Unsupported compiler . Please use gcc as the COMPILER variable .)
2020-03-17 00:31:30 -04:00
e n d i f
2024-01-09 18:49:12 +01:00
AS := $( MIPS_BINUTILS_PREFIX) as
LD := $( MIPS_BINUTILS_PREFIX) ld
OBJCOPY := $( MIPS_BINUTILS_PREFIX) objcopy
OBJDUMP := $( MIPS_BINUTILS_PREFIX) objdump
2024-01-24 15:00:10 -03:00
NM := $( MIPS_BINUTILS_PREFIX) nm
2024-01-09 18:49:12 +01:00
N64_EMULATOR ?=
2020-03-17 00:31:30 -04:00
2024-03-02 04:09:57 +01:00
INC := -Iinclude -Iinclude/libc -Isrc -I$( BUILD_DIR) -I. -I$( EXTRACTED_DIR)
2021-09-18 09:07:51 -03:00
2020-03-23 23:15:45 +01:00
# Check code syntax with host compiler
2022-06-16 02:15:44 +02:00
CHECK_WARNINGS := -Wall -Wextra -Wno-format-security -Wno-unknown-pragmas -Wno-unused-parameter -Wno-unused-variable -Wno-missing-braces
2020-03-17 00:31:30 -04:00
2024-03-29 08:03:28 -07:00
# The `cpp` command behaves differently on macOS (it behaves as if
# `-traditional-cpp` was passed) so we use `gcc -E` instead.
CPP := gcc -E
2020-03-17 00:31:30 -04:00
MKLDSCRIPT := tools/mkldscript
2021-11-30 23:29:09 +00:00
MKDMADATA := tools/mkdmadata
2020-03-17 00:31:30 -04:00
ELF2ROM := tools/elf2rom
2021-01-01 23:24:29 -05:00
ZAPD := tools/ZAPD/ZAPD.out
2022-02-06 19:40:26 +00:00
FADO := tools/fado/fado.elf
2024-01-24 16:39:13 -08:00
PYTHON ?= $( VENV) /bin/python3
2024-02-04 13:04:13 +01:00
FLIPS := tools/Flips/flips
2020-03-17 00:31:30 -04:00
2024-01-05 14:27:19 -08:00
# Command to replace path variables in the spec file. We can't use the C
# preprocessor for this because it won't substitute inside string literals.
SPEC_REPLACE_VARS := sed -e 's|$$(BUILD_DIR)|$(BUILD_DIR)|g'
2022-05-01 23:14:44 +01:00
ASFLAGS := -march= vr4300 -32 -no-pad-sections -Iinclude
2020-03-17 00:31:30 -04:00
2022-02-19 16:50:56 -05:00
i f e q ( $( COMPILER ) , g c c )
2024-02-29 20:11:54 +00:00
CFLAGS += -G 0 -nostdinc $( INC) -march= vr4300 -mfix4300 -mabi= 32 -mno-abicalls -mdivide-breaks -fno-PIC -fno-common -ffreestanding -fbuiltin -fno-builtin-sinf -fno-builtin-cosf $( CHECK_WARNINGS) -funsigned-char
2022-02-19 16:50:56 -05:00
MIPS_VERSION := -mips3
2024-02-01 21:08:45 +01:00
RUN_CC_CHECK := 0
2020-03-17 00:31:30 -04:00
e n d i f
2022-05-20 07:27:54 +01:00
OBJDUMP_FLAGS := -d -r -z -Mreg-names= 32
2020-03-17 00:31:30 -04:00
#### Files ####
# ROM image
2024-02-04 12:30:03 +01:00
i f e q ( $( VERSION ) , h a c k e r o o t - m q )
ROM := $( BUILD_DIR) /$( VERSION) .z64
e l s e
ROM := $( BUILD_DIR) /oot-$( VERSION) .z64
e n d i f
2024-02-06 03:18:50 +01:00
ROMC := $( ROM:.z64= -compressed-$( COMPRESSION) .z64)
2024-02-03 17:40:34 +01:00
WAD := $( ROM:.z64= .wad)
2024-02-04 13:04:13 +01:00
BPS := $( ROM:.z64= .bps)
2024-02-02 13:34:20 -08:00
ELF := $( ROM:.z64= .elf)
MAP := $( ROM:.z64= .map)
LDSCRIPT := $( ROM:.z64= .ld)
2020-03-17 00:31:30 -04:00
# description of ROM segments
SPEC := spec
2024-02-04 13:04:13 +01:00
# Baserom to use when creating BPS patches
BASEROM_PATCH ?= baseroms/$( VERSION) /baserom.z64
2024-01-31 17:51:33 +01:00
i f e q ( $( COMPILER ) , g c c )
2020-05-01 03:49:35 +02:00
SRC_DIRS := $( shell find src -type d)
2022-02-19 16:50:56 -05:00
e n d i f
z_message_PAL, message_data_static and surrounding doc (#996)
* Initial progress on z_message_PAL, very messy
* Fix merge
* Some more progress
* Fix merge
* More z_message_PAL
* Small progress
* More small progress
* message_data_static files OK
* Prepare z_message_tables
* Matched another function, small updates
* Attempt to use asm-processor static-symbols branch
* Refactor text id declarations
* Begin large text codes parser function
* Fix merge
* Refactor done
* Build OK, add color and highscore names
* Remove encoded text headers and automatically encode during build
* Fix kanfont
* Various cleanups
* DISP macros
* Another match aside data
* Further progress
* Small improvements
* Deduplicate magic values for text control codes, small improvements
* Tiny progress
* Minor cleanups
* Clean up z_message_PAL comment
* Progress on large functions
* Further progress on large functions
* Changes to mkldscript to link .data in the .rodata section
* data OK
* Few improvements
* Use gDPLoadTextureBlock macros where appropriate
* rm z_message_tables, progress on large functions
* 2 more matches
* Improvements
* Small progress
* More progress on big function
* progress
* match func_80107980
* match Message_Update
* match func_8010BED8
* done
* Progress on remaining large functions
* Small progress on largest function
* Another match, extract text and move to assets, improve text build system
* Small nonmatchings improvements
* docs wip
* Largest function maybe equivalent
* Fix merge
* Document do_action values, largest function is almost instruction-matching
* Rename NAVI do_action to NONE, as that appears to be how that value is used in practice
* Fix merge
* one match
* Last function is instruction-matching
* Fix
* Improvements thanks to engineer124
* Stack matched thanks to petrie911, now just a/v/low t regalloc issues, some cleanup
* More variables labeled, use text state enum everywhere
* More labels and names
* Fix
* Actor_IsTalking -> Actor_TalkRequested
* Match func_8010C39C and remove unused asm
* More docs
* Mostly ocarina related docs
* All msgModes named
* Fix assetclean
* Cleanup
* Extraction fixes and headers
* Suggestions
* Review suggestions
* Change text extraction again, only extract if the headers do not already exist
* Fix
* Use ast for charmap, fix assetclean for real this time
* Review suggestions
* BGM ids and ran formatter
* Review comments
* rename include_readonly to include_data_with_rodata
* Remove leading 0s in number directives
* Review suggestions for message_data_static
* textbox pos enum comments, rename several enum names from Message to TextBox
Co-authored-by: Thar0 <maximilianc64@gmail.com>
Co-authored-by: Zelllll <56516451+Zelllll@users.noreply.github.com>
Co-authored-by: petrie911 <pmontag@DESKTOP-LG8A167.localdomain>
Co-authored-by: Roman971 <romanlasnier@hotmail.com>
2021-11-23 01:20:30 +00:00
ASSET_BIN_DIRS := $( shell find assets/* -type d -not -path "assets/xml*" -not -path "assets/text" )
2020-12-26 06:39:52 -05:00
ASSET_FILES_XML := $( foreach dir,$( ASSET_BIN_DIRS) ,$( wildcard $( dir) /*.xml) )
ASSET_FILES_BIN := $( foreach dir,$( ASSET_BIN_DIRS) ,$( wildcard $( dir) /*.bin) )
ASSET_FILES_OUT := $( foreach f,$( ASSET_FILES_XML:.xml= .c) ,$f ) \
2024-01-05 14:27:19 -08:00
$( foreach f,$( ASSET_FILES_BIN:.bin= .bin.inc.c) ,$( BUILD_DIR) /$f ) \
$( foreach f,$( wildcard assets/text/*.c) ,$( BUILD_DIR) /$( f:.c= .o) )
2020-12-26 06:39:52 -05:00
2022-06-03 21:33:18 +01:00
UNDECOMPILED_DATA_DIRS := $( shell find data -type d)
2024-03-04 16:06:26 -08:00
BASEROM_BIN_FILES := $( wildcard $( EXTRACTED_DIR) /baserom/*)
2024-01-28 09:09:03 -08:00
2020-05-01 03:49:35 +02:00
# source files
2022-10-04 12:36:25 +02:00
C_FILES := $( filter-out %.inc.c,$( foreach dir,$( SRC_DIRS) $( ASSET_BIN_DIRS) ,$( wildcard $( dir) /*.c) ) )
2022-06-03 21:33:18 +01:00
S_FILES := $( foreach dir,$( SRC_DIRS) $( UNDECOMPILED_DATA_DIRS) ,$( wildcard $( dir) /*.s) )
2024-01-05 14:27:19 -08:00
O_FILES := $( foreach f,$( S_FILES:.s= .o) ,$( BUILD_DIR) /$f ) \
$( foreach f,$( C_FILES:.c= .o) ,$( BUILD_DIR) /$f ) \
2024-01-24 15:00:10 -03:00
$( foreach f,$( BASEROM_BIN_FILES) ,$( BUILD_DIR) /baserom/$( notdir $f ) .o)
2020-12-26 06:39:52 -05:00
2024-01-05 14:27:19 -08:00
OVL_RELOC_FILES := $( shell $( CPP) $( CPPFLAGS) $( SPEC) | $( SPEC_REPLACE_VARS) | grep -o '[^"]*_reloc.o' )
2022-02-06 19:40:26 +00:00
2021-05-02 22:21:27 +02:00
# Automatic dependency files
2022-02-06 19:40:26 +00:00
# (Only asm_processor dependencies and reloc dependencies are handled for now)
DEP_FILES := $( O_FILES:.o= .asmproc.d) $( OVL_RELOC_FILES:.o= .d)
2021-05-02 22:21:27 +02:00
2021-05-15 14:14:51 -04:00
TEXTURE_FILES_PNG := $( foreach dir,$( ASSET_BIN_DIRS) ,$( wildcard $( dir) /*.png) )
2021-04-02 19:07:29 -03:00
TEXTURE_FILES_JPG := $( foreach dir,$( ASSET_BIN_DIRS) ,$( wildcard $( dir) /*.jpg) )
2024-01-05 14:27:19 -08:00
TEXTURE_FILES_OUT := $( foreach f,$( TEXTURE_FILES_PNG:.png= .inc.c) ,$( BUILD_DIR) /$f ) \
$( foreach f,$( TEXTURE_FILES_JPG:.jpg= .jpg.inc.c) ,$( BUILD_DIR) /$f ) \
2020-03-17 00:31:30 -04:00
# create build directories
2024-03-02 04:09:57 +01:00
$( shell mkdir -p $ ( BUILD_DIR ) /baserom $ ( EXTRACTED_DIR ) /text $ ( BUILD_DIR ) /assets /text $ ( foreach dir ,$ ( SRC_DIRS ) $ ( UNDECOMPILED_DATA_DIRS ) $ ( ASSET_BIN_DIRS ) ,$ ( BUILD_DIR ) /$ ( dir ) ) )
2020-03-17 00:31:30 -04:00
2024-01-31 17:51:33 +01:00
i f e q ( $( COMPILER ) , g c c )
2024-02-29 20:11:54 +00:00
# Note that if adding additional assets directories for modding reasons these flags must also be used there
2024-03-05 16:35:42 +01:00
$( BUILD_DIR) /assets/%.o: CFLAGS += -fno-zero-initialized-in-bss -fno-toplevel-reorder
$( BUILD_DIR) /src/%.o: CFLAGS += -fexec-charset= utf-8
2024-01-31 17:51:33 +01:00
$( BUILD_DIR) /src/libultra/libc/ll.o: OPTFLAGS := -Ofast
2024-03-05 16:35:42 +01:00
$( BUILD_DIR) /src/overlays/%.o: CFLAGS += -fno-merge-constants -mno-explicit-relocs -mno-split-addresses
2024-01-05 14:27:19 -08:00
2024-01-31 17:51:33 +01:00
$( BUILD_DIR) /src/overlays/actors/ovl_Item_Shield/%.o: OPTFLAGS := -O2
$( BUILD_DIR) /src/overlays/actors/ovl_En_Part/%.o: OPTFLAGS := -O2
$( BUILD_DIR) /src/overlays/actors/ovl_Item_B_Heart/%.o: OPTFLAGS := -O0
$( BUILD_DIR) /src/overlays/actors/ovl_Bg_Mori_Hineri/%.o: OPTFLAGS := -O0
2022-02-19 16:50:56 -05:00
e n d i f
2020-04-16 20:08:23 +02:00
2020-03-17 00:31:30 -04:00
#### Main Targets ###
2024-04-18 19:37:37 +02:00
all : rom
2024-01-24 16:39:13 -08:00
2024-04-18 19:37:37 +02:00
rom :
2024-04-21 19:59:53 +02:00
$( call print,Building the rom...)
$( V) python3 tools/mod_assets.py
$( V) $( MAKE) $( ROM)
2024-01-24 15:00:10 -03:00
2024-02-06 03:18:50 +01:00
compress :
2024-04-20 02:23:18 +02:00
$( call print,Compressing the rom...)
2024-02-06 03:18:50 +01:00
# make sure z_std_dma.c and spec are up-to-date
2024-04-20 02:23:18 +02:00
$( V) $( shell touch spec)
$( V) $( shell touch src/boot/z_std_dma.c)
$( V) $( MAKE) $( ROMC)
$( call print,Success!)
2024-01-31 17:51:33 +01:00
wad :
2024-04-20 02:23:18 +02:00
$( call print,Patching WAD...)
2024-02-04 01:45:13 +01:00
i f e q ( "$(wildcard baseroms/$(VERSION)/common-key.bin)" , "" )
2024-01-31 17:51:33 +01:00
$( error Please provide the common-key.bin file.)
2020-07-19 21:42:05 +02:00
e n d i f
2024-04-20 02:23:18 +02:00
$( V) $( MAKE) compress CFLAGS = " -DCONSOLE_WIIVC $( CFLAGS) -fno-reorder-blocks -fno-optimize-sibling-calls " CPPFLAGS = " -DCONSOLE_WIIVC $( CPPFLAGS) "
$( V) tools/gzinject/gzinject -a inject -r 1 -k baseroms/$( VERSION) /common-key.bin -w baseroms/$( VERSION) /basewad.wad -m $( ROMC) -o $( WAD) -t "HackerOoT" -i NHOE -p tools/gzinject/patches/NACE.gzi -p tools/gzinject/patches/gz_default_remap.gzi
$( V) $( RM) -r wadextract/
$( call print,Success!)
2020-03-17 00:31:30 -04:00
clean :
2024-04-20 02:23:18 +02:00
$( V) $( RM) -r $( BUILD_DIR)
$( call print,Success!)
2020-03-17 00:31:30 -04:00
2021-05-17 13:50:19 -04:00
assetclean :
2024-04-20 02:23:18 +02:00
$( V) $( RM) -r $( ASSET_BIN_DIRS)
$( V) $( RM) -r $( EXTRACTED_DIR)
$( V) $( RM) -r $( BUILD_DIR) /assets
$( V) $( RM) -r .extracted-assets.json
$( call print,Success!)
2021-05-17 13:50:19 -04:00
2024-03-04 09:26:04 -08:00
distclean : assetclean
2024-04-20 02:23:18 +02:00
$( V) $( RM) -r extracted/
$( V) $( RM) -r build/
$( V) $( MAKE) -C tools distclean
$( V) $( RM) -r F3DEX3/F3DEX3.code F3DEX3/F3DEX3.data
$( call print,Success!)
2021-03-14 13:07:46 -03:00
2024-01-24 16:39:13 -08:00
venv :
2024-01-27 16:40:29 -08:00
# Create the virtual environment if it doesn't exist.
# Delete the virtual environment directory if creation fails.
2024-04-20 02:23:18 +02:00
$( call print,Preparing the virtual environment...)
$( V) test -d $( VENV) || python3 -m venv $( VENV) || { rm -rf $( VENV) ; false; }
$( V) $( PYTHON) -m pip install -U pip
$( V) $( PYTHON) -m pip install -U -r requirements.txt
$( call print,Success!)
2024-01-24 16:39:13 -08:00
setup : venv
2024-04-20 02:23:18 +02:00
$( call print,Setup in progress...)
$( V) $( MAKE) -C tools
$( call print,Tools: Done!)
$( V) $( PYTHON) tools/decompress_baserom.py $( VERSION)
$( call print,Decompressing baserom: Done!)
$( V) $( PYTHON) tools/extract_baserom.py $( BASEROM_DIR) /baserom-decompressed.z64 -o $( EXTRACTED_DIR) /baserom --dmadata-start ` cat $( BASEROM_DIR) /dmadata_start.txt` --dmadata-names $( BASEROM_DIR) /dmadata_names.txt
$( V) $( PYTHON) tools/msgdis.py --oot-version $( VERSION) --text-out $( EXTRACTED_DIR) /text/message_data.h --staff-text-out $( EXTRACTED_DIR) /text/message_data_staff.h
2024-02-04 19:59:09 -08:00
# TODO: for now, we only extract assets from the Debug ROM
2024-02-06 23:35:19 +01:00
i f n e q ( $( VERSION ) , g c - e u - m q )
2024-04-20 02:23:18 +02:00
$( V) $( PYTHON) extract_assets.py -j$( N_THREADS) -v $( VERSION)
2024-01-28 09:09:03 -08:00
e n d i f
2024-04-20 02:23:18 +02:00
$( call print,Extracting files: Done!)
2024-02-04 14:29:13 +01:00
$( MAKE) f3dex3
2024-04-20 02:23:18 +02:00
$( call print,Success!)
2024-04-16 14:49:57 +02:00
i f e q ( $( VERSION ) , h a c k e r o o t - m q )
2024-04-16 14:45:30 +02:00
# TODO: proper fix (for .s files)
cp baseroms/hackeroot-mq/baserom-decompressed.z64 baseroms/gc-eu-mq-dbg/baserom-decompressed.z64
e n d i f
2020-03-17 00:31:30 -04:00
2024-04-21 19:59:53 +02:00
run : rom
2024-01-09 18:49:12 +01:00
i f e q ( $( N 64_EMULATOR ) , )
$( error Emulator path not set. Set N64_EMULATOR in the Makefile or define it as an environment variable)
2023-08-28 18:48:52 -04:00
e n d i f
2024-04-21 19:59:53 +02:00
$( N64_EMULATOR) $( ROM)
2020-12-21 16:14:25 -08:00
2024-02-04 13:04:13 +01:00
patch :
2024-04-20 02:23:18 +02:00
$( call print,Creating BPS patch...)
$( V) $( FLIPS) --create --bps $( BASEROM_PATCH) $( ROM) $( BPS)
$( call print,Success!)
2022-02-06 19:40:26 +00:00
2024-02-04 14:29:13 +01:00
f3dex3 :
2024-04-20 02:23:18 +02:00
$( call print,Patching the microcode...)
$( V) $( PYTHON) tools/data_extractor.py --start 0xBCD0F0 --size 0x1630 --input $( BASEROM_DIR) /baserom-decompressed.z64 --output F3DEX3/f3dzex2.code
$( V) $( PYTHON) tools/data_extractor.py --start 0xBCE720 --size 0x420 --input $( BASEROM_DIR) /baserom-decompressed.z64 --output F3DEX3/f3dzex2.data
$( V) $( FLIPS) --apply F3DEX3/F3DEX3.code.bps F3DEX3/f3dzex2.code F3DEX3/F3DEX3.code
$( V) $( FLIPS) --apply F3DEX3/F3DEX3.data.bps F3DEX3/f3dzex2.data F3DEX3/F3DEX3.data
$( V) $( RM) -r F3DEX3/f3dzex2.code F3DEX3/f3dzex2.data
$( call print,Success!)
2024-02-04 14:29:13 +01:00
.PHONY : all rom compress clean assetclean distclean venv setup run wad patch f 3dex 3
2024-01-24 15:00:10 -03:00
.DEFAULT_GOAL := rom
2020-12-21 16:14:25 -08:00
2020-03-17 00:31:30 -04:00
#### Various Recipes ####
2022-02-06 19:40:26 +00:00
$(ROM) : $( ELF )
2024-04-20 02:23:18 +02:00
$( V) $( ELF2ROM) -cic 6105 $< $@
@$( PRINT) " ${ BLINK } Build succeeded.\n $( NO_COL) "
@$( PRINT) " ==== Build Options ==== $( NO_COL) \n "
@$( PRINT) " ${ GREEN } OoT Version: $( BLUE) $( VERSION) $( NO_COL) \n "
@$( PRINT) " ${ GREEN } Code Version: $( BLUE) $( PACKAGE_VERSION) $( NO_COL) \n "
2022-02-06 19:40:26 +00:00
2024-01-24 15:00:10 -03:00
$(ROMC) : $( ROM ) $( ELF ) $( BUILD_DIR ) /compress_ranges .txt
2024-02-04 01:45:13 +01:00
i f e q ( $( COMPRESSION ) , y a z )
2024-04-20 02:23:18 +02:00
$( V) $( PYTHON) tools/compress.py --in $( ROM) --out $@ --dmadata-start ` ./tools/dmadata_range.sh $( NM) $( ELF) ` --compress ` cat $( BUILD_DIR) /compress_ranges.txt` --threads $( N_THREADS)
2024-02-04 01:45:13 +01:00
e l s e
2024-04-20 02:23:18 +02:00
$( V) $( PYTHON) tools/z64compress_wrapper.py --codec $( COMPRESSION) --cache $( BUILD_DIR) /cache --threads $( N_THREADS) $< $@ $( ELF) $( BUILD_DIR) /$( SPEC)
2024-02-04 01:45:13 +01:00
e n d i f
2024-04-20 02:23:18 +02:00
$( V) $( PYTHON) -m ipl3checksum sum --cic 6105 --update $@
2024-01-24 15:00:10 -03:00
2024-02-02 13:34:20 -08:00
$(ELF) : $( TEXTURE_FILES_OUT ) $( ASSET_FILES_OUT ) $( O_FILES ) $( OVL_RELOC_FILES ) $( LDSCRIPT ) $( BUILD_DIR ) /undefined_syms .txt
2024-04-20 02:23:18 +02:00
$( V) $( LD) -T $( LDSCRIPT) -T $( BUILD_DIR) /undefined_syms.txt --no-check-sections --accept-unknown-input-arch --emit-relocs -Map $( MAP) -o $@
2022-02-06 19:40:26 +00:00
2023-02-26 17:26:07 +01:00
## Order-only prerequisites
2022-02-06 19:40:26 +00:00
# These ensure e.g. the O_FILES are built before the OVL_RELOC_FILES.
# The intermediate phony targets avoid quadratically-many dependencies between the targets and prerequisites.
o_files : $( O_FILES )
$(OVL_RELOC_FILES) : | o_files
asset_files : $( TEXTURE_FILES_OUT ) $( ASSET_FILES_OUT )
$(O_FILES) : | asset_files
.PHONY : o_files asset_files
2024-01-05 14:27:19 -08:00
$(BUILD_DIR)/$(SPEC) : $( SPEC )
2024-04-20 02:23:18 +02:00
$( call print,Compiling:,$<,$@ )
$( V) $( CPP) $( CPPFLAGS) $< | $( SPEC_REPLACE_VARS) > $@
2022-02-06 19:40:26 +00:00
2024-02-02 13:34:20 -08:00
$(LDSCRIPT) : $( BUILD_DIR ) /$( SPEC )
2024-04-20 02:23:18 +02:00
$( call print,Linking:,$<,$@ )
$( V) $( MKLDSCRIPT) $< $@
2022-02-06 19:40:26 +00:00
2024-01-05 14:27:19 -08:00
$(BUILD_DIR)/undefined_syms.txt : undefined_syms .txt
2024-04-20 02:23:18 +02:00
$( call print,Compiling:,$<,$@ )
$( V) $( CPP) $( CPPFLAGS) $< > $@
2022-02-06 19:40:26 +00:00
2024-03-04 16:06:26 -08:00
$(BUILD_DIR)/baserom/%.o : $( EXTRACTED_DIR ) /baserom /%
2024-04-20 02:23:18 +02:00
$( V) $( OBJCOPY) -I binary -O elf32-big $< $@
2020-03-17 00:31:30 -04:00
2024-01-05 14:27:19 -08:00
$(BUILD_DIR)/data/%.o : data /%.s
2024-04-20 02:23:18 +02:00
$( call print,Relocating:,$<,$@ )
$( V) $( AS) $( ASFLAGS) $< -o $@
2020-03-17 00:31:30 -04:00
2024-02-04 15:11:29 +01:00
$(BUILD_DIR)/data/rsp.rodata.f3dex3.o : F 3DEX 3/F 3DEX 3.code F 3DEX 3/F 3DEX 3.data
2024-03-02 04:09:57 +01:00
$(BUILD_DIR)/assets/text/%.enc.h : assets /text /%.h $( EXTRACTED_DIR ) /text /%.h assets /text /charmap .txt
2024-04-20 02:23:18 +02:00
$( call print,Compiling:,$<,$@ )
$( V) $( CPP) $( CPPFLAGS) -I$( EXTRACTED_DIR) $< | $( PYTHON) tools/msgenc.py - --output $@ --charmap assets/text/charmap.txt
z_message_PAL, message_data_static and surrounding doc (#996)
* Initial progress on z_message_PAL, very messy
* Fix merge
* Some more progress
* Fix merge
* More z_message_PAL
* Small progress
* More small progress
* message_data_static files OK
* Prepare z_message_tables
* Matched another function, small updates
* Attempt to use asm-processor static-symbols branch
* Refactor text id declarations
* Begin large text codes parser function
* Fix merge
* Refactor done
* Build OK, add color and highscore names
* Remove encoded text headers and automatically encode during build
* Fix kanfont
* Various cleanups
* DISP macros
* Another match aside data
* Further progress
* Small improvements
* Deduplicate magic values for text control codes, small improvements
* Tiny progress
* Minor cleanups
* Clean up z_message_PAL comment
* Progress on large functions
* Further progress on large functions
* Changes to mkldscript to link .data in the .rodata section
* data OK
* Few improvements
* Use gDPLoadTextureBlock macros where appropriate
* rm z_message_tables, progress on large functions
* 2 more matches
* Improvements
* Small progress
* More progress on big function
* progress
* match func_80107980
* match Message_Update
* match func_8010BED8
* done
* Progress on remaining large functions
* Small progress on largest function
* Another match, extract text and move to assets, improve text build system
* Small nonmatchings improvements
* docs wip
* Largest function maybe equivalent
* Fix merge
* Document do_action values, largest function is almost instruction-matching
* Rename NAVI do_action to NONE, as that appears to be how that value is used in practice
* Fix merge
* one match
* Last function is instruction-matching
* Fix
* Improvements thanks to engineer124
* Stack matched thanks to petrie911, now just a/v/low t regalloc issues, some cleanup
* More variables labeled, use text state enum everywhere
* More labels and names
* Fix
* Actor_IsTalking -> Actor_TalkRequested
* Match func_8010C39C and remove unused asm
* More docs
* Mostly ocarina related docs
* All msgModes named
* Fix assetclean
* Cleanup
* Extraction fixes and headers
* Suggestions
* Review suggestions
* Change text extraction again, only extract if the headers do not already exist
* Fix
* Use ast for charmap, fix assetclean for real this time
* Review suggestions
* BGM ids and ran formatter
* Review comments
* rename include_readonly to include_data_with_rodata
* Remove leading 0s in number directives
* Review suggestions for message_data_static
* textbox pos enum comments, rename several enum names from Message to TextBox
Co-authored-by: Thar0 <maximilianc64@gmail.com>
Co-authored-by: Zelllll <56516451+Zelllll@users.noreply.github.com>
Co-authored-by: petrie911 <pmontag@DESKTOP-LG8A167.localdomain>
Co-authored-by: Roman971 <romanlasnier@hotmail.com>
2021-11-23 01:20:30 +00:00
2023-10-20 18:14:52 +01:00
# Dependencies for files including message data headers
# TODO remove when full header dependencies are used.
2024-01-05 14:27:19 -08:00
$(BUILD_DIR)/assets/text/fra_message_data_static.o : $( BUILD_DIR ) /assets /text /message_data .enc .h
$(BUILD_DIR)/assets/text/ger_message_data_static.o : $( BUILD_DIR ) /assets /text /message_data .enc .h
$(BUILD_DIR)/assets/text/nes_message_data_static.o : $( BUILD_DIR ) /assets /text /message_data .enc .h
$(BUILD_DIR)/assets/text/staff_message_data_static.o : $( BUILD_DIR ) /assets /text /message_data_staff .enc .h
$(BUILD_DIR)/src/code/z_message_PAL.o : $( BUILD_DIR ) /assets /text /message_data .enc .h $( BUILD_DIR ) /assets /text /message_data_staff .enc .h
z_message_PAL, message_data_static and surrounding doc (#996)
* Initial progress on z_message_PAL, very messy
* Fix merge
* Some more progress
* Fix merge
* More z_message_PAL
* Small progress
* More small progress
* message_data_static files OK
* Prepare z_message_tables
* Matched another function, small updates
* Attempt to use asm-processor static-symbols branch
* Refactor text id declarations
* Begin large text codes parser function
* Fix merge
* Refactor done
* Build OK, add color and highscore names
* Remove encoded text headers and automatically encode during build
* Fix kanfont
* Various cleanups
* DISP macros
* Another match aside data
* Further progress
* Small improvements
* Deduplicate magic values for text control codes, small improvements
* Tiny progress
* Minor cleanups
* Clean up z_message_PAL comment
* Progress on large functions
* Further progress on large functions
* Changes to mkldscript to link .data in the .rodata section
* data OK
* Few improvements
* Use gDPLoadTextureBlock macros where appropriate
* rm z_message_tables, progress on large functions
* 2 more matches
* Improvements
* Small progress
* More progress on big function
* progress
* match func_80107980
* match Message_Update
* match func_8010BED8
* done
* Progress on remaining large functions
* Small progress on largest function
* Another match, extract text and move to assets, improve text build system
* Small nonmatchings improvements
* docs wip
* Largest function maybe equivalent
* Fix merge
* Document do_action values, largest function is almost instruction-matching
* Rename NAVI do_action to NONE, as that appears to be how that value is used in practice
* Fix merge
* one match
* Last function is instruction-matching
* Fix
* Improvements thanks to engineer124
* Stack matched thanks to petrie911, now just a/v/low t regalloc issues, some cleanup
* More variables labeled, use text state enum everywhere
* More labels and names
* Fix
* Actor_IsTalking -> Actor_TalkRequested
* Match func_8010C39C and remove unused asm
* More docs
* Mostly ocarina related docs
* All msgModes named
* Fix assetclean
* Cleanup
* Extraction fixes and headers
* Suggestions
* Review suggestions
* Change text extraction again, only extract if the headers do not already exist
* Fix
* Use ast for charmap, fix assetclean for real this time
* Review suggestions
* BGM ids and ran formatter
* Review comments
* rename include_readonly to include_data_with_rodata
* Remove leading 0s in number directives
* Review suggestions for message_data_static
* textbox pos enum comments, rename several enum names from Message to TextBox
Co-authored-by: Thar0 <maximilianc64@gmail.com>
Co-authored-by: Zelllll <56516451+Zelllll@users.noreply.github.com>
Co-authored-by: petrie911 <pmontag@DESKTOP-LG8A167.localdomain>
Co-authored-by: Roman971 <romanlasnier@hotmail.com>
2021-11-23 01:20:30 +00:00
2024-01-05 14:27:19 -08:00
$(BUILD_DIR)/assets/%.o : assets /%.c
2024-04-20 02:23:18 +02:00
$( call print,Compiling:,$<,$@ )
$( V) $( CC) -c $( CFLAGS) $( MIPS_VERSION) $( OPTFLAGS) -o $@ $<
$( V) $( OBJCOPY) -O binary $@ $@ .bin
2020-03-17 00:31:30 -04:00
2024-01-05 14:27:19 -08:00
$(BUILD_DIR)/src/%.o : src /%.s
2024-04-20 02:23:18 +02:00
$( call print,Compiling:,$<,$@ )
$( V) $( CPP) $( CPPFLAGS) -Iinclude $< | $( AS) $( ASFLAGS) -o $@
2022-06-03 21:33:18 +01:00
2024-01-24 15:00:10 -03:00
$(BUILD_DIR)/dmadata_table_spec.h $(BUILD_DIR)/compress_ranges.txt : $( BUILD_DIR ) /$( SPEC )
2024-04-20 02:23:18 +02:00
$( V) $( MKDMADATA) $< $( BUILD_DIR) /dmadata_table_spec.h $( BUILD_DIR) /compress_ranges.txt
2021-11-30 23:29:09 +00:00
2023-10-20 18:14:52 +01:00
# Dependencies for files that may include the dmadata header automatically generated from the spec file
2024-01-05 14:27:19 -08:00
$(BUILD_DIR)/src/boot/z_std_dma.o : $( BUILD_DIR ) /dmadata_table_spec .h
$(BUILD_DIR)/src/dmadata/dmadata.o : $( BUILD_DIR ) /dmadata_table_spec .h
2021-11-30 23:29:09 +00:00
2023-10-20 18:14:52 +01:00
# Dependencies for files including from include/tables/
# TODO remove when full header dependencies are used.
2024-01-05 14:27:19 -08:00
$(BUILD_DIR)/src/code/graph.o : include /tables /gamestate_table .h
$(BUILD_DIR)/src/code/object_table.o : include /tables /object_table .h
$(BUILD_DIR)/src/code/z_actor.o : include /tables /actor_table .h # so uses of ACTOR_ID_MAX update when the table length changes
$(BUILD_DIR)/src/code/z_actor_dlftbls.o : include /tables /actor_table .h
$(BUILD_DIR)/src/code/z_effect_soft_sprite_dlftbls.o : include /tables /effect_ss_table .h
$(BUILD_DIR)/src/code/z_game_dlftbls.o : include /tables /gamestate_table .h
$(BUILD_DIR)/src/code/z_scene_table.o : include /tables /scene_table .h include /tables /entrance_table .h
$(BUILD_DIR)/src/%.o : src /%.c
2024-02-01 21:08:45 +01:00
i f n e q ( $( RUN_CC_CHECK ) , 0 )
2024-04-20 02:23:18 +02:00
$( V) $( CC_CHECK) $<
2024-02-01 21:08:45 +01:00
e n d i f
2024-04-20 02:23:18 +02:00
$( call print,Compiling:,$<,$@ )
$( V) $( CC) -c $( CFLAGS) $( MIPS_VERSION) $( OPTFLAGS) -o $@ $<
$( V) @$( OBJDUMP) $( OBJDUMP_FLAGS) $@ > $( @:.o= .s)
2020-03-17 00:31:30 -04:00
2024-01-05 14:27:19 -08:00
$(BUILD_DIR)/src/libultra/libc/ll.o : src /libultra /libc /ll .c
2024-02-01 21:08:45 +01:00
i f n e q ( $( RUN_CC_CHECK ) , 0 )
2024-04-20 02:23:18 +02:00
$( V) $( CC_CHECK) $<
2024-02-01 21:08:45 +01:00
e n d i f
2024-04-20 02:23:18 +02:00
$( call print,Compiling:,$<,$@ )
$( V) $( CC) -c $( CFLAGS) $( MIPS_VERSION) $( OPTFLAGS) -o $@ $<
$( V) $( PYTHON) tools/set_o32abi_bit.py $@
$( V) @$( OBJDUMP) $( OBJDUMP_FLAGS) $@ > $( @:.o= .s)
2021-01-31 11:27:50 -07:00
2024-01-05 14:27:19 -08:00
$(BUILD_DIR)/src/libultra/libc/llcvt.o : src /libultra /libc /llcvt .c
2024-02-01 21:08:45 +01:00
i f n e q ( $( RUN_CC_CHECK ) , 0 )
2024-04-20 02:23:18 +02:00
$( V) $( CC_CHECK) $<
2024-02-01 21:08:45 +01:00
e n d i f
2024-04-20 02:23:18 +02:00
$( call print,Compiling:,$<,$@ )
$( V) $( CC) -c $( CFLAGS) $( MIPS_VERSION) $( OPTFLAGS) -o $@ $<
$( V) $( PYTHON) tools/set_o32abi_bit.py $@
$( V) @$( OBJDUMP) $( OBJDUMP_FLAGS) $@ > $( @:.o= .s)
2020-05-27 00:48:07 -07:00
2024-01-05 14:27:19 -08:00
$(BUILD_DIR)/src/overlays/%_reloc.o : $( BUILD_DIR ) /$( SPEC )
2024-04-20 02:23:18 +02:00
$( call print,Generating Relocation:,$<,$@ )
$( V) $( FADO) $$ ( tools/reloc_prereq $< $( notdir $* ) ) -n $( notdir $* ) -o $( @:.o= .s) -M $( @:.o= .d)
$( V) $( AS) $( ASFLAGS) $( @:.o= .s) -o $@
2022-02-06 19:40:26 +00:00
2024-01-05 14:27:19 -08:00
$(BUILD_DIR)/%.inc.c : %.png
2024-04-20 02:23:18 +02:00
$( V) $( ZAPD) btex -eh -tt $( subst .,,$( suffix $* ) ) -i $< -o $@
2020-03-17 00:31:30 -04:00
2024-01-05 14:27:19 -08:00
$(BUILD_DIR)/assets/%.bin.inc.c : assets /%.bin
2024-04-20 02:23:18 +02:00
$( V) $( ZAPD) bblb -eh -i $< -o $@
2021-04-02 19:07:29 -03:00
2024-01-05 14:27:19 -08:00
$(BUILD_DIR)/assets/%.jpg.inc.c : assets /%.jpg
2024-04-20 02:23:18 +02:00
$( V) $( ZAPD) bren -eh -i $< -o $@
2021-05-02 22:21:27 +02:00
- i n c l u d e $( DEP_FILES )
2024-01-24 15:00:10 -03:00
# Print target for debugging
print-% : ; $( info $ * is a $ ( flavor $ *) variable set to [$ ( $ *) ]) @true