mirror of
https://github.com/Pharaoh2k/ps5debug-NG.git
synced 2026-10-21 19:33:05 -05:00
Pin LF endings for our C/H/S/Makefile/Markdown/shell/Python files so edits no longer produce spurious whole-file CRLF/LF diffs across machines or editors. Converts the 6 previously-CRLF tracked files to LF (PROTOCOL.md, README.md, debugger/Makefile, debugger/source/proc_remote.c, installer/Makefile, installer/source/main.c). Vendored trees (ps5-payload-sdk, third_party, debugger/third_party) are marked -text and left byte-for-byte unchanged. EOL-only change; no code changes.
43 lines
1.1 KiB
Makefile
43 lines
1.1 KiB
Makefile
# SPDX-License-Identifier: GPL-3.0-only
|
|
|
|
SDK := ../ps5-payload-sdk/install
|
|
|
|
ifeq (,$(wildcard $(SDK)/toolchain/prospero.mk))
|
|
$(error SDK not built - run ../build.sh from the project root)
|
|
endif
|
|
|
|
include $(SDK)/toolchain/prospero.mk
|
|
|
|
ELF := build/ps5debug-NG.elf
|
|
BUILD_DIR := build
|
|
|
|
PAYLOAD_ELF := ../debugger/build/debugger.elf
|
|
EMBEDDED_BIN := $(BUILD_DIR)/embedded_inner.elf.bin
|
|
EMBEDDED_OBJ := $(BUILD_DIR)/embedded_inner.o
|
|
EMBEDDED_S := source/embedded_inner.S
|
|
|
|
CFLAGS := -Wall -O2 -I../common/include -ffunction-sections -fdata-sections
|
|
LDFLAGS := -Wl,--gc-sections
|
|
LDLIBS := -lSceLibcInternal -lkernel_sys -lSceNet -lSceNetCtl -lSceSysCore
|
|
|
|
CFILES := $(wildcard ../common/source/*.c) $(wildcard source/*.c)
|
|
|
|
all: $(ELF)
|
|
|
|
$(BUILD_DIR):
|
|
mkdir -p $(BUILD_DIR)
|
|
|
|
$(EMBEDDED_BIN): $(PAYLOAD_ELF) | $(BUILD_DIR)
|
|
cp $< $@
|
|
|
|
$(EMBEDDED_OBJ): $(EMBEDDED_S) $(EMBEDDED_BIN) | $(BUILD_DIR)
|
|
$(CC) -c -o $@ $(EMBEDDED_S) -I$(BUILD_DIR)
|
|
|
|
$(ELF): $(CFILES) $(EMBEDDED_OBJ) | $(BUILD_DIR)
|
|
$(CC) $(CFLAGS) -o $@ $(CFILES) $(EMBEDDED_OBJ) $(LDFLAGS) $(LDLIBS)
|
|
|
|
clean:
|
|
rm -rf $(BUILD_DIR)
|
|
|
|
.PHONY: all clean
|