Annotation of /branches/mage-next/conf/Makefile
Parent Directory | Revision Log
Revision 2577 -
(hide annotations)
(download)
Wed Jan 29 13:38:39 2014 UTC (10 years, 4 months ago) by niro
File size: 831 byte(s)
Wed Jan 29 13:38:39 2014 UTC (10 years, 4 months ago) by niro
File size: 831 byte(s)
-re-facored buildsystem
1 | niro | 2577 | include ../Makefile.inc |
2 | |||
3 | FILES = etc-update.conf mage.rc.example mage.rc.global | ||
4 | |||
5 | ARCH = $(shell uname -m) | ||
6 | ifeq ($(ARCH), x86_64) | ||
7 | MTUNE = generic | ||
8 | else | ||
9 | MTUNE = $(ARCH) | ||
10 | endif | ||
11 | |||
12 | SCRIPT_SED_LINES += \ | ||
13 | -e "s:@@ARCH@@:$(ARCH):g" \ | ||
14 | -e "s:@@MTUNE@@:$(MTUNE):g" | ||
15 | |||
16 | all: $(FILES) | ||
17 | |||
18 | install: all | ||
19 | $(INSTALLDIR) $(DESTDIR)/$(SYSCONFDIR) | ||
20 | $(INSTALLFILE) $(FILES) $(DESTDIR)/$(SYSCONFDIR) | ||
21 | $(INSTALLDIR) $(DESTDIR)/$(MAGELIBDIR) | ||
22 | $(INSTALLFILE) mage.rc.example $(DESTDIR)/$(MAGELIBDIR) | ||
23 | $(INSTALLFILE) mage.rc.global $(DESTDIR)/$(MAGELIBDIR) | ||
24 | |||
25 | uninstall: | ||
26 | for i in $(FILES); do $(RM) $(DESTDIR)/$(SYSCONFDIR)/$${i}; done | ||
27 | $(RM) $(DESTDIR)/$(MAGELIBDIR)/mage.rc.example | ||
28 | $(RM) $(DESTDIR)/$(MAGELIBDIR)/mage.rc.global | ||
29 | $(RMDIR) $(DESTDIR)/$(SYSCONFDIR) | ||
30 | $(RMDIR) $(DESTDIR)/$(MAGELIBDIR) | ||
31 | |||
32 | clean: | ||
33 | $(RM) $(FILES) | ||
34 | |||
35 | .PHONY: all install uninstall clean |