.PHONY: all install clean PREFIX = $(HOME)/.local CC = clang CFLAGS = -std=c90 -Weverything -fPIC all: libayylmao.a libayylmao.so install: libayylmao.so libayylmao.a mkdir -p -- $(PREFIX)/lib $(PREFIX)/include install -m 0644 -- *.h $(PREFIX)/include install -m 0644 -- *.so *.a $(PREFIX)/lib install -m 0644 -- *.3 $(PREFIX)/share/man/man3 clean: rm -f -- *.a *.o *.so libayylmao.a: ayy.o lmao.o ar rcs "$@" ayy.o lmao.o libayylmao.so: ayy.o lmao.o $(CC) $(CFLAGS) -shared -Wl,-soname,"$@" -o "$@" ayy.o lmao.o