1 ###############################################################################
4 # @brief Handles default driver framework target
6 # @author Copyright (C) 2010 CERN. Yury GEORGIEVSKIY <ygeorgie@gmail.com>
8 # @date Created on 29/04/2010
10 # @section license_sec License
11 # Released under the GPL
12 ###############################################################################
14 # If not limited by the user (using TARGET_CPU) -- framework will be compiled for this platforms
15 DEFAULT_CPU
= L865 ppc4
17 # User can compile for this platforms, if (1) framework compilation is not limited
18 # by TARGET_CPU and (2) CPU is provided in the command line
19 SUPPORTED_CPU
= L865 ppc4 L864 ces
21 # User can limit framework compilation using this option
22 # If user does no limitation -- will compile for default targets
23 TARGET_CPU ?
= $(DEFAULT_CPU
)
25 ifeq ("$(origin CPU)", "command line")
27 # Check CPU provided and bail out if it is not supported
28 override CPU
:= $(strip $(if
$(findstring "default", "$(CPU)"), $(DEFAULT_CPU
), $(CPU
)))
29 FCPU
= $(filter-out $(SUPPORTED_CPU
), $(CPU
))
30 $(if
$(FCPU
), $(error wrong
/unsupported cpu
"$(FCPU)"))
32 # User wants to compile for specific platform, so
33 # limit compilation to one requested by the user
34 TARGET_CPU
:= $(filter $(CPU
), $(TARGET_CPU
))
39 @for cpu in
$(TARGET_CPU
) _dummy_cpu_
; \
41 if
[ $$cpu != _dummy_cpu_
]; then \
42 $(MAKE
) CPU
=$$cpu _build
; \