Changeset 11cafc0 in rtems


Ignore:
Timestamp:
Feb 12, 2004, 12:10:29 PM (16 years ago)
Author:
Ralf Corsepius <ralf.corsepius@…>
Branches:
4.10, 4.11, 4.8, 4.9, master
Children:
e9e6b77
Parents:
c24d7c84
Message:

2004-02-12 Ralf Corsepius <corsepiu@…>

  • wrapup/Makefile.am: Don't include lib.am.
  • automake/compile.am: Use automake compilation rules.
Location:
c/src
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • c/src/ChangeLog

    rc24d7c84 r11cafc0  
     12004-02-12      Ralf Corsepius <corsepiu@faw.uni-ulm.de>
     2
     3        * wrapup/Makefile.am: Don't include lib.am.
     4        * automake/compile.am: Use automake compilation rules.
     5
    162004-02-09      Ralf Corsepius <corsepiu@faw.uni-ulm.de>
    27
  • c/src/automake/compile.am

    rc24d7c84 r11cafc0  
    3737## 'VARIANT=<OPTIMIZE|DEBUG>' targets to their _V values.
    3838
    39 ## XCPPFLAGS, XCFLAGS, XCXXFLAGS, XASFLAGS
    40 ## are used to add flags from the shell
    41 ## cf. make.info ("Implicit rules/variables" for details)
    42 
    4339if RTEMS_USE_GCC
    4440## All the stuff below is specific to gcc
     
    5450DEFS = @DEFS@
    5551
    56 CPPFLAGS = @CPPFLAGS@ $(CPU_DEFINES) $(DEFINES) $(XCPPFLAGS)
    57 CFLAGS   = @RTEMS_CFLAGS@ $(XCFLAGS)
     52CPPFLAGS = @CPPFLAGS@ $(CPU_DEFINES) $(DEFINES)
     53CFLAGS   = @RTEMS_CFLAGS@
    5854## FIXME: This should be correct, but is not supported, yet
    5955# CXXFLAGS = @RTEMS_CXXFLAGS@ $(XCXXFLAGS)
     
    6258ASFLAGS  = $(CPU_ASFLAGS) $(CPU_CFLAGS) $(XASFLAGS)
    6359
    64 #
    65 # Client compiler and support tools
    66 #
    67 
    68 #
    69 # How to compile stuff into ${ARCH} subdirectory
    70 #
    71 
    72 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
    73         $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
    74 CCLD = $(CC)
    75 LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
    76         $(AM_LDFLAGS) $(LDFLAGS) -o $@
    77 
    78 CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
    79         $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
    80 CXXLD = $(CXX)
    81 CXXLINK = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) \
    82         $(AM_LDFLAGS) $(LDFLAGS) -o $@
    83 
    84 CCAS = $(CC)
    85 CCASCOMPILE = $(CCAS) $(AM_CCASFLAGS) $(CCASFLAGS)
    86 
    87 # OBSOLETE: Don't use
    88 AS = $(CC)
    89 ASCOMPILE = $(AS) $(AM_ASFLAGS) $(ASFLAGS)
    90 
    91 ${ARCH}/%.o: %.c $(ARCH)/$(dirstamp)
    92         ${COMPILE} -o $@ -c $<
    93 
    94 ${ARCH}/%.o: %.cc $(ARCH)/$(dirstamp)
    95         ${CXXCOMPILE} -o $@ -c $<
    96 
    97 ${ARCH}/%.o: %.S $(ARCH)/$(dirstamp)
    98         ${CCASCOMPILE} -DASM -o $@ -c $<
    99 
    100 ${ARCH}/$(dirstamp):
    101         @$(mkdir_p) $(ARCH)
    102         @: > $(ARCH)/$(dirstamp)
    103 
    104 # Dependency files for use by gmake
    105 # NOTE: we don't put them into $(ARCH)
    106 #       so that 'make clean' doesn't blow it away
    107 
    108 DEPEND=Depends-${ARCH}
    109 
    110 # We deliberately don't have anything depend on the
    111 # $(DEPEND) file; otherwise it will get rebuilt even
    112 # on 'make clean'
    113 #
    114 
    115 if RTEMS_USE_GCC
    116 ## HACK: Specific to gcc
    117 ## FIXME: The approach below is known to be conceptionally broken.
    118 depend-gcc: $(C_FILES) $(CC_FILES) $(S_FILES)
    119 ##       Use gcc -M to generate dependencies
    120 ##       Replace foo.o with $(ARCH)/foo.o
    121 ##       Replace $(ARCH) value with string $(ARCH)
    122 ##           so that it will for debug cases
    123         $(COMPILE) -M   $^    |  \
    124         sed -e 's?^\(.*\)\.o[ ]*:?$$(ARCH)/\1.o:?' \
    125             -e 's?$(ARCH)/?$$(ARCH)/?'   >$(DEPEND).tmp
    126         mv $(DEPEND).tmp $(DEPEND)
    127 
    128 # pull in dependencies if they exist 
    129 ifeq (${DEPEND},$(wildcard ${DEPEND}))
    130 include ${DEPEND}
    131 @ENDIF@
    132 endif
    133 depend: depend-am
     60depend:
    13461
    13562if RTEMS_USE_GCC
     
    15784
    15885VARIANT_V = $(VARIANT_$(VARIANT)_V)
    159 
    160 ## Setup the variant build subdirectory
    161 ARCH_OPTIMIZE_V = o-optimize
    162 ARCH_DEBUG_V = o-debug
    163 
    164 ARCH__V = $(ARCH_OPTIMIZE_V)
    165 ARCH = $(ARCH_$(VARIANT_V)_V)
    16686
    16787## Setup the library suffix
     
    207127AM_CFLAGS =
    208128AM_CXXFLAGS =
    209 AM_CCASFLAGS = $(CPU_CFLAGS) $(RTEMS_CPPFLAGS) $(RTEMS_CCASFLAGS)
    210 
    211 clean-local:
    212         $(RM) -r o-optimize o-debug $(CLEANDIRS)
    213         $(RM) Depends-o-optimize.tmp Depends-o-debug.tmp
     129AM_CCASFLAGS = $(RTEMS_CPPFLAGS) $(RTEMS_CCASFLAGS)
  • c/src/wrapup/Makefile.am

    rc24d7c84 r11cafc0  
    66
    77include $(top_srcdir)/automake/compile.am
    8 include $(top_srcdir)/automake/lib.am
     8
     9## Setup the variant build subdirectory
     10ARCH_OPTIMIZE_V = o-optimize
     11ARCH_DEBUG_V = o-debug
     12                                                                               
     13ARCH__V = $(ARCH_OPTIMIZE_V)
     14ARCH = $(ARCH_$(VARIANT_V)_V)
    915
    1016project_lib_DATA = $(ARCH)/librtemsbsp$(LIB_VARIANT).a
     17CLEANFILES = o-optimize/librtemsbsp.a
     18CLEANFILES += o-debug/librtemsbsp_g.a
    1119
    1220SRCS = ../support/libsupport$(LIB_VARIANT).a
     
    3543endif
    3644
    37 SRCS += $(wildcard $(PROJECT_LIB)/libcpu$(LIB_VARIANT).a)
     45# FIXME: ATM, there is no libcpu.a, anymore.
     46# SRCS += $(wildcard $(PROJECT_LIB)/libcpu$(LIB_VARIANT).a)
    3847
    3948if LIBCHIP
     
    5463all-local: $(TMPINSTALL_FILES)
    5564
    56 $(ARCH)/librtemsbsp$(LIB_VARIANT).a: $(SRCS) $(ARCH)/$(dirstamp)
     65$(ARCH)/librtemsbsp$(LIB_VARIANT).a: $(SRCS)
     66        rm -f $@
     67        $(mkdir_p) $(ARCH)
    5768        rm -rf $(ARCH)/*.a $(ARCH)/*.$(OBJEXT) $(ARCH)/*.rel
    5869        for f in $(SRCS); do \
     
    8091        done
    8192        $(AR) rc $@ $(ARCH)/*
     93        rm -f $(ARCH)/*.$(OBJEXT) $(ARCH)/*.rel
    8294        $(RANLIB) $@
    8395
     
    93105TMPINSTALL_FILES += $(PROJECT_LIB)/librtemsbsp$(LIB_VARIANT).a
    94106
    95 CLEANFILES = $(TMPINSTALL_FILES)
     107CLEANFILES += $(TMPINSTALL_FILES)
    96108
    97109include $(top_srcdir)/automake/local.am
Note: See TracChangeset for help on using the changeset viewer.