1
0
Fork 0
mirror of https://gitlab.com/sortix/sortix.git synced 2023-02-13 20:55:38 -05:00
sortix--sortix/utils/Makefile

73 lines
984 B
Makefile
Raw Normal View History

SOFTWARE_MEANT_FOR_SORTIX=1
2012-09-10 17:36:15 -04:00
include ../compiler.mak
include ../version.mak
include ../dirs.mak
2012-09-10 17:36:15 -04:00
ifndef OPTLEVEL
OPTLEVEL=-g -O2
2012-09-10 17:36:15 -04:00
endif
2012-09-10 17:36:15 -04:00
ifndef CXXFLAGS
CXXFLAGS:=$(OPTLEVEL)
endif
CPPFLAGS:=$(CPPFLAGS) -DVERSIONSTR=\"$(VERSION)\"
2012-09-10 17:36:15 -04:00
CXXFLAGS:=$(CXXFLAGS) -Wall -Wextra -fno-exceptions -fno-rtti
BINARIES:=\
calc \
cat \
2013-02-23 11:42:23 -05:00
chvideomode \
clear \
column \
2011-11-21 08:57:02 -05:00
cp \
2011-11-25 18:54:17 -05:00
echo \
2013-02-23 11:42:23 -05:00
editor \
2013-02-17 08:23:04 -05:00
find \
2013-02-23 11:42:23 -05:00
head \
2011-08-27 17:26:11 -04:00
help \
2013-02-23 11:42:23 -05:00
init \
2013-02-19 15:41:53 -05:00
install-file \
kernelinfo \
kill \
2013-02-23 11:42:23 -05:00
ln \
ls \
memstat \
mkdir \
2013-02-16 10:28:40 -05:00
mv \
2013-02-23 11:42:23 -05:00
mxsh \
pager \
2013-02-23 11:42:23 -05:00
pwd \
rm \
rmdir \
sh \
2012-03-02 18:29:24 -05:00
tail \
type \
2013-02-23 11:42:23 -05:00
uname \
uptime \
2012-12-09 13:10:59 -05:00
which \
INSTALLBINARIES:=$(addprefix $(DESTDIR)$(BINDIR)/,$(BINARIES))
2012-09-10 17:36:15 -04:00
all: $(BINARIES)
.PHONY: all install uninstall clean
2012-09-10 17:36:15 -04:00
install: all
mkdir -p $(DESTDIR)$(BINDIR)
install $(BINARIES) $(DESTDIR)$(BINDIR)
2013-02-19 15:41:53 -05:00
install install-file $(DESTDIR)$(BINDIR)/install
2012-09-10 17:36:15 -04:00
uninstall:
rm -f $(INSTALLBINARIES) $(DESTDIR)$(BINDIR)/install
%: %.cpp
$(CXX) -std=gnu++11 $(CPPFLAGS) $(CXXFLAGS) $< -o $@
sh: mxsh
cp $< $@
clean:
2012-09-10 17:36:15 -04:00
rm -f $(BINARIES) *.o