mirror of
https://codeberg.org/canoeboot/cbmk.git
synced 2024-12-22 07:49:55 +00:00
9c1a7e0f79
Use shell scripting in the recipe instead of GNU make's conditional syntax. This allows the Makefile to work with the default implementations of make on the BSDs. Signed-off-by: Nicholas Chin <nic.c3.14@gmail.com>
16 lines
397 B
Makefile
16 lines
397 B
Makefile
# SPDX-License-Identifier: MIT
|
|
# SPDX-FileCopyrightText: 2023 Nicholas Chin
|
|
|
|
CC=cc
|
|
CFLAGS=-Wall -Wextra -Werror -O2 -pedantic
|
|
SRCS=dell_flash_unlock.c accessors.c
|
|
|
|
all: $(SRCS) accessors.h
|
|
CFLAGS="$(CFLAGS)"; \
|
|
if [ $$(uname) = OpenBSD ] || [ $$(uname) = NetBSD ]; then \
|
|
CFLAGS="$$CFLAGS -l$$(uname -p)"; \
|
|
fi; \
|
|
$(CC) $$CFLAGS $(SRCS) -o dell_flash_unlock
|
|
|
|
clean:
|
|
rm -f dell_flash_unlock
|