Magellan Linux

Diff of /tags/installer-simple-0_4_90_20140108_4/Makefile

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2333 by niro, Fri Jan 3 14:00:30 2014 UTC revision 2508 by niro, Wed Jan 8 15:06:32 2014 UTC
# Line 1  Line 1 
1  # $Id$  # $Id$
2    
3  VERSION = $(shell cat VERSION)  SYSCONFDIR = /etc
 SYSTEMDUNITDIR = $(shell pkg-config --variable=systemdsystemunitdir systemd)  
 INSTALLER_TTY = tty1  
   
 SYSCONFDIR = etc  
4  PREFIX = /usr  PREFIX = /usr
5  LIBDIR = $(PREFIX)/lib/installer  LIBDIR = $(PREFIX)/lib/installer
6  BINDIR = $(PREFIX)/bin  BINDIR = $(PREFIX)/bin
# Line 13  SED = sed Line 9  SED = sed
9  INSTALL = install  INSTALL = install
10  LN_S = ln -snf  LN_S = ln -snf
11  RM = rm  RM = rm
12    CAT = cat
13    PKGCONFIG = pkg-config
14    
15    VERSION = $(shell $(CAT) VERSION)
16    SYSTEMDUNITDIR = $(shell $(PKGCONFIG) --variable=systemdsystemunitdir systemd)
17    INSTALLER_TTY = tty1
18    LOCALE =
19    
20  all:  all:
21   $(SED) -e 's:%VERSIONTAG%:$(VERSION):' \   $(SED) -e 's:%VERSIONTAG%:$(VERSION):' \
22   -e 'S:%LIBDIR%:$(LIBDIR):g'   -e 's:%LIBDIR%:$(LIBDIR):g' \
23     -e 's:%SYSCONFDIR%:$(SYSCONFDIR):g' \
24   bin/installer.sh.in \   bin/installer.sh.in \
25   > bin/installer.sh   > bin/installer.sh
26   $(SED) -e 's:%INSTALLER_TTY%:$(INSTALLER_TTY):g'  \   $(SED) -e 's:%INSTALLER_TTY%:$(INSTALLER_TTY):g' \
27   -e 's:%BINDIR%:$(BINDIR):g'  \   -e 's:%BINDIR%:$(BINDIR):g' \
28     -e 's:%LOCALE%:$(LOCALE):g' \
29   systemd/installer.service.in \   systemd/installer.service.in \
30   > systemd/installer.service   > systemd/installer.service
31    
# Line 32  create-dirs: Line 37  create-dirs:
37  install-files:  install-files:
38   $(INSTALL) -m 0644 conf/installer.conf $(DESTDIR)$(SYSCONFDIR)   $(INSTALL) -m 0644 conf/installer.conf $(DESTDIR)$(SYSCONFDIR)
39   $(INSTALL) -m 0755 bin/installer.sh $(DESTDIR)$(BINDIR)/installer   $(INSTALL) -m 0755 bin/installer.sh $(DESTDIR)$(BINDIR)/installer
40   $(INSTALL) -m 0644 functions/findhdd.sh $(DESTDIR)$(LIBDIR)/functions/   $(INSTALL) -m 0644 functions/common.sh $(DESTDIR)$(LIBDIR)/functions/
41     $(INSTALL) -m 0644 functions/common-dialogs.sh $(DESTDIR)$(LIBDIR)/functions/
42     $(INSTALL) -m 0644 functions/installer-dialogs.sh $(DESTDIR)$(LIBDIR)/functions/
43     $(INSTALL) -m 0644 functions/hwdetection.sh $(DESTDIR)$(LIBDIR)/functions/
44     $(INSTALL) -m 0644 functions/bootloader.sh $(DESTDIR)$(LIBDIR)/functions/
45     $(INSTALL) -m 0644 functions/grub.sh $(DESTDIR)$(LIBDIR)/functions/
46     $(INSTALL) -m 0644 functions/grub2.sh $(DESTDIR)$(LIBDIR)/functions/
47     $(INSTALL) -m 0644 functions/initrd-tools.sh $(DESTDIR)$(LIBDIR)/functions/
48     $(INSTALL) -m 0644 functions/dracut.sh $(DESTDIR)$(LIBDIR)/functions/
49     $(INSTALL) -m 0644 functions/mkinitrd.sh $(DESTDIR)$(LIBDIR)/functions/
50    
51  install-systemd  install-systemd:
52   $(INSTALL) -d $(DESTDIR)/$(SYSTEMDUNITDIR)   $(INSTALL) -d $(DESTDIR)/$(SYSTEMDUNITDIR)
53     $(INSTALL) -m 0644 systemd/installer.service $(DESTDIR)/$(SYSTEMDUNITDIR)
54   $(INSTALL) -d $(DESTDIR)/$(SYSTEMDUNITDIR)/local-fs.target.wants   $(INSTALL) -d $(DESTDIR)/$(SYSTEMDUNITDIR)/local-fs.target.wants
55   $(INSTALL) -m 0644 systemd/mnt-cdrom.mount $(DESTDIR)/$(SYSTEMDUNITDIR)   $(INSTALL) -m 0644 systemd/mnt-cdrom.mount $(DESTDIR)/$(SYSTEMDUNITDIR)
56   $(LN_S) ../mnt-cdrom.mount $(DESTDIR)/$(SYSTEMDUNITDIR)/local-fs.target.wants/mnt-cdrom.mount   $(LN_S) ../mnt-cdrom.mount $(DESTDIR)/$(SYSTEMDUNITDIR)/local-fs.target.wants/mnt-cdrom.mount
57    
58  install: create-dirs install-files install-systemd  install: create-dirs install-files install-systemd install-mo
59    
60    pot: locale/installer.pot
61     generate-po.sh --create-pot bin/installer.sh.in installer
62     generate-po.sh --append-pot functions/common.sh installer
63     generate-po.sh --append-pot functions/common-dialogs.sh installer
64     generate-po.sh --append-pot functions/installer-dialogs.sh installer
65     generate-po.sh --append-pot functions/hwdetection.sh installer
66     generate-po.sh --append-pot functions/bootloader.sh installer
67     generate-po.sh --append-pot functions/grub.sh installer
68     generate-po.sh --append-pot functions/grub2.sh installer
69     generate-po.sh --append-pot functions/initrd-tools.sh installer
70     generate-po.sh --append-pot functions/dracut.sh installer
71     generate-po.sh --append-pot functions/mkinitrd.sh installer
72     generate-po.sh --unique-pot bin/installer.sh.in installer
73     generate-po.sh --generate bin/installer.sh.in installer
74    
75    install-mo: locale/installer.pot
76     DESTDIR=$(DESTDIR) generate-po.sh --compile bin/installer.sh.in installer
77    
78  clean:  clean:
79   $(RM) -f bin/installer.sh   $(RM) -f bin/installer.sh
80   $(RM) -f systemd/installer.service   $(RM) -f systemd/installer.service
81     $(RM) -f locale/installer.pot.dump
82     $(RM) -f locale/installer.pot.fixed
83    
84  .PHONY: all install  .PHONY: all install

Legend:
Removed from v.2333  
changed lines
  Added in v.2508