3 # Build control file for the rEFInd boot menu
5 # This program is licensed under the terms of the GNU GPL, version 3,
6 # or (at your option) any later version.
7 # You should have received a copy of the GNU General Public License
8 # along with this program. If not, see <http://www.gnu.org/licenses/>.
14 ARCH
= $(shell uname
-m | sed s
,i
[3456789]86,ia32
,)
20 TARGET
= refind_ia32.efi
25 TARGET
= refind_x64.efi
28 ifeq ($(ARCH
),aarch64
)
30 TARGET
= refind_aa64.efi
33 LOCAL_GNUEFI_CFLAGS
= -I
$(SRCDIR
) -I
$(SRCDIR
)/..
/include \
34 -I
$(SRCDIR
)/..
/libeg
-I
$(SRCDIR
)/..
/mok
35 LOCAL_LDFLAGS
= -L
$(SRCDIR
)/..
/libeg
/ -L
$(SRCDIR
)/..
/mok
/ \
36 -L
$(SRCDIR
)/..
/EfiLib
/
37 LOCAL_LIBS
= -leg
-lmok
-lEfiLib
39 OBJS
= main.o mystrings.o apple.o line_edit.o config.o menu.o \
40 screen.o icns.o gpt.o crc32.o lib.o driver_support.o \
43 include $(SRCDIR
)/..
/Make.common
47 $(SHLIB_TARGET
): $(OBJS
)
48 $(LD
) $(LOCAL_LDFLAGS
) $(GNUEFI_LDFLAGS
) $(SUBSYSTEM_LDFLAG
) $(OBJS
) \
49 -o
$@
$(LOCAL_LIBS
) $(GNUEFI_LIBS
)
51 $(TARGET
): $(SHLIB_TARGET
)
52 $(OBJCOPY
) -j .text
-j .sdata
-j .data
-j .dynamic
-j .dynsym
-j .rel \
53 -j .rela
-j .rel.
* -j .rela.
* -j .rel
* -j .rela
* \
54 -j .reloc
$(FORMAT
) $< $@
58 rm -f
$(TARGET
) *~
*.so
$(OBJS
) *.efi
*.obj refind_
*.txt \