source: trunk/essentials/sys-devel/automake-1.8/lib/am/data.am

Last change on this file was 3118, checked in by bird, 18 years ago

automake 1.8.5

File size: 3.0 KB
Line 
1## automake - create Makefile.in from Makefile.am
2## Copyright (C) 1994, 1995, 1996, 1998, 1999, 2001, 2003, 2004
3## Free Software Foundation, Inc.
4
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 2, or (at your option)
8## any later version.
9
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.
14
15## You should have received a copy of the GNU General Public License
16## along with this program; if not, write to the Free Software
17## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
18## 02111-1307, USA.
19
20## ------------ ##
21## Installing. ##
22## ------------ ##
23
24if %?INSTALL%
25am__installdirs += "$(DESTDIR)$(%NDIR%dir)"
26?BASE?%DIR%%PRIMARY%_INSTALL = $(INSTALL_%ONE_PRIMARY%)
27?!BASE?%DIR%%PRIMARY%_INSTALL = $(install_sh_DATA)
28?EXEC?.PHONY install-exec-am: install-%DIR%%PRIMARY%
29?!EXEC?.PHONY install-data-am: install-%DIR%%PRIMARY%
30install-%DIR%%PRIMARY%: $(%DIR%_%PRIMARY%)
31 @$(NORMAL_INSTALL)
32 test -z "$(%NDIR%dir)" || $(mkdir_p) "$(DESTDIR)$(%NDIR%dir)"
33?!BASE? @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
34## Funny invocation because Makefile variable can be empty, leading to
35## a syntax error in sh.
36?!BASE? list='$(%DIR%_%PRIMARY%)'; for p in $$list; do \
37?BASE? @list='$(%DIR%_%PRIMARY%)'; for p in $$list; do \
38## A file can be in the source directory or the build directory.
39 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
40## If the _%PRIMARY% variable has an entry like foo/bar, install it as
41## $(destdir)/bar, not $(destdir)/foo/bar. The user can make a
42## new dir variable or use a nobase_ target for the latter case.
43?BASE? f="`echo $$p | sed -e 's|^.*/||'`"; \
44?!BASE? case $$p in \
45?!BASE? $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
46?!BASE? *) f=$$p;; \
47?!BASE? esac; \
48 echo " $(%DIR%%PRIMARY%_INSTALL) '$$d$$p' '$(DESTDIR)$(%NDIR%dir)/$$f'"; \
49 $(%DIR%%PRIMARY%_INSTALL) "$$d$$p" "$(DESTDIR)$(%NDIR%dir)/$$f"; \
50 done
51endif %?INSTALL%
52
53
54## -------------- ##
55## Uninstalling. ##
56## -------------- ##
57
58if %?INSTALL%
59.PHONY uninstall-am: uninstall-%DIR%%PRIMARY%
60uninstall-%DIR%%PRIMARY%:
61 @$(NORMAL_UNINSTALL)
62?!BASE? @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
63?!BASE? list='$(%DIR%_%PRIMARY%)'; for p in $$list; do \
64?BASE? @list='$(%DIR%_%PRIMARY%)'; for p in $$list; do \
65?BASE? f="`echo $$p | sed -e 's|^.*/||'`"; \
66?!BASE? case $$p in \
67?!BASE? $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
68?!BASE? *) f=$$p;; \
69?!BASE? esac; \
70 echo " rm -f '$(DESTDIR)$(%NDIR%dir)/$$f'"; \
71 rm -f "$(DESTDIR)$(%NDIR%dir)/$$f"; \
72 done
73endif %?INSTALL%
74
75
76## ---------- ##
77## Cleaning. ##
78## ---------- ##
79
80## Nothing.
81
82
83## -------------- ##
84## Distributing. ##
85## -------------- ##
86
87if %?DIST%
88DIST_COMMON += %DISTVAR%
89endif %?DIST%
Note: See TracBrowser for help on using the repository browser.