OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [branches/] [newlib/] [newlib/] [newlib/] [libc/] [Makefile.in] - Blame information for rev 39

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 39 lampret
# Makefile for newlib/libc.
2
# Copyright (c) 1994, 1995, 1997 Cygnus Support.
3
# All rights reserved.
4
#
5
# Redistribution and use in source and binary forms are permitted
6
# provided that the above copyright notice and this paragraph are
7
# duplicated in all such forms and that any documentation,
8
# advertising materials, and other materials related to such
9
# distribution and use acknowledge that the software was developed
10
# at Cygnus Support, Inc.  Cygnus Support, Inc. may not be used to
11
# endorse or promote products derived from this software without
12
# specific prior written permission.
13
# THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
14
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
15
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
16
 
17
VERSION = 1.8.1
18
 
19
srcdir = .
20
 
21
prefix = /usr/local
22
 
23
exec_prefix = $(prefix)
24
bindir = $(exec_prefix)/bin
25
libdir = $(exec_prefix)/lib
26
 
27
datadir = $(prefix)/share
28
 
29
mandir = $(prefix)/man
30
man1dir = $(mandir)/man1
31
man2dir = $(mandir)/man2
32
man3dir = $(mandir)/man3
33
man4dir = $(mandir)/man4
34
man5dir = $(mandir)/man5
35
man6dir = $(mandir)/man6
36
man7dir = $(mandir)/man7
37
man8dir = $(mandir)/man8
38
man9dir = $(mandir)/man9
39
infodir = $(prefix)/info
40
includedir = $(prefix)/include
41
 
42
# Used for docn; upper-level Makefile may clear this in some configs
43
signal_dir = signal
44
 
45
SHELL = /bin/sh
46
 
47
INSTALL = install -c
48
INSTALL_PROGRAM = $(INSTALL)
49
INSTALL_DATA = $(INSTALL)
50
 
51
AR_FLAGS = qv
52
MAKEINFO = makeinfo
53
TEXI2DVI = texi2dvi
54
TEXIDIR=$(srcdir)/../../texinfo
55
SET_TEXINPUTS = TEXINPUTS=${TEXIDIR}:.:$(srcdir):$$TEXINPUTS
56
 
57
TOP = ..
58
SRCTOP = ..
59
TARGETDOC = `echo $${rootpre}./targetdep.tex`
60
 
61
.NOEXPORT:
62
MAKEOVERRIDES=
63
 
64
#### Host, target, and site specific Makefile fragments come in here.
65
###
66
 
67
# These are roughly topologically sorted in order to make porting more
68
# streamlined.
69
FLAGS_TO_PASS = \
70
        "CC=$(CC)" \
71
        "CFLAGS=$(CFLAGS)" \
72
        "AR=$(AR)" \
73
        "AR_FLAGS=$(AR_FLAGS)" \
74
        "AS=$(AS)" \
75
        "DLLTOOL=$(DLLTOOL)" \
76
        "CROSS_CFLAGS=$(CROSS_CFLAGS)" \
77
        "TARGET_CFLAGS=$(TARGET_CFLAGS)" \
78
        "TARGET_ASFLAGS=$(TARGET_ASFLAGS)" \
79
        "INCLUDES=$(INCLUDES)"
80
 
81
# The order of SUBDIRS is very important to the integrated documentation;
82
# DO NOT CHANGE this order without considering doc impact.
83
#
84
LIBC_SIGNAL_LIB =
85
LIBC_SYS_LIB =
86
LIBC_MACHINE_LIB =
87
LIBC_UNIX_LIB =
88
LIBC_POSIX_LIB =
89
LIBC_SYSCALL_LIB =
90
CRT0 =
91
 
92
SUBDIRS = stdlib ctype stdio string signal time locale sys reent errno \
93
        misc machine unix posix syscalls
94
 
95
SUBLIBS = \
96
        stdlib/lib.a \
97
        ctype/lib.a \
98
        stdio/lib.a \
99
        string/lib.a \
100
        $(LIBC_SIGNAL_LIB) \
101
        time/lib.a \
102
        locale/lib.a \
103
        $(LIBC_SYS_LIB) \
104
        reent/lib.a \
105
        errno/lib.a \
106
        misc/lib.a \
107
        $(LIBC_MACHINE_LIB) \
108
        $(LIBC_UNIX_LIB) \
109
        $(LIBC_POSIX_LIB) \
110
        $(LIBC_SYSCALL_LIB)
111
 
112
all: libc.a $(CRT0)
113
libc.a: $(SUBLIBS)
114
        rm -f $@
115
        rm -rf tmp
116
        mkdir tmp
117
        rootpre=`pwd`/; export rootpre; \
118
        srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre ; \
119
        cd tmp ; \
120
                for i in $(SUBLIBS) ; do \
121
                        $(AR) x ../$$i ; \
122
                done ; \
123
                $(AR) $(AR_FLAGS) ../$@ *.o
124
        $(RANLIB) $@
125
        rm -rf tmp
126
 
127
crt0.o: sys/crt0.o
128
        rm -f $@
129
        ln sys/crt0.o $@ >/dev/null 2>/dev/null || cp sys/crt0.o $@
130
 
131
sys/crt0.o: $(LIBC_SYS_LIB)
132
 
133
$(SUBLIBS): force
134
        @rootpre=`pwd`/; export rootpre; \
135
        srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
136
        (cd `echo $@ | sed -e 's:/[^/]*$$::'` ; \
137
                $(MAKE) $(FLAGS_TO_PASS) all) \
138
        || exit 1
139
 
140
clean-here:
141
        rm -f core *~ libc.a crt0.o
142
        rm -f libc.cp libc.dvi targetdep.tex libc.log libc.cps
143
        rm -f libc.aux libc.toc libc.fn libc.vr libc.tp libc.ky
144
        rm -f libc.pg libc.fns libc.kys libc.pgs libc.tps libc.vrs
145
 
146
clean mostlyclean: clean-here
147
        @rootpre=`pwd`/; export rootpre; \
148
        srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
149
        for i in $(SUBDIRS); do \
150
          if [ -f ./$$i/Makefile ] ; then \
151
            (cd $$i ; $(MAKE) $(FLAGS_TO_PASS) $@) || exit 1 ; \
152
          else true ; fi ; \
153
        done
154
 
155
distclean maintainer-clean realclean: clean-here
156
        @rootpre=`pwd`/; export rootpre; \
157
        srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
158
        for i in $(SUBDIRS); do \
159
          if [ -f ./$$i/Makefile ] ; then \
160
            (cd $$i ; $(MAKE) $(FLAGS_TO_PASS) $@) || exit 1 ; \
161
          else true ; fi ; \
162
        done
163
        rm -f Makefile config.status
164
 
165
info:
166
        -rm -f targetdep.tex
167
        if [ -n "$(signal_dir)" ]; then \
168
          echo "@set SIGNALS" >sigset.texi ; else \
169
          echo "@clear SIGNALS" >sigset.texi ; fi
170
        @rootpre=`pwd`/; export rootpre; \
171
        srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
172
        $(MAKE) "CHEW=$(CHEW)" "TARGETDOC=$(TARGETDOC)" targetdep.tex
173
        $(MAKEINFO) -o libc.info $(srcdir)/libc.texinfo
174
 
175
targetdep.tex:
176
        touch targetdep.tex
177
        @rootpre=`pwd`/; export rootpre; \
178
        srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
179
        for i in $(SUBDIRS); do \
180
          if [ -f ./$$i/Makefile ] ; then \
181
            (cd $$i ; $(MAKE) "CHEW=$(CHEW)" "TARGETDOC=$(TARGETDOC)" doc) \
182
            || exit 1 ; \
183
          else true ; fi ; \
184
        done
185
        cat $(srcdir)/sys.tex >> $(TARGETDOC)
186
 
187
docs: dvi
188
 
189
dvi:
190
        -rm -f targetdep.tex
191
        @rootpre=`pwd`/; export rootpre; \
192
        srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
193
        $(MAKE) $(FLAGS_TO_PASS) "CHEW=$(CHEW)" "TARGETDOC=$(TARGETDOC)" \
194
             targetdep.tex
195
        $(SET_TEXINPUTS) $(TEXI2DVI) $(srcdir)/libc.texinfo
196
 
197
install:
198
 
199
install-info:
200
        -for i in libc.info*; do \
201
            $(INSTALL_DATA) $$i $(infodir)/$$i; \
202
          done
203
 
204
force:
205
 
206
Makefile: Makefile.in $(host_makefile_frag) $(target_makefile_frag)
207
        $(SHELL) config.status

powered by: WebSVN 2.1.0

© copyright 1999-2025 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.