2011-04-26 13:21:24 +02:00
|
|
|
# Makefile for livecd-tools
|
2022-06-26 10:55:57 +02:00
|
|
|
# Copyright (c) 2004-2022 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
2011-04-26 13:21:24 +02:00
|
|
|
# Released under the terms of the GNU GPLv3 license
|
|
|
|
|
|
|
|
NAME=livecd-tools
|
|
|
|
|
|
|
|
include VERSION
|
|
|
|
|
|
|
|
# System locations
|
|
|
|
prefix = /usr
|
|
|
|
exec_prefix = ${prefix}
|
|
|
|
sysconfdir = /etc
|
|
|
|
sbindir = /sbin
|
|
|
|
bindir = ${exec_prefix}/bin
|
2015-04-30 16:38:23 +02:00
|
|
|
libdir = ${prefix}/lib
|
2011-04-26 13:21:24 +02:00
|
|
|
mandir = ${prefix}/usr/share/man
|
|
|
|
datadir = ${prefix}/share
|
|
|
|
iconsdir = ${datadir}/icons/hicolor
|
|
|
|
sysconfigdir= ${sysconfdir}/sysconfig
|
2022-06-26 10:55:57 +02:00
|
|
|
localesdir = ${datadir}/locale
|
2011-04-26 13:21:24 +02:00
|
|
|
srcdir = .
|
|
|
|
|
|
|
|
DESTDIR =
|
|
|
|
INSTALL = /usr/bin/install
|
|
|
|
INSTALL_PROGRAM = ${INSTALL} -m 755
|
|
|
|
INSTALL_DATA = ${INSTALL} -m 644
|
|
|
|
INSTALL_DIR = ${INSTALL} -d -m 755
|
|
|
|
INSTALL_SCRIPT = ${INSTALL_PROGRAM}
|
|
|
|
SYSTEM_MENU_DIR = ${datadir}/applications
|
|
|
|
STATIC_DIR = /static
|
|
|
|
|
2011-08-25 21:37:48 +02:00
|
|
|
# package related variables
|
|
|
|
distdir = $(NAME)-$(VERSION)
|
|
|
|
dist_archive = $(distdir).tar.bz2
|
|
|
|
|
2011-04-26 13:21:24 +02:00
|
|
|
.SUFFIXES:
|
|
|
|
.SUFFIXES: .po .mo
|
|
|
|
.po.mo:; msgfmt $< -o $@
|
|
|
|
|
|
|
|
all: locales
|
|
|
|
|
|
|
|
locales: $(pck_catalogs:.po=.mo)
|
2022-06-26 11:01:02 +02:00
|
|
|
# lupdate calamares/etc/calamares/branding/openmamba/lang/calamares-openmamba_it.ts
|
|
|
|
lrelease-qt5 calamares/etc/calamares/branding/openmamba/lang/calamares-openmamba_it.ts
|
2011-04-26 13:21:24 +02:00
|
|
|
|
|
|
|
install-locales: locales
|
|
|
|
@for f in $(pck_catalogs); do\
|
|
|
|
lang=`echo $$f | sed 's,.*/\(.*\)\.po,\1,'`;\
|
|
|
|
echo "installing i18n file for language \`$$lang'...";\
|
|
|
|
dir="$(DESTDIR)$(localesdir)/$$lang/LC_MESSAGES";\
|
|
|
|
$(INSTALL_DIR) $$dir;\
|
|
|
|
done
|
|
|
|
|
|
|
|
install-dirs:
|
|
|
|
@$(INSTALL_DIR) $(DESTDIR)$(sbindir)
|
|
|
|
@$(INSTALL_DIR) $(DESTDIR)$(sysconfigdir)
|
|
|
|
@$(INSTALL_DIR) $(DESTDIR)$(SYSTEM_MENU_DIR)
|
2011-10-06 00:34:17 +02:00
|
|
|
@$(INSTALL_DIR) $(DESTDIR)/home/liveuser/
|
2011-10-21 01:51:01 +02:00
|
|
|
@$(INSTALL_DIR) $(DESTDIR)$(sysconfdir)/sudoers.d/
|
2013-05-25 21:32:52 +02:00
|
|
|
@$(INSTALL_DIR) $(DESTDIR)$(sysconfdir)/systemd/system/
|
2015-04-30 16:38:23 +02:00
|
|
|
@$(INSTALL_DIR) $(DESTDIR)$(libdir)/calamares/modules/
|
2011-04-26 13:21:24 +02:00
|
|
|
|
2022-06-26 10:55:57 +02:00
|
|
|
install: install-dirs install-locales
|
2013-05-25 21:32:52 +02:00
|
|
|
$(INSTALL_DATA) tools/autovt@.service $(DESTDIR)$(sysconfdir)/systemd/system/
|
2015-09-13 01:05:02 +02:00
|
|
|
$(INSTALL_DATA) tools/eject.service $(DESTDIR)$(sysconfdir)/systemd/system/
|
2011-10-30 18:08:48 +01:00
|
|
|
$(INSTALL_PROGRAM) liveuser-sudoers $(DESTDIR)$(sysconfdir)/sudoers.d/liveuser
|
2022-07-09 13:38:01 +02:00
|
|
|
$(INSTALL_DATA) calamares-installer.desktop $(DESTDIR)$(SYSTEM_MENU_DIR)
|
2015-04-30 16:38:23 +02:00
|
|
|
cp -a calamares/etc/calamares $(DESTDIR)$(sysconfdir)/
|
|
|
|
cp -a calamares/openmamba-postinstall $(DESTDIR)$(libdir)/calamares/modules/
|
2011-04-26 13:21:24 +02:00
|
|
|
|
|
|
|
clean:
|
|
|
|
|
|
|
|
dist: clean
|
2011-08-25 21:37:48 +02:00
|
|
|
@mkdir /tmp/$(distdir)
|
|
|
|
@cp -a * /tmp/$(distdir)/
|
|
|
|
@rm -f $(dist_archive);\
|
|
|
|
tar cf - -C /tmp $(distdir) | bzip2 -9 -c > $(dist_archive)
|
|
|
|
@rm -rf /tmp/$(distdir)
|
|
|
|
@echo "file \`$(dist_archive)' created"
|
2011-04-26 13:21:24 +02:00
|
|
|
|
|
|
|
dist-rpm: dist
|
|
|
|
@rpm_sourcedir=`rpm --eval=%{_sourcedir}`;\
|
2011-08-25 21:37:48 +02:00
|
|
|
mv -f $(dist_archive) $$rpm_sourcedir;\
|
|
|
|
echo "and saved as \`$$rpm_sourcedir/$(dist_archive)'"
|