branding-alt-virtualization.../Makefile.in
2019-05-15 16:56:45 +03:00

198 lines
9.8 KiB
Makefile

STATUS=@STATUS@
BRAND=@BRAND@
THEME=@THEME@
NAME=@NAME@
VERSION=@VERSION@
PRODUCT_NAME=@PRODUCT_NAME@
CODENAME=@CODENAME@
.PHONY: graphics browser-qt ahttpd boot-images boot-splash boot indexhtml install education-install
# graphics
# generate derivative graphics
graphics:
# make default wallpaper
cp -al images/background4x3.png images/wallpaper.png
cp -al images/background16x9.png backgrounds/default-wide.png
cp -al images/product-logo.png backgrounds/product-logo.png
cp -al images/wallpaper.png backgrounds/default.png
cp -al images/wallpaper.png backgrounds/xdm.png
# make wallpapers for gfxboot and grub2
# convert images/background4x3.png -resize 800x600 images/small.png
# display status
# convert images/small.png images/product-logo.png -geometry +30+30 -composite images/grub.png
# cp -al images/grub.png images/boot.png
# use predefined image 800x600 with logo
cp -al images/boot.png images/grub.png
# product logo for ahttpd
cp -al images/product-logo.png ahttpd/images/product-logo.png
# product logo for indexhtml
cp -al images/product-logo.png indexhtml/images/product-logo.png
# browser-qt
browser-qt/design/bg.png: images/installer.png
convert $< -fill '#c62530' -font /usr/share/fonts/ttf/dejavu/DejaVuSansCondensed-Bold.ttf -style Normal -weight Normal -pointsize 20 -gravity northeast -draw 'text 25,25 "$(STATUS)"' $@
browser-qt:browser-qt/design/bg.png
install -d $(datadir)/alterator-browser-qt/design
rcc-qt4 -binary browser-qt/theme.qrc -o $(datadir)/alterator-browser-qt/design/$(THEME).rcc
#cp -f browser-qt/design/design-live.qss browser-qt/design/design.qss
rcc-qt4 -binary browser-qt/theme.qrc -o $(datadir)/alterator-browser-qt/design/$(THEME)-live.rcc
install -d $(sysconfdir)/alternatives/packages.d
printf '/etc/alterator/design-browser-qt\t/usr/share/alterator-browser-qt/design/$(THEME).rcc\t50\n'>$(sysconfdir)/alternatives/packages.d/$(THEME).rcc
# ahttpd
ahttpd:
for i in ahttpd/images/*.svg; do \
image=$${i%.svg}; \
convert -background none $$image.svg $$image.png ; \
done
install -d $(datadir)/alterator/design/styles
cp -a ahttpd/images $(datadir)/alterator/design
cp -a ahttpd/styles/*.css $(datadir)/alterator/design/styles
# bootloader and bootsplash
boot-images:
cp -a /usr/src/design-bootloader-source ./
cp -a bootloader/config design-bootloader-source/
cp -a bootloader/gfxboot.cfg design-bootloader-source/data-install/
cp -a bootloader/gfxboot.cfg design-bootloader-source/data-boot/
#for size in 1024x768 800x600 640x480; do \
# convert images/boot.jpg -quality 97 -resize "$$size!" -fill '#c62530' -font /usr/share/fonts/ttf/dejavu/DejaVuSansCondensed-Bold.ttf -style Normal -weight Normal -pointsize 20 -gravity northeast -draw 'text 25,25 "$(STATUS)"' boot-$$size.jpg ;\
#done
#convert images/boot.png -resize "800x600!" -fill '#c62530' -font /usr/share/fonts/ttf/dejavu/DejaVuSansCondensed-Bold.ttf -style Normal -weight Normal -pointsize 20 -gravity northeast -draw 'text 25,25 "$(STATUS)"' design-bootloader-source/data-install/back.jpg
convert -colorspace YCbCr -sampling-factor 2x2 images/boot.png JPEG:images/boot.jpg
cp -al images/boot.jpg design-bootloader-source/data-boot/back.jpg
cp -al images/boot.jpg design-bootloader-source/data-install/back.jpg
mv design-bootloader-source/data-install/back{,.1}.jpg
convert -quality 97 -fill '#acdaf2' -draw 'rectangle 0,0,2,2' design-bootloader-source/data-install/back{.1,}.jpg
rm -f design-bootloader-source/data-install/back.*.jpg
#bootsplash
boot-splash: boot-images
mkdir -p $(datadir)/plymouth/themes/$(THEME)
cp -al images/grub.jpg $(datadir)/plymouth/themes/$(THEME)/grub.jpg
# Put logo to background*x*.png
cp -al images/with-logo/background*x*.png $(datadir)/plymouth/themes/$(THEME)/
cp -a bootsplash/* $(datadir)/plymouth/themes/$(THEME)
mv $(datadir)/plymouth/themes/$(THEME)/theme.plymouth $(datadir)/plymouth/themes/$(THEME)/$(THEME).plymouth
rm -f $(datadir)/plymouth/themes/$(THEME)/*.in
#bootloader
boot: boot-images
DEFAULT_LANG='--lang-to-subst--' PATH=$(PATH):/usr/sbin make -C design-bootloader-source
install -d -m 755 $(sysconfdir)/../boot/splash/$(THEME)
install -d -m 755 $(datadir)/gfxboot/$(THEME)
install -m 644 design-bootloader-source/message $(sysconfdir)/../boot/splash/$(THEME)
install -m 644 design-bootloader-source/bootlogo $(datadir)/gfxboot/$(THEME)
#install -m644 bootloader/bootlogo $(datadir)/gfxboot/$(THEME)
#grub2
convert -size 16x16 -define png:color-type=2 -depth 8 xc:'#268BD2' grub2/selected_blob_c.png
install -d -m 755 $(sysconfdir)/../boot/grub/themes/$(THEME)
cp -a grub2/* $(sysconfdir)/../boot/grub/themes/$(THEME)/
install -m 644 images/boot.png $(sysconfdir)/../boot/grub/themes/$(THEME)/boot.png
install -m 644 images/boot.jpg $(sysconfdir)/../boot/grub/themes/$(THEME)/grub.jpg
# index html page, start page for all local browsers
indexhtml/index.css:
sed 's|/design/|file:///usr/share/alterator/design/|g' ahttpd/styles/alterator.css > indexhtml/index.css
INDEXHTML_DIR=$(datadir)/doc/indexhtml
indexhtml: indexhtml/index.css
for i in indexhtml/*.html indexhtml/*.css;do \
install -Dpm644 $$i $(INDEXHTML_DIR)/`basename $$i`; \
done
install -Dpm644 /dev/null $(INDEXHTML_DIR)/index.html
cp -a indexhtml/images $(INDEXHTML_DIR)
for i in alt-docs documentation;do \
ln -s /usr/share/doc/$$i $(INDEXHTML_DIR)/$$i; \
done
install -Dpm644 indexhtml/indexhtml.desktop $(datadir)/applications/indexhtml.desktop
install -Dpm755 indexhtml/indexhtml.desktop $(datadir)/kde4/apps/kio_desktop/DesktopLinks/indexhtml.desktop
all: graphics
education-install:
# install product icon
for size in 16 22 24 32 48 64 128; do \
install -Dm 0644 icons/alt-education-$$size.png $(datadir)/icons/hicolor/$${size}x$${size}/apps/alt-education.png; \
done
install -Dm 0644 kde-settings/Education.profile $(datadir)/kf5/konsole/Education.profile
install -Dm 0644 kde-settings/konsolerc $(sysconfdir)/skel/.config/konsolerc
install: browser-qt ahttpd boot-images boot-splash @X86@ indexhtml education-install
install -d $(datadir)/design/{$(THEME),backgrounds}
install -d $(datadir)/icons/hicolor/32x32/apps
cp -a backgrounds icons faces $(datadir)/design/$(THEME)
ln -s ../../../wallpapers $(datadir)/design/$(THEME)/backgrounds/more
install -d $(sysconfdir)/alternatives/packages.d
echo "/usr/share/design-current /usr/share/design/$(THEME) 000012000000" >> $(sysconfdir)/alternatives/packages.d/branding-$(BRAND)-$(THEME)-graphics
echo "/usr/share/design/current /usr/share/design/$(THEME) 000012000000" >> $(sysconfdir)/alternatives/packages.d/branding-$(BRAND)-$(THEME)-graphics
#release
mkdir -p $(sysconfdir)/buildreqs/packages/ignore.d/
install -pD -m644 /dev/null $(sysconfdir)/buildreqs/packages/ignore.d/$(BRAND)-$(THEME)-release
echo "$(DISTRO_NAME) ($(CODENAME))" >$(sysconfdir)/altlinux-release
for n in fedora redhat system; do \
ln -s altlinux-release $(sysconfdir)/$$n-release; \
done
install -pD -m644 systemd/os-release $(sysconfdir)/os-release
#notes
cd notes; \
install -d $(datadir)/alt-notes; \
cp -a *.html $(datadir)/alt-notes; \
for relnotes in release-notes.*.html; do \
suffix="$${relnotes#release-notes.}"; \
ln -s $$relnotes $(datadir)/alt-notes/livecd-finish.$$suffix; \
done; \
cd ..
#kde-settings
cd kde-settings; \
mkdir -p $(sysconfdir)/skel/.kde4; \
cp -a kde4/* $(sysconfdir)/skel/.kde4/; \
mkdir -p $(sysconfdir)/kde4/xdg/menus/applications-merged/; \
install -m 0644 menu/*.menu $(sysconfdir)/kde4/xdg/menus/applications-merged/; \
install -Dm 0644 nm-applet.desktop $(sysconfdir)/skel/.config/autostart/nm-applet.desktop; \
cd ..
#fwvm-settings
mkdir -p $(sysconfdir)/skel
install -m 644 fvwm-settings/.fvwm2rc $(sysconfdir)/skel/
#mate-settings
cd mate-settings; \
install -Dm644 50_mate-background.gschema.override $(datadir)/glib-2.0/schemas/50_mate-background.gschema.override; \
install -Dm644 60_mate-theme.gschema.override $(datadir)/glib-2.0/schemas/60_mate-theme.gschema.override; \
install -Dm644 Trolltech.conf $(sysconfdir)/skel/.config/Trolltech.conf; \
cd ..
install -d $(sysconfdir)/skel
cp -r xfce-settings/etcskel/XDG-Templates.skel $(sysconfdir)/skel/
cp -r xfce-settings/etcskel/.[a-z]* $(sysconfdir)/skel/
install -Dm 644 xfce-settings/etcskel/registrymodifications.xcu $(sysconfdir)/skel/.config/libreoffice/4/user/registrymodifications.xcu
install -pDm0755 xfce-settings/scripts/zdg-move-templates.sh $(sysconfdir)/X11/profile.d/zdg-move-templates.sh
install -Dm 644 gnome-settings/gtkrc-2 $(sysconfdir)/skel/.gtkrc-2.0
install -Dm 644 gnome-settings/gtk3-settings.ini $(sysconfdir)/skel/.config/gtk-3.0/settings.ini
#slideshow
mkdir -p $(datadir)/install2/slideshow
mkdir -p $(sysconfdir)/alterator
cp -a slideshow/* $(datadir)/install2/slideshow/
install slideshow/slideshow.conf $(sysconfdir)/alterator/
# Set English slideshow as default
#ln -s slides-en $(datadir)/install2/slideshow/slides
#indexhtml
install -d $(datadir)/doc/indexhtml
cp -a indexhtml/{*.html,images} $(datadir)/doc/indexhtml
install -Dm755 indexhtml/indexhtml.desktop $(datadir)/kde4/apps/kio_desktop/DesktopLinks/indexhtml.desktop
install -Dm755 indexhtml/indexhtml.desktop $(datadir)/kf5/kio_desktop/DesktopLinks/indexhtml.desktop
install -Dm755 indexhtml/indexhtml.desktop $(datadir)/Desktop/indexhtml.desktop
#menu
mkdir -p $(datadir)/slinux-style/applications
install menu/applications/* $(datadir)/slinux-style/applications/
mkdir -p $(sysconfdir)/xdg/menus/xfce-applications-merged
cp menu/50-xfce-applications.menu $(sysconfdir)/xdg/menus/xfce-applications-merged/
mkdir -p $(datadir)/desktop-directories
cp menu/altlinux-wine.directory $(datadir)/desktop-directories/
# system-settings
mkdir -p $(sysconfdir)/polkit-1/rules.d/
cp -a system-settings/polkit-rules/*.rules $(sysconfdir)/polkit-1/rules.d/
#install -Dm644 system-settings/ldm_pam_environment $(localstatedir)/ldm/.pam_environment