--- trunk/installer-simple/Makefile 2014/01/03 22:52:43 2347 +++ trunk/installer-simple/Makefile 2014/01/07 15:00:24 2449 @@ -1,10 +1,6 @@ # $Id$ -VERSION = $(shell cat VERSION) -SYSTEMDUNITDIR = $(shell pkg-config --variable=systemdsystemunitdir systemd) -INSTALLER_TTY = tty1 - -SYSCONFDIR = etc +SYSCONFDIR = /etc PREFIX = /usr LIBDIR = $(PREFIX)/lib/installer BINDIR = $(PREFIX)/bin @@ -13,10 +9,16 @@ INSTALL = install LN_S = ln -snf RM = rm +CAT = cat +PKGCONFIG = pkg-config + +VERSION = $(shell $(CAT) VERSION) +SYSTEMDUNITDIR = $(shell $(PKGCONFIG) --variable=systemdsystemunitdir systemd) +INSTALLER_TTY = tty1 all: $(SED) -e 's:%VERSIONTAG%:$(VERSION):' \ - -e 'S:%LIBDIR%:$(LIBDIR):g' + -e 's:%LIBDIR%:$(LIBDIR):g' \ bin/installer.sh.in \ > bin/installer.sh $(SED) -e 's:%INSTALLER_TTY%:$(INSTALLER_TTY):g' \ @@ -32,7 +34,16 @@ install-files: $(INSTALL) -m 0644 conf/installer.conf $(DESTDIR)$(SYSCONFDIR) $(INSTALL) -m 0755 bin/installer.sh $(DESTDIR)$(BINDIR)/installer + $(INSTALL) -m 0644 functions/common.sh $(DESTDIR)$(LIBDIR)/functions/ + $(INSTALL) -m 0644 functions/common-dialogs.sh $(DESTDIR)$(LIBDIR)/functions/ + $(INSTALL) -m 0644 functions/installer-dialogs.sh $(DESTDIR)$(LIBDIR)/functions/ $(INSTALL) -m 0644 functions/hwdetection.sh $(DESTDIR)$(LIBDIR)/functions/ + $(INSTALL) -m 0644 functions/bootloader.sh $(DESTDIR)$(LIBDIR)/functions/ + $(INSTALL) -m 0644 functions/grub.sh $(DESTDIR)$(LIBDIR)/functions/ + $(INSTALL) -m 0644 functions/grub2.sh $(DESTDIR)$(LIBDIR)/functions/ + $(INSTALL) -m 0644 functions/initrd-tools.sh $(DESTDIR)$(LIBDIR)/functions/ + $(INSTALL) -m 0644 functions/dracut.sh $(DESTDIR)$(LIBDIR)/functions/ + $(INSTALL) -m 0644 functions/mkinitrd.sh $(DESTDIR)$(LIBDIR)/functions/ install-systemd: $(INSTALL) -d $(DESTDIR)/$(SYSTEMDUNITDIR) @@ -42,6 +53,16 @@ install: create-dirs install-files install-systemd +pot: locale/installer.pot + generate-po.sh --create-pot bin/installer.sh.in installer + generate-po.sh --append-pot functions/common.sh installer + generate-po.sh --append-pot functions/common-dialogs.sh installer + generate-po.sh --append-pot functions/installer-dialogs.sh installer + generate-po.sh --append-pot functions/hwdetection.sh installer + generate-po.sh --generate bin/installer.sh.in installer +install-mo: locale/installer.pot + DESTDIR=$(DESTDIR) generate-po.sh --compile bin/installer.sh.in installer + clean: $(RM) -f bin/installer.sh $(RM) -f systemd/installer.service