-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
55 lines (42 loc) · 921 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
# variables
CC := g++
SRCDIR := src
INCLUDEDIR := include
BUILDDIR := bin
CFLAG := -v
INC := -I include/alib -I lib/rang
APPNAME := alib
APPTESTNAME := alibTest
APPTESTDIR := test
.PHONY: all
all: testBuild testRun
.PHONY: build
build:
${CC} ${CFLAG} ${SRCDIR}/${APPNAME}.cpp ${INC} -o ${BUILDDIR}/${APPNAME}.exe
.PHONY: run
run:
# Testing env
.PHONY: testBuild
testBuild:
${CC} ${CFLAG} ${APPTESTDIR}/${APPTESTNAME}.cpp ${INC} -o ${BUILDDIR}/${APPTESTNAME}.exe
.PHONY: testRun
testRun:
${BUILDDIR}/${APPTESTNAME}.exe
.PHONY: config
config:
mkdir bin
mkdir src
.PHONY: clean
clean:
rm -r bin src
install:
sudo cp include/alib/alib.hpp lib/rang/rang.hpp /usr/include
echo Installed Alib to your system
uninstall:
sudo rm /usr/include/alib.hpp /usr/include/rang.hpp
echo "Removed Alib from your sytem"
pkgclean:
sudo rm -r pkg ALib *pkg.tar.zst
pkgbuild:
makepkg --printsrcinfo > .SRCINFO
makepkg