diff options
author | James Bottomley <James.Bottomley@HansenPartnership.com> | 2018-02-20 22:45:27 -0500 |
---|---|---|
committer | James Bottomley <James.Bottomley@HansenPartnership.com> | 2018-02-20 22:51:31 -0500 |
commit | 2e0965cb03ec1aa0311e9cebedfd21fa5bbce525 (patch) | |
tree | 25beca8ccdd9077509277ba59f25ef4251d0234e | |
parent | cf61362f95844f2fa607844ad3875ed9081c9216 (diff) | |
download | efitools-2e0965cb03ec1aa0311e9cebedfd21fa5bbce525.tar.gz |
Fix Fedora build
Fedora has a whole load of weird and wonderful ideas beyond both
Debian and openSUSE about how to install gnu-efi. Fix the build rules
to accommodate its eccentricities.
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
-rw-r--r-- | Make.rules | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -15,16 +15,16 @@ $(error unknown architecture $(ARCH)) endif INCDIR = -I$(TOPDIR)include/ -I/usr/include/efi -I/usr/include/efi/$(ARCH) -I/usr/include/efi/protocol CPPFLAGS = -DCONFIG_$(ARCH) -CFLAGS = -O2 $(ARCH3264) -fpic -Wall -fshort-wchar -fno-strict-aliasing -fno-merge-constants -fno-stack-protector -ffreestanding -fno-stack-check +CFLAGS = -O2 -g $(ARCH3264) -fpic -Wall -fshort-wchar -fno-strict-aliasing -fno-merge-constants -fno-stack-protector -ffreestanding -fno-stack-check LDFLAGS = -nostdlib CRTOBJ = crt0-efi-$(ARCH).o -CRTPATHS = /lib /lib64 /lib/efi /lib64/efi /usr/lib /usr/lib64 /usr/lib/efi /usr/lib64/efi +CRTPATHS = /lib /lib64 /lib/efi /lib64/efi /usr/lib /usr/lib64 /usr/lib/efi /usr/lib64/efi /usr/lib/gnuefi /usr/lib64/gnuefi CRTPATH = $(shell for f in $(CRTPATHS); do if [ -e $$f/$(CRTOBJ) ]; then echo $$f; break; fi; done) CRTOBJS = $(CRTPATH)/$(CRTOBJ) # there's a bug in the gnu tools ... the .reloc section has to be # aligned otherwise the file alignment gets screwed up LDSCRIPT = elf_$(ARCH)_efi.lds -LDFLAGS += -shared -Bsymbolic $(CRTOBJS) -L $(CRTPATH) -T $(LDSCRIPT) +LDFLAGS += -shared -Bsymbolic $(CRTOBJS) -L $(CRTPATH) -L /usr/lib -L /usr/lib64 -T $(LDSCRIPT) LOADLIBES = -lefi -lgnuefi $(shell $(CC) $(ARCH3264) -print-libgcc-file-name) FORMAT = --target=efi-app-$(ARCH) OBJCOPY = objcopy |