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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-stable/] [newlib-1.18.0/] [newlib/] [libc/] [sys/] [linux/] [linuxthreads/] [Makefile.am] - Blame information for rev 829

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 207 jeremybenn
## Process this file with automake to generate Makefile.in
2
 
3
AUTOMAKE_OPTIONS = cygnus
4
 
5
INCLUDES = -I$(srcdir)/../include -I$(srcdir)/machine/$(machine_dir) -I$(srcdir)/machine/generic  $(NEWLIB_CFLAGS) $(CROSS_CFLAGS) $(TARGET_CFLAGS) -I$(srcdir)/..
6
 
7
LIBTOOL_VERSION_INFO = 0:0:0
8
 
9
LIB_SOURCES= \
10
        attr.c barrier.c condvar.c \
11
        events.c getcpuclockid.c getreent.c join.c lockfile.c manager.c \
12
        mq_notify.c oldsemaphore.c prio.c ptclock_gettime.c ptclock_settime.c \
13
        ptlongjmp.c pt-machine.c reent.c rwlock.c semaphore.c \
14
        signals.c spinlock.c sysctl.c \
15
        timer_create.c timer_getoverr.c timer_routines.c \
16
        timer_delete.c timer_gettime.c timer_settime.c \
17
        wrapsyscall.c
18
 
19
LIB_DB_SOURCES = td_init.c td_log.c td_ta_delete.c td_ta_get_nthreads.c      \
20
        td_ta_get_ph.c td_ta_map_id2thr.c td_ta_map_lwp2thr.c     \
21
        td_ta_new.c td_ta_thr_iter.c td_ta_tsd_iter.c             \
22
        td_thr_get_info.c td_thr_getfpregs.c td_thr_getgregs.c    \
23
        td_thr_getxregs.c td_thr_getxregsize.c td_thr_setfpregs.c \
24
        td_thr_setgregs.c td_thr_setprio.c td_thr_setsigpending.c \
25
        td_thr_setxregs.c td_thr_sigsetmask.c td_thr_tsd.c        \
26
        td_thr_validate.c td_thr_dbsuspend.c td_thr_dbresume.c    \
27
        td_ta_setconcurrency.c td_ta_enable_stats.c               \
28
        td_ta_reset_stats.c td_ta_get_stats.c td_ta_event_addr.c  \
29
        td_thr_event_enable.c td_thr_set_event.c                  \
30
        td_thr_clear_event.c td_thr_event_getmsg.c                \
31
        td_ta_set_event.c td_ta_event_getmsg.c                    \
32
        td_ta_clear_event.c td_symbol_list.c
33
 
34
# Because of how libtool moves objects around, these files must be built last.
35
LIBADD_OBJS = \
36
        $(lpfx)mutex.$(oext) $(lpfx)specific.$(oext) \
37
        $(lpfx)pthread.$(oext) $(lpfx)cancel.$(oext)
38
 
39
ELIX_3_SOURCES = \
40
        ptfork.c
41
 
42
if ELIX_LEVEL_1
43
ELIX_SOURCES = reqsyscalls.c
44
else
45
if ELIX_LEVEL_2
46
ELIX_SOURCES = reqsyscalls.c
47
else
48
ELIX_SOURCES = $(ELIX_3_SOURCES)
49
endif
50
endif
51
 
52
SUBDIRS = machine .
53
 
54
tooldir = $(tooldir)
55
toollibdir = $(top_toollibdir)
56
 
57
libpthread_la_LDFLAGS = -version-info $(LIBTOOL_VERSION_INFO) -release newlib -no-undefined -lgcc -Xcompiler -nostdlib -Xlinker --version-script=$(srcdir)/../shared.ld `cat extra-libtool-objlist`
58
libthread_db_la_LDFLAGS = -version-info $(LIBTOOL_VERSION_INFO) -release newlib -no-undefined -lgcc -Xcompiler -nostdlib -Xlinker --version-script=$(srcdir)/../shared.ld
59
 
60
if USE_LIBTOOL
61
 
62
# objects listed later in LIBPTHREAD_OBJLISTS will override those listed earlier
63
extra-libtool-objlist: $(MACHINE_OBJLIST)
64
        cat $(MACHINE_OBJLIST) | $(AWK) '{ libpthread[$$1] = $$2 }; END { for (x in libpthread) printf ("%s\n", libpthread[x]) }' > $@
65
 
66
toollib_LTLIBRARIES = libpthread.la libthread_db.la
67
libpthread_la_SOURCES = $(LIB_SOURCES) $(ELIX_SOURCES)
68
libpthread_la_LIBADD = $(LIBADD_OBJS)
69
## libpthread_la_DEPENDENCIES = defs.h crti.S
70
libpthread_la_DEPENDENCIES = $(LIBADD_OBJS) extra-libtool-objlist
71
noinst_DATA=objectlist.awk.in
72
LIB_COMPILE = $(LTCOMPILE)
73
 
74
libthread_db_la_SOURCES = $(LIB_DB_SOURCES)
75
 
76
else
77
 
78
toollib_LIBRARIES = libpthread.a libthread_db.a
79
libpthread_a_SOURCES = $(LIB_SOURCES) $(ELIX_SOURCES)
80
libpthread_a_LIBADD = $(LIBADD_OBJS) $(MACHINE_LIB)
81
libpthread_a_CFLAGS = $(AM_CFLAGS)
82
## libpthread_a_DEPENDENCIES = defs.h crti.S
83
libpthread_a_DEPENDENCIES = $(LIBADD_OBJS) $(MACHINE_LIB)
84
LIB_COMPILE = $(COMPILE)
85
 
86
libthread_db_a_SOURCES = $(LIB_DB_SOURCES)
87
libthread_db_a_CFLAGS = $(AM_CFLAGS)
88
 
89
endif # USE_LIBTOOL
90
 
91
include $(srcdir)/../../../../Makefile.shared
92
 
93
doc:
94
 
95
install-data-local: install-toollibLIBRARIES
96
        -rm -f $(DESTDIR)$(toollibdir)/libthread_db.so.1
97
        ln -s `readlink $(DESTDIR)$(toollibdir)/libthread_db.so` \
98
          $(DESTDIR)$(toollibdir)/libthread_db.so.1 \
99
          || cp $(DESTDIR)$(toollibdir)/libthread_db.so \
100
          $(DESTDIR)$(toollibdir)/libthread_db.so.1
101
 
102
AM_CFLAGS = -D_XOPEN_SOURCE=600 -D_GNU_SOURCE=1
103
ACLOCAL_AMFLAGS = -I ../../../.. -I ../../../../..
104
CONFIG_STATUS_DEPENDENCIES = $(newlib_basedir)/configure.host
105
 
106
## PTHREAD_HEADERS=pthread.h semaphore.h
107
 
108
CFLAGS_pt_initfini = -g0 -fPIC -fno-inline-functions
109
CFLAGS_noweak=-D__NO_WEAK_PTHREAD_ALIASES
110
CFLAGS_cancel=-D__NO_WEAK_PTHREAD_ALIASES -D_RPC_THREAD_SAFE_
111
CFLAGS_pthread=-D__NO_WEAK_PTHREAD_ALIASES -DHAVE_Z_NODELETE
112
 
113
pt-initfini.s: $(srcdir)/pt-initfini.c
114
        $(CC) -S $(CFLAGS_pt_initfini) -finhibit-size-directive \
115
                $(patsubst -f%,-fno-%,$(exceptions)) -o $@
116
 
117
# We only have one kind of startup code files.  Static binaries and
118
# shared libraries are build using the PIC version.
119
crti.S: pt-initfini.s
120
        sed -n -e '1,/@HEADER_ENDS/p' \
121
               -e '/@_.*_PROLOG_BEGINS/,/@_.*_PROLOG_ENDS/p' \
122
               -e '/@TRAILER_BEGINS/,$$p' $< > $@
123
 
124
defs.h: pt-initfini.s
125
        sed -n -e '/@TESTS_BEGIN/,/@TESTS_END/p' $< | \
126
                $(AWK) -f defs.awk > $@
127
 
128
crti.o: crti.S defs.h
129
        $(CC) -g0 $(ASFLAGS) -o $@
130
 
131
$(lpfx)mutex.$(oext): $(srcdir)/mutex.c
132
        $(LIB_COMPILE) $(CFLAGS_noweak) -c $< -o $@
133
 
134
$(lpfx)specific.$(oext): $(srcdir)/specific.c
135
        $(LIB_COMPILE) $(CFLAGS_noweak) -c $< -o $@
136
 
137
$(lpfx)pthread.$(oext): $(srcdir)/pthread.c
138
        $(LIB_COMPILE) $(CFLAGS_pthread) -c $< -o $@
139
 
140
$(lpfx)ptfork.$(oext): $(srcdir)/ptfork.c
141
        $(LIB_COMPILE) $(CFLAGS_noweak) -c $< -o $@
142
 
143
$(lpfx)cancel.$(oext): $(srcdir)/cancel.c
144
        $(LIB_COMPILE) $(CFLAGS_cancel) -c $< -o $@
145
 

powered by: WebSVN 2.1.0

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