source: trunk/essentials/sys-devel/automake-1.9/lib/am/libs.am

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

automake 1.9.6

File size: 3.1 KB
Line 
1## automake - create Makefile.in from Makefile.am
2## Copyright (C) 1994, 1995, 1996, 1998, 1999, 2001, 2002, 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., 51 Franklin Street, Fifth Floor, Boston, MA
18## 02110-1301, USA.
19
20if %?INSTALL%
21include inst-vars.am
22endif %?INSTALL%
23
24## ------------ ##
25## Installing. ##
26## ------------ ##
27
28if %?INSTALL%
29am__installdirs += "$(DESTDIR)$(%NDIR%dir)"
30?BASE?%DIR%LIBRARIES_INSTALL = $(INSTALL_DATA)
31?!BASE?%DIR%LIBRARIES_INSTALL = $(install_sh_DATA)
32?EXEC?.PHONY install-exec-am: install-%DIR%LIBRARIES
33?!EXEC?.PHONY install-data-am: install-%DIR%LIBRARIES
34install-%DIR%LIBRARIES: $(%DIR%_LIBRARIES)
35 @$(NORMAL_INSTALL)
36 test -z "$(%NDIR%dir)" || $(mkdir_p) "$(DESTDIR)$(%NDIR%dir)"
37## Funny invocation because Makefile variable can be empty, leading to
38## a syntax error in sh.
39 @list='$(%DIR%_LIBRARIES)'; for p in $$list; do \
40 if test -f $$p; then \
41## Compute basename of source file. Unless this is a nobase_ target, we
42## want to install 'python/foo.py' as '$(DESTDIR)$(%NDIR%dir)/foo.yo',
43## not '$(DESTDIR)$(%NDIR%dir)/python/foo.yo'.
44?BASE? f=$(am__strip_dir) \
45?!BASE? f=$$p; \
46 echo " $(%DIR%LIBRARIES_INSTALL) '$$p' '$(DESTDIR)$(%NDIR%dir)/$$f'"; \
47 $(%DIR%LIBRARIES_INSTALL) "$$p" "$(DESTDIR)$(%NDIR%dir)/$$f"; \
48 else :; fi; \
49 done
50## We do two loops here so that $(POST_INSTALL) can be empty. If we
51## merge the two loops, we get a syntax error from sh. Anyway, having
52## $(POST_INSTALL) in the middle of the loop essentially renders it
53## useless; sh never actually executes this command. Read the GNU
54## Standards for a little enlightenment on this.
55 @$(POST_INSTALL)
56 @list='$(%DIR%_LIBRARIES)'; for p in $$list; do \
57 if test -f $$p; then \
58?BASE? p=$(am__strip_dir) \
59## Must ranlib after installing because mod time changes.
60 echo " $(RANLIB) '$(DESTDIR)$(%NDIR%dir)/$$p'"; \
61 $(RANLIB) "$(DESTDIR)$(%NDIR%dir)/$$p"; \
62 else :; fi; \
63 done
64endif %?INSTALL%
65
66
67## -------------- ##
68## Uninstalling. ##
69## -------------- ##
70
71if %?INSTALL%
72.PHONY uninstall-am: uninstall-%DIR%LIBRARIES
73uninstall-%DIR%LIBRARIES:
74 @$(NORMAL_UNINSTALL)
75 @list='$(%DIR%_LIBRARIES)'; for p in $$list; do \
76?BASE? p=$(am__strip_dir) \
77 echo " rm -f '$(DESTDIR)$(%NDIR%dir)/$$p'"; \
78 rm -f "$(DESTDIR)$(%NDIR%dir)/$$p"; \
79 done
80endif %?INSTALL%
81
82
83## ---------- ##
84## Cleaning. ##
85## ---------- ##
86
87.PHONY clean-am: clean-%DIR%LIBRARIES
88clean-%DIR%LIBRARIES:
89 -test -z "$(%DIR%_LIBRARIES)" || rm -f $(%DIR%_LIBRARIES)
Note: See TracBrowser for help on using the repository browser.