qt: Fix use of dangling pointer in QApplication
[pinentry.git] / Makefile.am
1 # Makefile.am
2 # Copyright (C) 2002, 2012, 2015 g10 Code GmbH
3 #
4 # This file is part of PINENTRY.
5 #
6 # PINENTRY is free software; you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by
8 # the Free Software Foundation; either version 2 of the License, or
9 # (at your option) any later version.
10 #
11 # PINENTRY is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14 # GNU General Public License for more details.
15 #
16 # You should have received a copy of the GNU General Public License
17 # along with this program; if not, see <https://www.gnu.org/licenses/>.
18 # SPDX-License-Identifier: GPL-2.0+
19
20 ## Process this file with automake to produce Makefile.in
21
22 ACLOCAL_AMFLAGS = -I m4
23 DISTCHECK_CONFIGURE_FLAGS = --disable-pinentry-qt --enable-pinentry-emacs
24
25 GITLOG_TO_CHANGELOG=gitlog-to-changelog
26
27 EXTRA_DIST = autogen.sh autogen.rc README.GIT ChangeLog-old \
28              build-aux/gitlog-to-changelog \
29              build-aux/git-log-fix build-aux/git-log-footer
30
31 if BUILD_PINENTRY_CURSES
32 pinentry_curses = curses
33 else
34 pinentry_curses =
35 endif
36
37 if BUILD_PINENTRY_TTY
38 pinentry_tty = tty
39 else
40 pinentry_tty =
41 endif
42
43 if BUILD_PINENTRY_EMACS
44 pinentry_emacs = emacs
45 else
46 pinentry_emacs =
47 endif
48
49 if BUILD_PINENTRY_GTK_2
50 pinentry_gtk_2 = gtk+-2
51 else
52 pinentry_gtk_2 =
53 endif
54
55 if BUILD_PINENTRY_GNOME_3
56 pinentry_gnome_3 = gnome3
57 else
58 pinentry_gnome_3 =
59 endif
60
61 if BUILD_PINENTRY_QT
62 pinentry_qt = qt
63 else
64 pinentry_qt =
65 endif
66
67 if BUILD_PINENTRY_TQT
68 pinentry_tqt = tqt
69 else
70 pinentry_tqt =
71 endif
72
73 if BUILD_PINENTRY_W32
74 pinentry_w32 = w32
75 else
76 pinentry_w32 =
77 endif
78
79 if BUILD_PINENTRY_FLTK
80 pinentry_fltk = fltk
81 else
82 pinentry_fltk =
83 endif
84
85 if BUILD_PINENTRY_EFL
86 pinentry_efl = efl
87 else
88 pinentry_efl =
89 endif
90
91 if BUILD_DOC
92 doc = doc
93 else
94 doc =
95 endif
96
97 SUBDIRS = m4 secmem pinentry ${pinentry_curses} ${pinentry_tty} \
98         ${pinentry_emacs} ${pinentry_gtk_2} ${pinentry_gnome_3} \
99         ${pinentry_qt} ${pinentry_tqt} ${pinentry_w32} \
100         ${pinentry_fltk} ${pinentry_efl} ${doc}
101
102
103 install-exec-local:
104         @list='$(bin_PROGRAMS)'; for p in $$list; do \
105           echo "  $(SETCAP) cap_ipc_lock+p $(DESTDIR)$(bindir)/`echo $$p|sed 's/$(EXEEXT)$$//'|sed '$(transform)'|sed 's/$$/$(EXEEXT)/'`"; \
106           $(SETCAP) cap_ipc_lock+p $(DESTDIR)$(bindir)/`echo $$p|sed 's/$(EXEEXT)$$//'|sed '$(transform)'|sed 's/$$/$(EXEEXT)/'` || true; \
107         done
108
109         (cd $(DESTDIR)$(bindir); \
110         rm -f pinentry; \
111         $(LN_S) $(PINENTRY_DEFAULT)$(EXEEXT) pinentry)
112
113 dist-hook: gen-ChangeLog
114         echo "$(VERSION)" > $(distdir)/VERSION
115
116 distcheck-hook:
117         set -e; ( \
118         pref="#+macro: pinentry_" ;\
119         reldate="$$(date -u +%Y-%m-%d)" ;\
120         echo "$${pref}ver  $(PACKAGE_VERSION)"  ;\
121         echo "$${pref}date $${reldate}" ;\
122         list='$(DIST_ARCHIVES)'; for i in $$list; do \
123           case "$$i" in *.tar.bz2) \
124             echo "$${pref}size $$(wc -c <$$i|awk '{print int($$1/1024)}')k" ;\
125             echo "$${pref}sha1 $$(sha1sum <$$i|cut -d' ' -f1)" ;\
126             echo "$${pref}sha2 $$(sha256sum <$$i|cut -d' ' -f1)" ;;\
127           esac;\
128         done ) | tee $(distdir).swdb
129
130
131 gen_start_date = 2012-08-08T00:00:00
132 .PHONY: gen-ChangeLog
133 gen-ChangeLog:
134         if test -d $(top_srcdir)/.git; then                             \
135           (cd $(top_srcdir) &&                                          \
136             $(GITLOG_TO_CHANGELOG) --append-dot --tear-off              \
137             --amend=build-aux/git-log-fix                               \
138             --since=$(gen_start_date) ) > $(distdir)/cl-t;              \
139           cat $(top_srcdir)/build-aux/git-log-footer >> $(distdir)/cl-t;\
140           rm -f $(distdir)/ChangeLog;                                   \
141           mv $(distdir)/cl-t $(distdir)/ChangeLog;                      \
142         fi