forked from void-linux/xbps
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
49 lines (40 loc) · 1 KB
/
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
-include config.mk
SUBDIRS = include lib bin data
ifdef BUILD_API_DOCS
SUBDIRS += doc
endif
ifdef BUILD_TESTS
SUBDIRS += tests
endif
all:
@if test ! -e config.mk; then \
echo "You didn't run ./configure ... exiting."; \
exit 1; \
fi
@for dir in $(SUBDIRS); do \
$(MAKE) -C $$dir || exit 1; \
done
install:
@for dir in $(SUBDIRS); do \
$(MAKE) -C $$dir install || exit 1; \
done
@echo
@echo "Binaries have been installed into $(DESTDIR)$(SBINDIR)."
@echo "Librares have been installed into $(DESTDIR)$(LIBDIR)."
@echo "Configuration file has been installed into $(DESTDIR)$(ETCDIR)."
@echo
@echo "WARNING: Don't forget to rerun ldconfig(1) if $(LIBDIR) is not"
@echo "WARNING: in your ld.so.conf by default."
@echo
uninstall:
@for dir in $(SUBDIRS); do \
$(MAKE) -C $$dir uninstall || exit 1; \
done
check:
@./run-tests
clean:
@for dir in $(SUBDIRS); do \
$(MAKE) -C $$dir clean || exit 1; \
done
-rm -f result* config.mk _ccflag.{,c,err}
.PHONY: all install uninstall check clean