Initial revision
[TestXSLT.git] / libiconv / src / Makefile.in
1 # Makefile for libiconv/src
2
3 #### Start of system configuration section. ####
4
5 # Directories used by "make":
6 srcdir = @srcdir@
7
8 # Directories used by "make install":
9 prefix = @prefix@
10 local_prefix = /usr/local
11 exec_prefix = @exec_prefix@
12 bindir = @bindir@
13 libdir = @libdir@
14 datadir = @datadir@
15 localedir = $(datadir)/locale
16
17 # Programs used by "make":
18 CC = @CC@
19 CFLAGS = @CFLAGS@
20 CPPFLAGS = @CPPFLAGS@
21 LDFLAGS = @LDFLAGS@
22 INCLUDES = -I. -I$(srcdir) -I../include -I$(srcdir)/../include
23 LIBTOOL = @LIBTOOL@
24 LIBTOOL_COMPILE = $(LIBTOOL) --mode=compile
25 LIBTOOL_LINK = $(LIBTOOL) --mode=link
26 LIBTOOL_INSTALL = $(LIBTOOL) --mode=install
27 LIBTOOL_UNINSTALL = $(LIBTOOL) --mode=uninstall
28 RM = rm -f
29 @SET_MAKE@
30
31 # Programs used by "make install":
32 INSTALL = @INSTALL@
33 INSTALL_PROGRAM = @INSTALL_PROGRAM@
34 INSTALL_DATA = @INSTALL_DATA@
35
36 #### End of system configuration section. ####
37
38 SHELL = /bin/sh
39
40 # Needed by $(LIBTOOL).
41 top_builddir = ..
42
43 # We cannot link with libintl until libiconv is installed. (When we call
44 # libtool with arguments "../lib/libiconv.la -lintl", libtool will call ld
45 # with "../lib/.libs/libiconv.so $libdir/libintl.so $libdir/libiconv.so",
46 # (remember that $libdir/libintl.la lists $libdir/libiconv.so as a dependency),
47 # and this gives a fatal linker error on Solaris because the two libiconv.so
48 # files are different but have the same soname.
49 # So we can link the iconv executable only after we have installed libiconv,
50 # i.e. during "make install". The intermediate 'iconv' executable is built
51 # without internationalization and not linked with libintl.
52
53 all : iconv_no_i18n iconv.@OBJEXT@
54         chmod 777 .
55
56 # This is the temporary iconv executable, without internationalization.
57 iconv_no_i18n : iconv_no_i18n.@OBJEXT@ ../lib/libiconv.la
58         $(LIBTOOL_LINK) $(CC) $(LDFLAGS) iconv_no_i18n.@OBJEXT@ ../lib/libiconv.la -o $@
59
60 iconv_no_i18n.@OBJEXT@ : $(srcdir)/iconv_no_i18n.c $(srcdir)/iconv.c
61         $(CC) -c $(INCLUDES) -I../lib $(CFLAGS) $(CPPFLAGS) -DLOCALEDIR=\"$(localedir)\" $(srcdir)/iconv_no_i18n.c
62
63 iconv.@OBJEXT@ : $(srcdir)/iconv.c
64         $(CC) -c $(INCLUDES) -I../lib $(CFLAGS) $(CPPFLAGS) -DLOCALEDIR=\"$(localedir)\" $(srcdir)/iconv.c
65
66 # The following rule is necessary to avoid a toplevel "make -n check" failure.
67 ../lib/libiconv.la :
68         cd ../lib && $(MAKE) libiconv.la
69
70 # During "make install", we can build the final iconv executable.
71 # On HP-UX, in order to ensure that the new libiconv.sl will override the old
72 # one that is hardcoded in libintl.sl, we need to mention libiconv.sl before
73 # libintl.sl on the link command line. We have to bypass libtool in order to
74 # achieve this.
75 install : all force
76         if [ ! -d $(DESTDIR)$(prefix) ] ; then mkdir $(DESTDIR)$(prefix) ; fi
77         if [ ! -d $(DESTDIR)$(exec_prefix) ] ; then mkdir $(DESTDIR)$(exec_prefix) ; fi
78         if [ ! -d $(DESTDIR)$(bindir) ] ; then mkdir $(DESTDIR)$(bindir) ; fi
79         case "@host_os@" in \
80           hpux*) $(CC) $(LDFLAGS) iconv.@OBJEXT@ -L$(libdir) -liconv @LIBINTL@ -o iconv;; \
81           *) $(LIBTOOL_LINK) $(CC) $(LDFLAGS) iconv.@OBJEXT@ $(libdir)/libiconv.la @LTLIBINTL@ -o iconv;; \
82         esac
83         $(LIBTOOL_INSTALL) $(INSTALL_PROGRAM) iconv $(DESTDIR)$(bindir)/iconv
84
85 installdirs : force
86         if [ ! -d $(DESTDIR)$(prefix) ] ; then mkdir $(DESTDIR)$(prefix) ; fi
87         if [ ! -d $(DESTDIR)$(exec_prefix) ] ; then mkdir $(DESTDIR)$(exec_prefix) ; fi
88         if [ ! -d $(DESTDIR)$(bindir) ] ; then mkdir $(DESTDIR)$(bindir) ; fi
89
90 uninstall : force
91         $(LIBTOOL_UNINSTALL) $(RM) $(DESTDIR)$(bindir)/iconv
92
93 check : all
94
95 mostlyclean : clean
96
97 clean : force
98         $(RM) *.@OBJEXT@ *.lo iconv_no_i18n iconv core
99         $(RM) -r .libs _libs
100
101 distclean : clean
102         $(RM) Makefile config.h
103
104 maintainer-clean : distclean
105
106 force :
107