X-Git-Url: https://code.delx.au/refind/blobdiff_plain/11fa7da805c3e263f8b05339f1900baa73a2ffd4..cc81100ca9d8e17fffcbffc85bd401fcbe445038:/Makefile?ds=sidebyside diff --git a/Makefile b/Makefile index c2616e8..2292c51 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,10 @@ # Makefile for rEFInd -CC=gcc -CXX=g++ + +# This program is licensed under the terms of the GNU GPL, version 3, +# or (at your option) any later version. +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + CXXFLAGS=-O2 -fpic -D_REENTRANT -D_GNU_SOURCE -Wall -g NAMES=refind SRCS=$(NAMES:=.c) @@ -13,6 +17,25 @@ MOK_DIR=mok GPTSYNC_DIR=gptsync EFILIB_DIR=EfiLib +export EDK2BASE = /usr/local/UDK2014/MyWorkSpace +export GENFW = $(EDK2BASE)/BaseTools/Source/C/bin/GenFw +export prefix = /usr/bin/ +ifeq ($(ARCH),aarch64) + export CC = $(prefix)aarch64-linux-gnu-gcc + export AS = $(prefix)aarch64-linux-gnu-as + export LD = $(prefix)aarch64-linux-gnu-ld + export AR = $(prefix)aarch64-linux-gnu-ar + export RANLIB = $(prefix)aarch64-linux-gnu-ranlib + export OBJCOPY = $(prefix)aarch64-linux-gnu-objcopy +else + export CC = $(prefix)gcc + export AS = $(prefix)as + export LD = $(prefix)ld + export AR = $(prefix)ar + export RANLIB = $(prefix)ranlib + export OBJCOPY = $(prefix)objcopy +endif + # Build rEFInd, including libeg all: tiano @@ -35,9 +58,17 @@ tiano: +make AR_TARGET=libeg -C $(LIBEG_DIR) -f Make.tiano +make AR_TARGET=mok -C $(MOK_DIR) -f Make.tiano +make BUILDME=refind DLL_TARGET=refind -C $(LOADER_DIR) -f Make.tiano +ifneq ($(ARCH),aarch64) +make -C $(GPTSYNC_DIR) -f Make.tiano +endif # +make -C $(FS_DIR) +gptsync: + +make -C $(GPTSYNC_DIR) -f Make.tiano + +gptsync_gnuefi: + +make -C $(GPTSYNC_DIR) gnuefi + clean: make -C $(LIBEG_DIR) clean make -C $(MOK_DIR) clean @@ -54,10 +85,10 @@ clean: # binary packages (RPMs, Debian packages, etc.). (Gentoo could # use it in an ebuild, though....) You COULD, however, copy the # files to a directory somewhere (/usr/share/refind or whatever) -# and then call install.sh as part of the binary package +# and then call refind-install as part of the binary package # installation process. install: - ./install.sh + ./refind-install # DO NOT DELETE