rulimine/Makefile

52 lines
1.9 KiB
Makefile
Raw Normal View History

2022-09-05 04:48:38 +03:00
CC ?= cc
INSTALL ?= ./install-sh
PREFIX ?= /usr/local
CFLAGS ?= -g -O2 -pipe -Wall -Wextra
.PHONY: all
2023-02-07 03:04:05 +03:00
all: limine-deploy limine-version limine-enroll-config
2022-09-05 04:48:38 +03:00
.PHONY: install-data
install-data: all
$(INSTALL) -d '$(DESTDIR)$(PREFIX)/share'
$(INSTALL) -d '$(DESTDIR)$(PREFIX)/share/limine'
$(INSTALL) -m 644 limine.sys '$(DESTDIR)$(PREFIX)/share/limine/'
$(INSTALL) -m 644 limine-cd.bin '$(DESTDIR)$(PREFIX)/share/limine/'
$(INSTALL) -m 644 limine-cd-efi.bin '$(DESTDIR)$(PREFIX)/share/limine/'
$(INSTALL) -m 644 limine-pxe.bin '$(DESTDIR)$(PREFIX)/share/limine/'
$(INSTALL) -m 644 BOOTX64.EFI '$(DESTDIR)$(PREFIX)/share/limine/'
$(INSTALL) -m 644 BOOTIA32.EFI '$(DESTDIR)$(PREFIX)/share/limine/'
$(INSTALL) -d '$(DESTDIR)$(PREFIX)/include'
$(INSTALL) -m 644 limine.h '$(DESTDIR)$(PREFIX)/include/'
.PHONY: install
install: install-data
$(INSTALL) -d '$(DESTDIR)$(PREFIX)/bin'
$(INSTALL) limine-deploy '$(DESTDIR)$(PREFIX)/bin/'
$(INSTALL) limine-version '$(DESTDIR)$(PREFIX)/bin/'
2023-02-07 03:04:05 +03:00
$(INSTALL) limine-enroll-config '$(DESTDIR)$(PREFIX)/bin/'
2022-09-05 04:48:38 +03:00
.PHONY: install-strip
install-strip: install-data
$(INSTALL) -d '$(DESTDIR)$(PREFIX)/bin'
$(INSTALL) -s limine-deploy '$(DESTDIR)$(PREFIX)/bin/'
$(INSTALL) -s limine-version '$(DESTDIR)$(PREFIX)/bin/'
2023-02-07 03:04:05 +03:00
$(INSTALL) -s limine-enroll-config '$(DESTDIR)$(PREFIX)/bin/'
2022-09-05 04:48:38 +03:00
.PHONY: clean
clean:
rm -f limine-deploy limine-deploy.exe
rm -f limine-version limine-version.exe
2023-02-07 03:04:05 +03:00
rm -f limine-enroll-config limine-enroll-config.exe
2022-09-05 04:48:38 +03:00
2022-09-24 05:37:43 +03:00
limine-deploy: limine-deploy.c limine-hdd.h
2022-09-21 00:59:04 +03:00
$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -std=c99 -D__USE_MINGW_ANSI_STDIO limine-deploy.c $(LIBS) -o $@
2022-09-05 04:48:38 +03:00
limine-version: limine-version.c
2022-09-21 00:59:04 +03:00
$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -std=c99 -D__USE_MINGW_ANSI_STDIO limine-version.c $(LIBS) -o $@
2023-02-07 03:04:05 +03:00
limine-enroll-config: limine-enroll-config.c
$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -std=c99 -D__USE_MINGW_ANSI_STDIO limine-enroll-config.c $(LIBS) -o $@