1 # Makefile.sub for `src utils afmtodit'
3 # File position: <groff-source>/src/utils/afmtodit/Makefile.sub
5 # Copyright (C) 2013-2014 Free Software Foundation, Inc.
7 # This file is part of groff.
9 # groff is free software; you can redistribute it and/or modify it under
10 # the terms of the GNU General Public License as published by the Free
11 # Software Foundation, either version 3 of the License, or
12 # (at your option) any later version.
14 # groff is distributed in the hope that it will be useful, but WITHOUT ANY
15 # WARRANTY; without even the implied warranty of MERCHANTABILITY or
16 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
19 # You should have received a copy of the GNU General Public License
20 # along with this program. If not, see <http://www.gnu.org/licenses/>.
22 ########################################################################
25 MOSTLYCLEANADD=afmtodit
30 afmtodit: afmtodit.pl afmtodit.tables
31 if test -n "$(PERL)"; then \
32 sed -e "s|/usr/bin/perl|$(PERL)|" \
33 -e "s|@VERSION@|$(version)$(revision)|" \
34 -e "s|@FONTDIR@|$(fontdir)|" \
35 -e "/@afmtodit.tables@/ r $(srcdir)/afmtodit.tables" \
36 -e "/@afmtodit.tables@/ d" \
37 $(srcdir)/afmtodit.pl >afmtodit; \
39 sed -e "s|@VERSION@|$(version)$(revision)|" \
40 -e "s|@FONTDIR@|$(fontdir)|" \
41 -e "/@afmtodit.tables@/ r $(srcdir)/afmtodit.tables" \
42 -e "/@afmtodit.tables@/ d" \
43 $(srcdir)/afmtodit.pl >afmtodit; \
47 install_data: afmtodit
48 -test -d $(DESTDIR)$(bindir) || $(mkinstalldirs) $(DESTDIR)$(bindir)
49 $(RM) $(DESTDIR)$(bindir)/afmtodit
50 $(INSTALL_SCRIPT) afmtodit $(DESTDIR)$(bindir)/afmtodit
53 $(RM) $(DESTDIR)$(bindir)/afmtodit
55 ########################################################################
57 ########################################################################