new ignore rule for compilation artifacts and makefile rule for installation

This commit is contained in:
cozis
2022-08-11 18:18:40 +02:00
parent c3d4479e97
commit 385e0145b8
5 changed files with 12 additions and 3 deletions
+3 -3
View File
@@ -1,4 +1,4 @@
build cache
temp
vgcore.* vgcore.*
out libnoja.a
noja
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
+9
View File
@@ -27,6 +27,11 @@ CLI_SUBDIR = cli
LIB_FNAME = libnoja.a LIB_FNAME = libnoja.a
CLI_FNAME = noja CLI_FNAME = noja
# Where the build programs will be moved when
# installation occurres.
CLI_INSTALLDIR = /bin
LIB_INSTALLDIR = /usr/local
# Default programs # Default programs
CC = gcc CC = gcc
AR = ar AR = ar
@@ -81,6 +86,10 @@ $(LIB): $(LIB_OFILES)
$(CLI): $(CLI_OFILES) $(LIB) $(CLI): $(CLI_OFILES) $(LIB)
$(CC) $^ -o $@ $(LFLAGS) $(CC) $^ -o $@ $(LFLAGS)
install: $(LIB) $(CLI)
sudo cp $(LIB) $(LIB_INSTALLDIR)
sudo cp $(CLI) $(CLI_INSTALLDIR)
clean: clean:
rm -rf $(OBJDIR) rm -rf $(OBJDIR)
rm -f $(LIB) rm -f $(LIB)
BIN
View File
Binary file not shown.