Makefile
author "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Fri May 18 15:57:16 2007 +0000 (2007-05-18)
changeset 103 b6e20abe9256
parent 96 aa1a9fbd6eb8
child 121 82e69d88119b
permissions -rw-r--r--
Add dmalloc debug library facility.
Add patches for dmalloc.
Ignore the generated config/debug.in
     1 # Makefile for crosstool-NG.
     2 # Copyright 2006 Yann E. MORIN <yann.morin.1998@anciens.enib.fr>
     3 
     4 # Don't print directory as we descend into them
     5 MAKEFLAGS += --no-print-directory
     6 
     7 export CT_TOP_DIR=$(shell pwd)
     8 
     9 # This is crosstool-ng version string
    10 export CT_VERSION=$(shell cat $(CT_TOP_DIR)/version)
    11 
    12 .PHONY: all
    13 all: build
    14 
    15 HOST_CC = gcc -funsigned-char
    16 
    17 help::
    18 	@echo  'Available make targets:'
    19 	@echo
    20 
    21 include $(CT_TOP_DIR)/kconfig/Makefile
    22 include $(CT_TOP_DIR)/samples/Makefile
    23 
    24 help::
    25 	@echo  'Build targets:'
    26 	@echo  '* build          - Build the toolchain'
    27 	@echo  '  tarball        - Build a tarball of the configured toolchain'
    28 	@echo  '  clean          - Remove generated files'
    29 	@echo  '  distclean      - Remove generated files, configuration and build directories'
    30 
    31 include $(CT_TOP_DIR)/tools/Makefile
    32 
    33 help::
    34 	@echo  'Execute "make" or "make all" to build all targets marked with [*]'
    35 
    36 .config: $(CONFIG_FILES) $(CT_TOP_DIR)/config/debug.in
    37 	@make oldconfig
    38 
    39 # Actual build
    40 build: .config
    41 	@$(CT_TOP_DIR)/scripts/crosstool.sh
    42 
    43 .PHONY: tarball
    44 tarball:
    45 	@$(CT_TOP_DIR)/scripts/tarball.sh
    46 
    47 .PHONY: distclean
    48 distclean:: clean
    49 	@rm -f .config* ..config.tmp
    50 	@rm -rf "$(CT_TOP_DIR)/targets"