Allow for specifying placeholders in shell scripts that are replaced during build time. Predefine a "@PACKAGE_VERSION@" placeholder that is replaced with the current version number. Also, rename all shell scripts to ".sh.in". Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
20 lines
361 B
Makefile
20 lines
361 B
Makefile
AUTOMAKE_OPTIONS = foreign
|
|
|
|
dist_bin_SCRIPTS = \
|
|
calcurse-upgrade
|
|
|
|
EXTRA_DIST = \
|
|
calcurse-upgrade.sh.in
|
|
|
|
CLEANFILES = \
|
|
calcurse-upgrade
|
|
|
|
edit = sed \
|
|
-e 's|@PACKAGE_VERSION[@]|$(PACKAGE_VERSION)|g'
|
|
|
|
calcurse-upgrade: calcurse-upgrade.sh.in
|
|
$(AM_V_at)$(RM) "$@"
|
|
$(AM_V_GEN)$(edit) <"$(srcdir)/$<" >"$@"
|
|
$(AM_V_at)chmod +x "$@"
|
|
$(AM_V_at)chmod a-w "$@"
|