2 ## PSPP - a program for statistical analysis.
3 ## Copyright (C) 2020 Free Software Foundation, Inc.
5 ## This program is free software: you can redistribute it and/or modify
6 ## it under the terms of the GNU General Public License as published by
7 ## the Free Software Foundation, either version 3 of the License, or
8 ## (at your option) any later version.
10 ## This program is distributed in the hope that it will be useful,
11 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
12 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 ## GNU General Public License for more details.
15 ## You should have received a copy of the GNU General Public License
16 ## along with this program. If not, see <http://www.gnu.org/licenses/>.
18 # This makefile is used to generate the artifacts needed by the
22 # In order to get this makefile to work there are several programs
23 # which need to be found on $PATH. Using debian 10.5 you can install
25 # apt-get install xdotool xvfb imagemagick x11-apps
27 # apt-get install xserver-xephyr
31 top_srcdir=%top_srcdir%
32 abs_builddir=%abs_builddir%
33 src_ui_gui_psppiredir=%src_ui_gui_psppiredir%
41 ## The ui files must be installed in order for screenshots to succeed
42 installed_ui_files=${subst src/ui/gui,$(src_ui_gui_psppiredir),$(UI_FILES)}
45 $(MAKE) -f Makefile $@
49 # Generate a X11 window dump based on a .grab file
51 # Default theme for web pages
52 $(top_srcdir)/doc/screenshots/%-ad.xwd: src/ui/gui/psppire $(top_srcdir)/doc/screengrab $(top_srcdir)/doc/screenshots/%.grab $(installed_ui_files)
54 bash ${word 2,$^} --application=$< --topsrcdir=$(top_srcdir) --x-server=$(XSERVER) --theme=Adwaita --payload=${word 3,$^} $@
56 # High Contrast theme for printed manuals
57 $(top_srcdir)/doc/screenshots/%-hc.xwd: src/ui/gui/psppire $(top_srcdir)/doc/screengrab $(top_srcdir)/doc/screenshots/%.grab $(installed_ui_files)
59 bash ${word 2,$^} --application=$< --topsrcdir=$(top_srcdir) --x-server=$(XSERVER) --theme=HighContrast --payload=${word 3,$^} $@
61 .PRECIOUS: $(top_srcdir)/doc/screenshots/%-ad.xwd $(top_srcdir)/doc/screenshots/%-hc.xwd
68 convert -strip $< $@,tmp.eps
69 sed -e '/^%%CreationDate: /d' -e '/^%%Title: /s|$(top_srcdir)/||' $@,tmp.eps > $@
71 $(src_ui_gui_psppiredir)/%.ui: $(top_srcdir)/src/ui/gui/%.ui
79 $(MAKE) -f Makefile $@
83 (cd $(top_srcdir)/doc/screenshots; md5sum *.xwd)
88 $(RM) $(top_srcdir)/doc/screenshots/*.xwd