2014-06-28 10:10:20 -04:00
|
|
|
include ../build-aux/platform.mak
|
|
|
|
include ../build-aux/compiler.mak
|
|
|
|
include ../build-aux/version.mak
|
|
|
|
include ../build-aux/dirs.mak
|
2013-03-26 07:40:43 -04:00
|
|
|
|
2014-04-13 16:34:36 -04:00
|
|
|
OPTLEVEL?=$(DEFAULT_OPTLEVEL)
|
2016-02-28 18:10:59 -05:00
|
|
|
CFLAGS?=$(OPTLEVEL)
|
2013-03-26 07:40:43 -04:00
|
|
|
|
2016-02-28 18:10:59 -05:00
|
|
|
CFLAGS:=$(CFLAGS) -Wall -Wextra
|
2015-07-29 19:08:49 -04:00
|
|
|
CPPFLAGS:=$(CPPFLAGS) -DVERSIONSTR=\"$(VERSION)\"
|
2016-02-28 18:10:59 -05:00
|
|
|
|
|
|
|
ifeq ($(HOST_IS_SORTIX),0)
|
|
|
|
CPPFLAGS+=-D_GNU_SOURCE
|
|
|
|
endif
|
2013-03-26 07:40:43 -04:00
|
|
|
|
|
|
|
BINARIES:=\
|
|
|
|
porttix-create \
|
|
|
|
srctix-create \
|
|
|
|
tix \
|
|
|
|
tix-build \
|
|
|
|
tix-collection \
|
|
|
|
tix-execdiff \
|
|
|
|
tix-execpatch \
|
|
|
|
tix-install \
|
|
|
|
tix-rmpatch \
|
|
|
|
|
|
|
|
PROGRAMS:=\
|
|
|
|
$(BINARIES) \
|
|
|
|
tix-eradicate-libtool-la \
|
2018-03-30 17:44:12 -04:00
|
|
|
tix-iso-add \
|
|
|
|
tix-iso-bootconfig \
|
|
|
|
tix-iso-liveconfig \
|
|
|
|
|
|
|
|
MANPAGES8=\
|
|
|
|
tix-iso-add.8 \
|
|
|
|
tix-iso-bootconfig.8 \
|
|
|
|
tix-iso-liveconfig.8 \
|
2013-03-26 07:40:43 -04:00
|
|
|
|
|
|
|
all: $(PROGRAMS)
|
|
|
|
|
|
|
|
.PHONY: all install clean
|
|
|
|
|
2016-02-28 18:10:59 -05:00
|
|
|
%: %.c util.h
|
|
|
|
$(CC) -std=gnu11 $(CFLAGS) $(CPPFLAGS) $< -o $@
|
2013-03-26 07:40:43 -04:00
|
|
|
|
2015-12-28 20:31:26 -05:00
|
|
|
$(DESTDIR)$(SBINDIR):
|
2013-03-26 07:40:43 -04:00
|
|
|
mkdir -p $@
|
|
|
|
|
2015-12-28 20:31:26 -05:00
|
|
|
install: all $(DESTDIR)$(SBINDIR)
|
|
|
|
install $(PROGRAMS) $(DESTDIR)$(SBINDIR)
|
2018-03-30 17:44:12 -04:00
|
|
|
mkdir -p $(DESTDIR)$(MANDIR)/man8
|
|
|
|
mkdir -p $(DESTDIR)$(MANDIR)/man8
|
|
|
|
cp $(MANPAGES8) $(DESTDIR)$(MANDIR)/man8
|
2013-03-26 07:40:43 -04:00
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f $(BINARIES)
|