summaryrefslogtreecommitdiffstats
path: root/c/src/lib/include/Makefile.in
blob: 0c4b8545560e2347e498facb8bd2c3c016bff3c8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
#
#  $Id$
#

@SET_MAKE@
srcdir = @srcdir@
top_srcdir = @top_srcdir@
top_builddir = ../../../..
subdir = c/src/lib/include

INSTALL = @INSTALL@

RTEMS_ROOT = $(top_srcdir)/@RTEMS_TOPdir@
PROJECT_ROOT = @PROJECT_ROOT@

VPATH = @srcdir@

H_PIECES=chain console clockdrv iosupp ringbuf \
   spurious timerdrv vmeintr
H_FILES=$(H_PIECES:%=$(srcdir)/%.h)

SYS_H_PIECES=termios utime
ifeq ($(HAS_NETWORKING),yes)
SYS_H_PIECES+=ioctl
endif
SYS_H_FILES=$(SYS_H_PIECES:%=$(srcdir)/sys/%.h)

MOTOROLA_H_PIECES=mc68230 mc68681
MOTOROLA_H_FILES=$(MOTOROLA_H_PIECES:%=$(srcdir)/motorola/%.h)

ZILOG_H_PIECES=z8036 z8530 z8536
ZILOG_H_FILES=$(ZILOG_H_PIECES:%=$(srcdir)/zilog/%.h)

RTEMSCPLUSPLUS_H_PIECES= rtemsEvent rtemsInterrupt rtemsMessageQueue \
  rtemsSemaphore rtemsStatusCode rtemsTask rtemsTaskMode rtemsTimer
RTEMSCPLUSPLUS_H_FILES=$(RTEMSCPLUSPLUS_H_PIECES:%=$(srcdir)/rtems++/%.h)

RPC_H_PIECES=  auth clnt rpc rpc_msg svc svc_auth types xdr
RPC_H_FILES=$(RPC_H_PIECES:%=$(srcdir)/rpc/%.h)

# We only build the rdbg library if HAS_NETWORKING and HAS_RDBG was defined
RDBG_H_PIECES_yes_yes_V = servrpc rdbg $(RTEMS_CPU)/rdbg_f $(RTEMS_CPU)/reg
RDBG_H_FILES=$(RDBG_H_PIECES_$(HAS_NETWORKING)_$(HAS_RDBG)_V:%=$(srcdir)/rdbg/%.h)

SRCS=$(H_FILES) $(SYS_H_FILES) \
     $(MOTOROLA_H_FILES) $(RTEMSCPLUSPLUS_H_FILES) \
     $(RPC_H_FILES) $(RDBG_H_FILES)

include $(RTEMS_ROOT)/make/custom/${RTEMS_BSP}.cfg
include $(RTEMS_ROOT)/make/leaf.cfg
CLEAN_ADDITIONS +=
CLOBBER_ADDITIONS +=

all:	$(SRCS)
	$(INSTALL_CHANGE) -m 444 $(H_FILES) $(PROJECT_INCLUDE)
	$(INSTALL_CHANGE) -m 444 $(SYS_H_FILES) $(PROJECT_INCLUDE)/sys
	$(INSTALL_CHANGE) -m 444 $(MOTOROLA_H_FILES) \
            $(PROJECT_INCLUDE)/motorola
	$(INSTALL_CHANGE) -m 444 $(ZILOG_H_FILES) $(PROJECT_INCLUDE)/zilog
ifeq ($(HAS_CPLUSPLUS),yes)
	$(INSTALL_CHANGE) -m 444 $(RTEMSCPLUSPLUS_H_FILES) $(PROJECT_INCLUDE)/rtems++
endif
ifeq ($(HAS_NETWORKING),yes)
	$(INSTALL_CHANGE) -m 444 $(RPC_H_FILES) $(PROJECT_INCLUDE)/rpc
ifeq ($(HAS_RDBG),yes)
	$(INSTALL_CHANGE) -m 444 $(RDBG_H_FILES) $(PROJECT_INCLUDE)/rdbg
endif
endif

Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
	cd $(top_builddir) \
	 && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status