This commit is contained in:
mintsuki 2022-08-22 18:41:32 +02:00
parent a17edef7bc
commit c626e63b56
2 changed files with 22 additions and 9 deletions

View File

@ -19,32 +19,39 @@ MKESCAPE = $(subst $(SPACE),\ ,$(1))
SHESCAPE = $(subst ','\'',$(1))
NASMESCAPE = $(subst ','"'$(COMMA) \"'\"$(COMMA) '"',$(1))
define DEFAULT_VAR =
ifeq ($(origin $1),default)
override $(1) := $(2)
endif
ifeq ($(origin $1),undefined)
override $(1) := $(2)
endif
endef
override BUILD_CD_EFI := @BUILD_CD_EFI@
override BUILD_PXE := @BUILD_PXE@
override BUILD_CD := @BUILD_CD@
override BUILD_LIMINE_DEPLOY := @BUILD_LIMINE_DEPLOY@
WERROR ?= @WERROR@
override WERROR := @WERROR@
export WERROR
ifeq ($(origin CC),default)
CC := @CC@
endif
$(eval $(call DEFAULT_VAR,CC,cc))
export CC
MKDIR_P ?= @MKDIR_P@
override MKDIR_P := @MKDIR_P@
export MKDIR_P
INSTALL ?= @INSTALL@
override INSTALL := @INSTALL@
export INSTALL
GREP ?= @GREP@
override GREP := @GREP@
export GREP
SED ?= @SED@
override SED := @SED@
export SED
AWK ?= @AWK@
override AWK := @AWK@
export AWK
CFLAGS ?= @CFLAGS@

View File

@ -25,7 +25,13 @@ if test "$werror_state" = "yes"; then
fi
AC_PROG_MKDIR_P
case "$MKDIR_P" in
.*) MKDIR_P="$(cd "$(dirname "$MKDIR_P")" && pwd -P)/$(basename "$MKDIR_P")" ;;
esac
AC_PROG_INSTALL
case "$INSTALL" in
.*) INSTALL="$(cd "$(dirname "$INSTALL")" && pwd -P)/$(basename "$INSTALL")" ;;
esac
AC_PROG_GREP
AC_PROG_SED
AC_PROG_AWK