1 include $(TOPDIR
)/.config
3 MAKEFLAGS
=-j
$(BR2_JLEVEL
)
5 # Strip off the annoying quoting
6 ARCH
:=$(strip $(subst ",, $(BR2_ARCH)))
8 WGET
:=$(strip $(subst ",, $(BR2_WGET)))
11 GCC_VERSION
:=$(strip $(subst ",, $(BR2_GCC_VERSION)))
13 GCC_USE_SJLJ_EXCEPTIONS
:=$(strip $(subst ",, $(BR2_GCC_USE_SJLJ_EXCEPTIONS)))
15 TARGET_OPTIMIZATION
:=$(strip $(subst ",, $(BR2_TARGET_OPTIMIZATION)))
19 ifeq ($(BR2_SOFT_FLOAT),y)
20 # gcc 3.4.x soft float configuration is different than previous versions.
21 ifeq ($(findstring 3.4.,$(GCC_VERSION)),3.4.)
22 SOFT_FLOAT_CONFIG_OPTION:=--with-float=soft
24 SOFT_FLOAT_CONFIG_OPTION:=--without-float
26 TARGET_SOFT_FLOAT:=-msoft-float
27 ARCH_FPU_SUFFIX:=_nofpu
29 SOFT_FLOAT_CONFIG_OPTION:=
35 ifeq ($(BR2_TAR_VERBOSITY),y)
41 ifneq ($(BR2_LARGEFILE),y)
42 DISABLE_LARGEFILE= --disable-largefile
44 TARGET_CFLAGS:=$(TARGET_OPTIMIZATION) $(TARGET_DEBUGGING)
46 OPTIMIZE_FOR_CPU=$(ARCH)
49 DL_DIR:=$(BASE_DIR)/dl
50 BUILD_DIR:=$(BASE_DIR)/build_$(ARCH)$(ARCH_FPU_SUFFIX)
51 SCRIPT_DIR:=$(BASE_DIR)/scripts
52 BIN_DIR:=$(BASE_DIR)/bin
53 STAMP_DIR:=$(BUILD_DIR)/stamp
54 PACKAGE_DIR:=$(BIN_DIR)/packages
55 TARGET_DIR:=$(BUILD_DIR)/root
56 STAMP_DIR:=$(BUILD_DIR)/stamp
57 TOOL_BUILD_DIR=$(BASE_DIR)/toolchain_build_$(ARCH)$(ARCH_FPU_SUFFIX)
58 # Strip off the annoying quoting
59 STAGING_DIR:=$(strip $(subst ",, $(BR2_STAGING_DIR
)))
61 TARGET_PATH
=$(STAGING_DIR
)/usr
/bin
:$(STAGING_DIR
)/bin
:/bin
:/sbin
:/usr
/bin
:/usr
/sbin
62 IMAGE
:=$(BUILD_DIR
)/root_fs_
$(ARCH
)$(ARCH_FPU_SUFFIX
)
63 REAL_GNU_TARGET_NAME
=$(OPTIMIZE_FOR_CPU
)-linux-uclibc
64 GNU_TARGET_NAME
=$(OPTIMIZE_FOR_CPU
)-linux
65 KERNEL_CROSS
:=$(STAGING_DIR
)/bin
/$(OPTIMIZE_FOR_CPU
)-linux-uclibc-
66 TARGET_CROSS
:=$(STAGING_DIR
)/bin
/$(OPTIMIZE_FOR_CPU
)-linux-uclibc-
67 TARGET_CC
:=$(TARGET_CROSS
)gcc
68 #STRIP:=$(TARGET_CROSS)strip --remove-section=.comment --remove-section=.note
69 STRIP
:=$(STAGING_DIR
)/bin
/sstrip
70 PATCH
=$(SCRIPT_DIR
)/patch-kernel.sh
71 SED
:=$(STAGING_DIR
)/bin
/sed
-i
-e
73 LINUX_DIR
:=$(BUILD_DIR
)/linux
74 LINUX_HEADERS_DIR
:=$(TOOL_BUILD_DIR
)/linux
75 LINUX_KERNEL
:=$(BUILD_DIR
)/buildroot-kernel
76 LINUX_IMAGE
:=$(BUILD_DIR
)/buildroot-kernel-image
77 MODULES_SUBDIR
:= lib
/modules
/$(LINUX_VERSION
)
78 MODULES_DIR
:= $(BUILD_DIR
)/modules
/$(MODULES_SUBDIR
)
81 HOST_ARCH
:=$(shell $(HOSTCC
) -dumpmachine | sed
-e s
'/-.*//' \
82 -e
's/sparc.*/sparc/' \
85 -e
's/ppc/powerpc/g' \
86 -e
's/v850.*/v850/g' \
88 -e
's/mips-.*/mips/' \
89 -e
's/mipsel-.*/mipsel/' \
91 -e
's/i[3-9]86/i386/' \
93 GNU_HOST_NAME
:=$(HOST_ARCH
)-pc-linux-gnu
94 TARGET_CONFIGURE_OPTS
=PATH
=$(TARGET_PATH
) \
95 AR
=$(TARGET_CROSS
)ar \
96 AS
=$(TARGET_CROSS
)as \
97 LD
=$(TARGET_CROSS
)ld \
98 NM
=$(TARGET_CROSS
)nm \
99 CC
=$(TARGET_CROSS
)gcc \
100 GCC
=$(TARGET_CROSS
)gcc \
101 CXX
=$(TARGET_CROSS
)g
++ \
102 RANLIB
=$(TARGET_CROSS
)ranlib
104 ifeq ($(ENABLE_LOCALE
),true
)
107 DISABLE_NLS
:=--disable-nls
110 ifeq ($(BR2_ENABLE_MULTILIB
),y
)
111 MULTILIB
:=--enable-multilib
115 # invoke ipkg with configuration in $(STAGING_DIR)/etc/ipkg.conf
116 IPKG
:= IPKG_INSTROOT
=$(TARGET_DIR
) IPKG_CONF_DIR
=$(STAGING_DIR
)/etc
$(SCRIPT_DIR
)/ipkg
-force-defaults
-force-depends
117 IPKG_STATE_DIR
:= $(TARGET_DIR
)/usr
/lib
/ipkg
119 # invoke ipkg-build with some default options
120 IPKG_BUILD
:= PATH
="$(TARGET_PATH)" ipkg-build
-c
-o root
-g root
122 # where to build (and put) .ipk packages
123 IPKG_TARGET_DIR
:= $(PACKAGE_DIR
)
125 RSTRIP
:=STRIP
="$(STRIP)" $(SCRIPT_DIR
)/rstrip.sh
126 RSTRIP_KMOD
:=STRIP
="$(TARGET_CROSS)strip --strip-unneeded --remove-section=.comment --remove-section=.comment" $(SCRIPT_DIR
)/rstrip.sh
This page took 0.057289 seconds and 5 git commands to generate.