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

Subversion Repositories or1k

[/] [or1k/] [trunk/] [linux/] [uClibc/] [libc/] [sysdeps/] [linux/] [or32/] [Makefile] - Blame information for rev 1779

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

Line No. Rev Author Line
1 1325 phoenix
# Makefile for uClibc
2
#
3
# Copyright (C) 2000-2003 Erik Andersen 
4
#
5
# This program is free software; you can redistribute it and/or modify it under
6
# the terms of the GNU Library General Public License as published by the Free
7
# Software Foundation; either version 2 of the License, or (at your option) any
8
# later version.
9
#
10
# This program is distributed in the hope that it will be useful, but WITHOUT
11
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
12
# FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more
13
# details.
14
#
15
# You should have received a copy of the GNU Library General Public License
16
# along with this program; if not, write to the Free Software Foundation, Inc.,
17
# 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18
 
19
TOPDIR=../../../../
20
include $(TOPDIR)Rules.mak
21
ASFLAGS=$(CFLAGS)
22
 
23
# __PHX__ no contructors and destructors for now
24
UCLIBC_CTOR_DTOR=n
25
 
26
# If you're looking for vfork(), it is defined in include/unistd.h
27
 
28
 
29
CRT0=crt0.S
30
CRT0_OBJ=$(patsubst %.S,%.o, $(CRT0))
31
CTOR_TARGETS=$(TOPDIR)lib/crti.o $(TOPDIR)lib/crtn.o
32
 
33
SSRC=__longjmp.S setjmp.S bsd-_setjmp.S bsd-setjmp.S
34
SOBJS=$(patsubst %.S,%.o, $(SSRC))
35
 
36
CSRC=crt1.c __syscall_error.c __init_brk.c brk.c sbrk.c vfork.c
37
COBJS=$(patsubst %.c,%.o, $(CSRC))
38
 
39
OBJS=$(SOBJS) $(MOBJ) $(COBJS) $(CRT0_OBJ)
40
 
41
ifeq ($(strip $(UCLIBC_HAS_SOFT_FLOAT)),y)
42
SAFECFLAGS += $(call check_gcc,-msoft-float,)
43
endif
44
 
45
all: $(OBJS) $(LIBC)
46
 
47
$(LIBC): ar-target
48
 
49
ar-target: $(OBJS) $(CRT0_OBJ) $(CTOR_TARGETS)
50
        $(AR) $(ARFLAGS) $(LIBC) $(OBJS)
51
        cp $(CRT0_OBJ) $(TOPDIR)lib/$(CRT0_OBJ)
52
 
53
$(CRT0_OBJ): %.o : %.S
54
        $(CC) $(CFLAGS) -c $< -o $@
55
        $(STRIPTOOL) -x -R .note -R .comment $*.o
56
 
57
$(SOBJS): %.o : %.S
58
        $(CC) $(CFLAGS) -c $< -o $@
59
        $(STRIPTOOL) -x -R .note -R .comment $*.o
60
 
61
$(COBJS): %.o : %.c
62
        $(CC) $(CFLAGS) -c $< -o $@
63
        $(STRIPTOOL) -x -R .note -R .comment $*.o
64
 
65
ifeq ($(strip $(UCLIBC_CTOR_DTOR)),y)
66
crti.o: crti.S
67
        $(CC) $(SAFECFLAGS) -c crti.S -o crti.o
68
 
69
$(TOPDIR)lib/crti.o: crti.o
70
        $(INSTALL) -d $(TOPDIR)lib/
71
        cp crti.o $(TOPDIR)lib/
72
 
73
crtn.o: crtn.S
74
        $(CC) $(SAFECFLAGS) -c crtn.S -o crtn.o
75
 
76
$(TOPDIR)lib/crtn.o: crtn.o
77
        $(INSTALL) -d $(TOPDIR)lib/
78
        cp crtn.o $(TOPDIR)lib/
79
else
80
$(TOPDIR)lib/crti.o:
81
        $(INSTALL) -d $(TOPDIR)lib/
82
        $(AR) $(ARFLAGS) $(TOPDIR)lib/crti.o
83
$(TOPDIR)lib/crtn.o:
84
        $(INSTALL) -d $(TOPDIR)lib/
85
        $(AR) $(ARFLAGS) $(TOPDIR)lib/crtn.o
86
endif
87
 
88
 
89
headers:
90
 
91
 
92
clean:
93
        $(RM) *.[oa] *~ core
94
        $(RM) bits/sysnum.h
95
ifneq ($(strip $(HAVE_ELF)),y)
96
        $(RM) $(TOPDIR)/include/float.h
97
endif
98
 

powered by: WebSVN 2.1.0

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