[BACK]Return to Makefile.inc CVS log [TXT][DIR] Up to [local] / prex-old / mk

Diff for /prex-old/mk/Makefile.inc between version 1.1.1.1.2.2 and 1.2

version 1.1.1.1.2.2, 2008/08/15 14:18:57 version 1.2, 2008/06/03 11:46:33
Line 2 
Line 2 
 # Makefile.inc - common make rules to build Prex  # Makefile.inc - common make rules to build Prex
 #  #
   
 #  
 # Supported environment variables  # Supported environment variables
 #  #
 #  SRCDIR        ... Root directory of source tree  #  SRCDIR        ... Root directory of source tree
 #  ARCH          ... Architecture name  #  ARCH          ... Architecture name
 #  PLATFORM      ... Platform name  #  PLATFORM      ... Platform name
 #  NDEBUG        ... 0 for debug, 1 for release (default: 0)  #  NDEBUG        ... 0 for debug, 1 for release (default: 0)
 #  LIBGCC_PATH   ... Directory for libgcc.a  #  LIBGCC_PATH   ... Full path for libgcc.a
 #  CROSS_COMPILE ... Prefix of tools for cross compile  #  CROSS_COMPILE ... Prefix of tools for cross compile
 #  #
 # Variables in local Makefile  # Variables in local Makefile
Line 35 
Line 34 
 #CROSS_COMPILE= powerpc-eabi-  #CROSS_COMPILE= powerpc-eabi-
 #CROSS_COMPILE= sh-elf-  #CROSS_COMPILE= sh-elf-
 #CROSS_COMPILE= mips-elf-  #CROSS_COMPILE= mips-elf-
   CROSS_COMPILE= avr32-
   
 #  #
 # Tools  # Tools
Line 48 
Line 48 
 OBJDUMP=        $(CROSS_COMPILE)objdump  OBJDUMP=        $(CROSS_COMPILE)objdump
 STRIP=          $(CROSS_COMPILE)strip  STRIP=          $(CROSS_COMPILE)strip
 LINT=           splint  LINT=           splint
 MAKE=           gmake  MAKE=           make
 #SHELL=         /bin/sh  #SHELL=         /bin/sh
 ifdef SHELL_PATH  ifdef SHELL_PATH
 SHELL=          $(SHELL_PATH)  SHELL=          $(SHELL_PATH)
Line 69 
Line 69 
                 -D__ARCH__=$(ARCH) -D__PLATFORM__=$(PLATFORM) \                  -D__ARCH__=$(ARCH) -D__PLATFORM__=$(PLATFORM) \
                 -U$(ARCH) -U$(PLATFORM)                  -U$(ARCH) -U$(PLATFORM)
   
 CFLAGS+=        -Os -ansi -pedantic -Wall -Wundef -fno-strict-aliasing \  CFLAGS+=        -Os -ansi -pedantic -fno-strict-aliasing \
                 -Wstrict-prototypes -Wpointer-arith \                  -Wall -Wundef -Wstrict-prototypes -Wpointer-arith \
                 $(CONFIG_CFLAGS) $(DEFS)                  $(CONFIG_CFLAGS) $(DEFS)
   
 ifeq ($(NDEBUG),1)  ifeq ($(NDEBUG),1)
 CFLAGS+=        -fomit-frame-pointer  CFLAGS+=        -fomit-frame-pointer
 else  else
 CFLAGS+=        -fno-omit-frame-pointer -g  CFLAGS+=        -fno-omit-frame-pointer -DDEBUG -g
 DEFS+=          -DDEBUG  
 endif  endif
   
 CPPFLAGS+=      $(DEFS)  CPPFLAGS+=      $(DEFS)
Line 87 
Line 86 
 endif  endif
 LDFLAGS+=  LDFLAGS+=
 MAKEFLAGS+=     -rR --no-print-directory  MAKEFLAGS+=     -rR --no-print-directory
 LINTFLAGS+=     -D__lint__ $(DEFS) -weak -nolib -retvalother -fcnuse  LINTFLAGS+=     -D__lint__ $(DEFS) -nolib -weak -fcnuse -nestcomment \
                   -retvalother -fullinitblock
   
 #  #
 # Specify path for libgcc.a  # Specify path for libgcc.a
Line 235 
Line 235 
   
 -include Makefile.dep  -include Makefile.dep
   
 ifndef SRCS  C_SRCS = $(wildcard *.c) $(wildcard *.S)
 SRCS = $(OBJS:.o=.c)  
 endif  
   
 #  #
 # Depend  # Depend
Line 250 
Line 248 
         done);          done);
 endif  endif
         rm -f Makefile.dep          rm -f Makefile.dep
         @(for d in $(SRCS) _ ; do \          @(for d in $(C_SRCS) _ ; do \
           if [ "$$d" != "_" ] ; then \            if [ "$$d" != "_" ] ; then \
           $(CPP) -M $(CPPFLAGS) $$d >> Makefile.dep; fi; \            $(CPP) -M $(CPPFLAGS) $$d >> Makefile.dep; fi; \
         done);          done);
Line 259 
Line 257 
 #  #
 .PHONY: lint  .PHONY: lint
 lint:  lint:
 ifdef SUBDIR          @(for d in $(C_SRCS) _ ; do \
         @(for d in $(SUBDIR) _ ; do \  
           if [ "$$d" != "_" ] ; then $(MAKE) -C $$d lint; fi; \  
         done);  
 endif  
         @(for d in $(SRCS) _ ; do \  
           if [ "$$d" != "_" ] ; then \            if [ "$$d" != "_" ] ; then \
           echo ; \  
           echo "Checking $$d" ; \  
           $(LINT) $(LINTFLAGS) $(INCLUDE) $$d; fi; \            $(LINT) $(LINTFLAGS) $(INCLUDE) $$d; fi; \
         done);          done);
   

Legend:
Removed from v.1.1.1.1.2.2  
changed lines
  Added in v.1.2

CVSweb