[syslinux] mk/efi.mk: Build gnu-efi with the Makefile, ARFLAGS=$(AROPT)
Celelibi
celelibi at gmail.com
Mon Sep 14 13:41:39 PDT 2015
2015-09-14 7:31 UTC+02:00, Geert Stappers via Syslinux <syslinux at zytor.com>:
> On Mon, Sep 14, 2015 at 05:50:58AM +0200, celelibi--- via Syslinux wrote:
>> index a705440..5ef6702 100644
>> --- a/mk/efi.mk
>> +++ b/mk/efi.mk
>> @@ -10,6 +10,7 @@ core = $(topdir)/core
>> GCCOPT := $(call gcc_ok,-fno-stack-protector,)
>> EFIINC = $(objdir)/include/efi
>> LIBDIR = $(objdir)/lib
>> +EFIDIR = $(topdir)/gnu-efi/gnu-efi-3.0
>
> Would it make sense to add
>
> AROPT = rvU
>
> or
>
> #ifdefine AR_DEFAULT_SETS_TIMESTAMP_TO_ZERO
> AROPT = rvU
> #elseif
> AROPT = rv
> #endifdefine
>
> ?
Definitely the second one, as some older versions of ar don't support
the U flag.
But how would we determine automatically if ar supports the U flag?
We could include a small test a-la autoconf in the Makefile, but I'm
not sure hpa would be big on that idea. Especially to fix something
that happens inside the Makefiles of gnu-efi.
>
>
>> ifeq ($(ARCH),i386)
>> ARCHOPT = -m32 -march=i386
>> @@ -55,7 +56,13 @@ $(EFIINC)/%.h $(EFIINC)/protocol/%.h
>> $(EFIINC)/$(EFI_SUBARCH)/%.h: gnuefi ;
>> .PHONY: gnuefi
>> gnuefi:
>> @echo Building gnu-efi for $(EFI_SUBARCH)
>> - $(topdir)/efi/check-gnu-efi.sh $(EFI_SUBARCH) $(objdir)
>> + cd $(topdir) && git submodule update --init
>> + mkdir -p "$(objdir)/gnu-efi"
>> + MAKEFLAGS= make SRCDIR="$(EFIDIR)" TOPDIR="$(EFIDIR)" \
>> + ARCH=$(EFI_SUBARCH) ARFLAGS=rvU -f "$(EFIDIR)/Makefile"
>
> + ARCH=$(EFI_SUBARCH) ARFLAGS=$(AROPT) -f "$(EFIDIR)/Makefile"
>
>> + MAKEFLAGS= make SRCDIR="$(EFIDIR)" TOPDIR="$(EFIDIR)" \
>> + ARCH=$(EFI_SUBARCH) PREFIX="$(objdir)" ARFLAGS=rvU \
>> + -f "$(EFIDIR)/Makefile" install
>>
>> %.o: %.S # Cancel old rule
>>
Celelibi
More information about the Syslinux
mailing list