build: Misc improvements
This commit is contained in:
parent
9f00d613a1
commit
4b32083ab6
@ -76,6 +76,7 @@ override STAGE1_FILES := $(shell find '$(call SHESCAPE,$(SRCDIR))/stage1' -type
|
||||
|
||||
.PHONY: all
|
||||
all: @BUILD_UEFI_X86_64@ @BUILD_UEFI_IA32@ @BUILD_BIOS@
|
||||
$(MAKE) '$(call SHESCAPE,$(BINDIR))/limine-cd-efi.bin'
|
||||
|
||||
$(call MKESCAPE,$(BINDIR))/limine-deploy: $(call MKESCAPE,$(SRCDIR))/limine-deploy/limine-deploy.c $(call MKESCAPE,$(BINDIR))/limine-hdd.bin
|
||||
mkdir -p '$(call SHESCAPE,$(BINDIR))'
|
||||
|
@ -285,7 +285,7 @@ $(call MKESCAPE,$(BUILDDIR))/limine-efi/gnuefi/reloc_x86_64.o: limine-efi
|
||||
|
||||
.PHONY: limine-efi
|
||||
limine-efi: $(call MKESCAPE,$(BUILDDIR))/limine-efi
|
||||
unset ARFLAGS; unset CPPFLAGS; \
|
||||
unset CPPFLAGS; \
|
||||
$(MAKE) -C '$(call SHESCAPE,$(BUILDDIR))/limine-efi/gnuefi' \
|
||||
CC="$(LIMINE_CC) -m64 -march=x86-64 -mtune=generic" \
|
||||
CFLAGS='-nostdinc' \
|
||||
@ -333,7 +333,7 @@ $(call MKESCAPE,$(BUILDDIR))/limine-efi/gnuefi/reloc_ia32.o: limine-efi
|
||||
|
||||
.PHONY: limine-efi
|
||||
limine-efi: $(call MKESCAPE,$(BUILDDIR))/limine-efi
|
||||
unset ARFLAGS; unset CPPFLAGS; \
|
||||
unset CPPFLAGS; \
|
||||
$(MAKE) -C '$(call SHESCAPE,$(BUILDDIR))/limine-efi/gnuefi' \
|
||||
CC="$(LIMINE_CC) -m32 -march=i686 -mtune=generic" \
|
||||
CFLAGS='-nostdinc' \
|
||||
|
@ -138,7 +138,7 @@ AC_SUBST(BUILD_UEFI_X86_64, [$BUILD_UEFI_X86_64])
|
||||
BUILD_CD_EFI="$BUILD_ALL"
|
||||
|
||||
AC_ARG_ENABLE([cd-efi],
|
||||
AS_HELP_STRING([--enable-cd-efi], [enable limine-cd-efi.bin build]),
|
||||
AS_HELP_STRING([--enable-cd-efi], [enable building limine-cd-efi.bin]),
|
||||
BUILD_CD_EFI="$enableval")
|
||||
|
||||
if ! test "x$BUILD_CD_EFI" = "xno"; then
|
||||
|
@ -71,6 +71,17 @@ if ! $LIMINE_CC -dumpmachine >/dev/null 2>&1; then
|
||||
fi
|
||||
|
||||
CC_MACHINE="$($LIMINE_CC -dumpmachine | dd bs=${#ARCHITECTURE} count=1 2>/dev/null)"
|
||||
|
||||
if test "x$CC_MACHINE" = "xx86_"; then
|
||||
case "$ARCHITECTURE" in
|
||||
i?86)
|
||||
CC_MACHINE="$ARCHITECTURE"
|
||||
;;
|
||||
*)
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
if ! test "x$CC_MACHINE" = "x$ARCHITECTURE"; then
|
||||
CC_ERROR_MSG
|
||||
fi
|
||||
@ -111,8 +122,6 @@ AC_DEFUN([GET_BINUTILS_PROG], [
|
||||
])
|
||||
|
||||
GET_BINUTILS_PROG(LD, ld, linker)
|
||||
GET_BINUTILS_PROG(AR, ar, archiver)
|
||||
GET_BINUTILS_PROG(AS, as, assembler)
|
||||
GET_BINUTILS_PROG(OBJCOPY, objcopy, objcopy)
|
||||
GET_BINUTILS_PROG(OBJDUMP, objdump, objdump)
|
||||
GET_BINUTILS_PROG(READELF, readelf, readelf)
|
||||
|
Loading…
Reference in New Issue
Block a user