source: rtems/c/src/lib/libbsp/unix/posix/startup/Makefile.am @ 5cb24705

4.104.114.84.9
Last change on this file since 5cb24705 was 5cb24705, checked in by Ralf Corsepius <ralf.corsepius@…>, on Dec 11, 2003 at 12:46:51 PM

2003-12-11 Ralf Corsepius <corsepiu@…>

  • startup/Makefile.am: Add custom compilation rule for rtems-ctor$(LIB_VARIANT).$(OBJEXT).
  • Property mode set to 100644
File size: 1.8 KB
Line 
1##
2##  $Id$
3##
4
5VPATH = @srcdir@:@srcdir@/../../../shared
6
7PGM = ${ARCH}/startup.rel
8
9if HAS_CXX
10C_MAIN_C_FILES =
11else
12C_MAIN_C_FILES = main.c
13endif
14
15# C sources
16C_FILES = bspclean.c bsplibc.c bspstart.c setvec.c $(C_MAIN_C_FILES)
17C_O_FILES = $(C_FILES:%.c=${ARCH}/%.$(OBJEXT))
18startup_rel_OBJECTS = $(C_O_FILES)
19
20# CC sources
21CC_FILES = rtems-ctor.cc
22CC_O_FILES = $(CC_FILES:%.cc=${ARCH}/%.$(OBJEXT)}
23
24# We install the RTEMS constructor as a separate .$(OBJEXT)
25# so it can be easily place correctly by the compiler config file.
26
27include $(top_srcdir)/../../../../automake/compile.am
28include $(top_srcdir)/../../../../automake/lib.am
29
30#
31# (OPTIONAL) Add local stuff here using +=
32#
33
34AM_CFLAGS += $(LIBC_DEFINES)
35
36$(PGM): $(startup_rel_OBJECTS)
37        $(make-rel)
38
39if HAS_CXX
40project_lib_DATA = ${ARCH}/libno-ctor$(LIB_VARIANT).a
41
42${ARCH}/libno-ctor$(LIB_VARIANT).a: $(ARCH)/no-ctor.$(OBJEXT)
43        $(AR) -cvr $@ $<
44
45${ARCH}/rtems-ctor$(LIB_VARIANT).$(OBJEXT): rtems-ctor.cc $(ARCH)/$(dirstamp)
46        ${CXXCOMPILE} -o $@ -c $<
47
48project_lib_DATA += ${ARCH}/rtems-ctor$(LIB_VARIANT).$(OBJEXT)
49endif
50
51all-local: $(PGM) $(TMPINSTALL_FILES)
52
53EXTRA_DIST = bspclean.c bspstart.c exit.c main.c no-ctor.c rtems-ctor.cc \
54    setvec.c
55
56if HAS_CXX
57${PROJECT_RELEASE}/lib/libno-ctor$(LIB_VARIANT).a: ${ARCH}/libno-ctor$(LIB_VARIANT).a ${PROJECT_RELEASE}/lib/$(dirstamp)
58        $(INSTALL_DATA) $< ${PROJECT_RELEASE}/lib/libno-ctor$(LIB_VARIANT).a
59TMPINSTALL_FILES += ${PROJECT_RELEASE}/lib/libno-ctor$(LIB_VARIANT).a
60
61${PROJECT_RELEASE}/lib/rtems-ctor$(LIB_VARIANT).$(OBJEXT): ${ARCH}/rtems-ctor$(LIB_VARIANT).$(OBJEXT) ${PROJECT_RELEASE}/lib/$(dirstamp)
62        $(INSTALL_DATA) $< ${PROJECT_RELEASE}/lib/rtems-ctor$(LIB_VARIANT).$(OBJEXT)
63TMPINSTALL_FILES += ${PROJECT_RELEASE}/lib/rtems-ctor$(LIB_VARIANT).$(OBJEXT)
64endif
65
66include $(top_srcdir)/../../../../automake/local.am
Note: See TracBrowser for help on using the repository browser.