-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile.am
134 lines (102 loc) · 3.2 KB
/
Makefile.am
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
# Makefile.am
SUBDIRS = data
gvg_version = $(top_srcdir)/.version
pkg_name = $(top_srcdir)/.package-name
pkg_release = $(PACKAGE)-release
cmake = cmake
gnulib_tool = gnulib-tool
vc_list_files = vc-list-files
gnulib_scripts = $(gnulib_tool) \
$(vc_list_files)
gnupgdir = $(homedir)/.gnupg
gpg_agent_conf = $(gnupgdir)/gpg-agent.conf
install_data_targets =
uninstall_targets =
ACLOCAL_AMFLAGS = -I m4 -I .quickhatch/m4
BUILT_SOURCES = $(gvg_version) \
$(pkg_name)
dist_toolbox_DATA = $(pkg_release)
CLEANFILES = $(gvg_version) \
$(pkg_name) \
$(pkg_release)
EXTRA_DIST = $(gvg_version) \
m4/gnulib-cache.m4 \
$(pkg_name) \
README.md
AM_DISTCHECK_CONFIGURE_FLAGS = HOME=$(top_distdir)
if !ENABLE_AWS_CLI
AM_DISTCHECK_CONFIGURE_FLAGS += --disable-aws-cli
endif
if !ENABLE_CONAN
AM_DISTCHECK_CONFIGURE_FLAGS += --disable-conan
endif
if !ENABLE_VIM_CMAKE
AM_DISTCHECK_CONFIGURE_FLAGS += --disable-vim-cmake
endif
AM_DISTCHECK_CONFIGURE_FLAGS += --disable-vim-plug-install
$(gvg_version):
$(AM_V_GEN)echo $(VERSION) > $@-t && mv $@-t $@
$(pkg_name):
$(AM_V_GEN)echo $(PACKAGE_NAME) > $@-t && mv $@-t $@
$(pkg_release): $(gvg_version)
$(AM_V_GEN)echo "$(PACKAGE) release $(VERSION)" > $@-t && mv $@-t $@
.PHONY: gen-ChangeLog
gen-ChangeLog:
$(AM_V_GEN)if test -d .git; then \
$(top_srcdir)/build-aux/gitlog-to-changelog > $(distdir)/cl-t;\
rm -f $(distdir)/ChangeLog; \
mv $(distdir)/cl-t $(distdir)/ChangeLog; \
fi
.PHONY: gen-tarball-version
gen-tarball-version:
$(AM_V_GEN)echo $(VERSION) > $(distdir)/.tarball-version
.PHONY: mk-bindir
mk-bindir:
$(AM_V_GEN)test -e $(DESTDIR)$(bindir) \
|| $(MKDIR_P) $(DESTDIR)$(bindir)
$(cmake): mk-bindir
$(AM_V_GEN)cd $(DESTDIR)$(bindir) && \
test -h $@ || $(LN_S) $(CMAKE) $@
$(gnulib_tool): mk-bindir
$(AM_V_GEN)cd $(DESTDIR)$(bindir) && \
test -h $@ || $(LN_S) $(GNULIB_REFDIR)/$@ $@
$(vc_list_files): mk-bindir
$(AM_V_GEN)cd $(DESTDIR)$(bindir) && \
test -h $@ || $(LN_S) $(GNULIB_REFDIR)/build-aux/$@ $@
.PHONY: rm-cmake
rm-cmake:
$(AM_V_GEN)cd $(DESTDIR)$(bindir) && \
rm -f $(cmake)
.PHONY: rm-gnulib-scripts
rm-gnulib-scripts:
$(AM_V_GEN)cd $(DESTDIR)$(bindir) && \
rm -f $(gnulib_scripts)
if HAVE_GNULIB_REFDIR
install_data_targets += $(gnulib_scripts)
uninstall_targets += rm-gnulib-scripts
endif
if HAVE_CMAKE3
install_data_targets += $(cmake)
uninstall_targets += rm-cmake
endif
.PHONY: mk-gnupgdir
mk-gnupgdir:
$(AM_V_GEN)test -e $(DESTDIR)$(gnupgdir) || \
$(MKDIR_P) -m 0700 $(DESTDIR)$(gnupgdir)
.PHONY: gpg-agent-pinentry-mac
gpg-agent-pinentry-mac: mk-gnupgdir
$(AM_V_GEN)$(GREP) '^pinentry-program' $(DESTDIR)$(gpg_agent_conf) &>/dev/null || \
printf 'pinentry-program %s\n' $(PINENTRY_MAC) >>$(DESTDIR)$(gpg_agent_conf)
.PHONY: rm-gpg-agent-pinentry-mac
rm-gpg-agent-pinentry-mac: mk-gnupgdir
$(AM_V_GEN)$(GREP) -v '^pinentry-program $(PINENTRY_MAC)' $(DESTDIR)$(gpg_agent_conf) &>/dev/null || \
rm $(DESTDIR)$(gpg_agent_conf)
if HAVE_GPG_AGENT
if HAVE_PINENTRY_MAC
install_data_targets += gpg-agent-pinentry-mac
uninstall_targets += rm-gpg-agent-pinentry-mac
endif
endif
install-data-hook: $(install_data_targets)
uninstall-hook: $(uninstall_targets)
dist-hook: gen-ChangeLog gen-tarball-version