source: rtems/cpukit/libcsupport/Makefile.am @ 3f4876a

4.104.114.84.95
Last change on this file since 3f4876a was 3f4876a, checked in by Ralf Corsepius <ralf.corsepius@…>, on May 30, 2003 at 11:49:08 AM

Merger from rtems-4.6-branch

  • Property mode set to 100644
File size: 4.9 KB
Line 
1##
2##  $Id$
3##
4
5ACLOCAL_AMFLAGS = -I ../aclocal
6
7include $(top_srcdir)/../automake/multilib.am
8include $(top_srcdir)/../automake/compile.am
9include $(top_srcdir)/../automake/lib.am
10
11include_HEADERS = include/chain.h include/console.h include/clockdrv.h \
12    include/iosupp.h include/ringbuf.h include/rtc.h \
13    include/spurious.h include/timerdrv.h include/vmeintr.h
14
15if NEED_STDINT_H
16LIBC_HFILES = include/stdint.h
17endif
18if NEED_INTTYPES_H
19LIBC_HFILES += include/inttypes.h
20endif
21include_HEADERS += $(LIBC_HFILES)
22
23PREINSTALL_FILES = $(PROJECT_INCLUDE) \
24    $(include_HEADERS:include/%=$(PROJECT_INCLUDE)/%)
25
26$(PROJECT_INCLUDE):
27        @$(mkinstalldirs) $@
28$(PROJECT_INCLUDE)/motorola:
29        @$(mkinstalldirs) $@
30$(PROJECT_INCLUDE)/rtems:
31        @$(mkinstalldirs) $@
32$(PROJECT_INCLUDE)/sys:
33        @$(mkinstalldirs) $@
34$(PROJECT_INCLUDE)/zilog:
35        @$(mkinstalldirs) $@
36
37$(PROJECT_INCLUDE)/%.h: include/%.h
38        $(INSTALL_DATA) $< $@
39
40## motorola
41
42include_motoroladir = $(includedir)/motorola
43
44include_motorola_HEADERS = include/motorola/mc68230.h include/motorola/mc68681.h
45
46PREINSTALL_FILES += $(PROJECT_INCLUDE)/motorola \
47    $(include_motorola_HEADERS:include/%=$(PROJECT_INCLUDE)/%)
48
49## rtems
50include_rtemsdir = $(includedir)/rtems
51
52include_rtems_HEADERS = \
53    include/rtems/assoc.h include/rtems/error.h include/rtems/libcsupport.h \
54    include/rtems/libio.h include/rtems/libio_.h \
55    include/rtems/termiostypes.h
56
57PREINSTALL_FILES += $(PROJECT_INCLUDE)/rtems \
58    $(include_rtems_HEADERS:include/%=$(PROJECT_INCLUDE)/%)
59
60## sys
61
62include_sysdir = $(includedir)/sys
63
64if NEWLIB
65NEWLIB_H_FILES = include/sys/termios.h include/sys/utsname.h
66endif
67
68if NEED_SYS_CDEFS_H
69SYS_H_FILES = include/sys/cdefs.h
70endif
71
72# FIXME: We should not install to include/sys unless using newlib.
73include_sys_HEADERS = \
74include/sys/filio.h \
75include/sys/ioccom.h \
76include/sys/ioctl.h \
77include/sys/sockio.h \
78include/sys/termios.h \
79include/sys/ttycom.h \
80$(SYS_H_FILES) \
81$(NEWLIB_H_FILES)
82
83PREINSTALL_FILES += $(PROJECT_INCLUDE)/sys \
84    $(include_sys_HEADERS:include/%=$(PROJECT_INCLUDE)/%)
85
86## zilog
87
88include_zilogdir = $(includedir)/zilog
89
90include_zilog_HEADERS = include/zilog/z8036.h include/zilog/z8530.h \
91    include/zilog/z8536.h
92
93PREINSTALL_FILES += $(PROJECT_INCLUDE)/zilog \
94    $(include_zilog_HEADERS:include/%=$(PROJECT_INCLUDE)/%)
95
96##  General stuff
97all-local: $(PREINSTALL_FILES)
98
99LIB = ${ARCH}/libcsupport.a
100
101AM_CPPFLAGS += -Isrc
102
103ERROR_C_FILES = src/error.c
104
105ASSOCIATION_C_FILES = src/assoc.c src/assocnamebad.c
106
107BASE_FS_C_FILES = src/base_fs.c src/mount.c src/unmount.c src/libio.c \
108    src/libio_sockets.c src/eval.c src/fs_null_handlers.c src/privateenv.c
109
110TERMIOS_C_FILES = src/cfgetispeed.c src/cfgetospeed.c src/cfsetispeed.c \
111    src/cfsetospeed.c src/tcgetattr.c src/tcsetattr.c src/tcdrain.c \
112    src/tcflow.c src/tcflush.c src/tcgetprgrp.c src/tcsendbreak.c \
113    src/tcsetpgrp.c src/termios.c src/termiosinitialize.c \
114    src/termiosreserveresources.c
115
116SYSTEM_CALL_C_FILES = src/open.c src/close.c src/read.c src/write.c \
117    src/lseek.c src/ioctl.c src/mkdir.c src/mknod.c src/mkfifo.c src/rmdir.c \
118    src/chdir.c src/chmod.c src/fchdir.c src/fchmod.c src/chown.c src/link.c \
119    src/unlink.c src/umask.c src/ftruncate.c src/utime.c src/fstat.c \
120    src/fcntl.c src/fpathconf.c src/getdents.c src/fsync.c src/fdatasync.c \
121    src/pipe.c src/dup.c src/dup2.c src/symlink.c src/readlink.c src/creat.c \
122    src/chroot.c
123
124DIRECTORY_SCAN_C_FILES = src/opendir.c src/closedir.c src/readdir.c \
125    src/readdir_r.c src/rewinddir.c src/scandir.c src/seekdir.c \
126    src/telldir.c src/getcwd.c
127
128MALLOC_C_FILES = src/malloc.c src/mallocfreespace.c src/__brk.c src/__sbrk.c
129
130PASSWORD_GROUP_C_FILES = src/getpwent.c
131
132TERMINAL_IDENTIFICATION_C_FILES = src/ctermid.c src/isatty.c src/ttyname.c \
133    src/ttyname_r.c
134
135LIBC_GLUE_C_FILES = src/__getpid.c src/__gettod.c src/__times.c \
136    src/truncate.c src/access.c src/stat.c src/lstat.c src/pathconf.c \
137    src/newlibc.c src/no_posix.c src/no_libc.c src/utsname.c
138
139UNIX_LIBC_C_FILES = src/unixlibc.c src/hosterr.c
140
141BSD_LIBC_C_FILES = src/strlcpy.c src/strlcat.c
142
143COMMON_C_FILES = src/gxx_wrappers.c src/printk.c \
144    $(BSD_LIBC_C_FILES) \
145    $(BASE_FS_C_FILES) \
146    $(MALLOC_C_FILES) $(TERMIOS_C_FILES) $(ERROR_C_FILES) \
147    $(ASSOCIATION_C_FILES)
148
149UNIX_C_FILES = $(UNIX_LIBC_C_FILES)
150
151EMBEDDED_C_FILES = $(LIBC_GLUE_C_FILES) $(PASSWORD_GROUP_C_FILES) \
152    $(TERMINAL_IDENTIFICATION_C_FILES) $(SYSTEM_CALL_C_FILES) \
153    $(DIRECTORY_SCAN_C_FILES)
154
155if UNIX
156C_FILES = $(COMMON_C_FILES) $(UNIX_C_FILES)
157else
158C_FILES = $(COMMON_C_FILES) $(EMBEDDED_C_FILES)
159endif
160
161OBJS = $(C_FILES:src/%.c=${ARCH}/%.$(OBJEXT))
162
163#
164# Add local stuff here using +=
165#
166
167AM_CFLAGS += $(LIBC_DEFINES)
168
169all-local: ${ARCH} ${LIB}
170
171${ARCH}/%.$(OBJEXT): src/%.c
172        ${COMPILE} -o $@ -c $<
173
174$(LIB): ${OBJS}
175        $(make-library)
176
177DOC_FILES = TODO CASES
178
179EXTRA_DIST = $(DOC_FILES) $(COMMON_C_FILES) $(EMBEDDED_C_FILES) \
180    $(UNIX_C_FILES)
181
182include $(top_srcdir)/../automake/local.am
Note: See TracBrowser for help on using the repository browser.