]> Git Repo - buildroot-mgba.git/blame - Makefile
busybox: default HIDE_OTHERS to y for all versions
[buildroot-mgba.git] / Makefile
CommitLineData
2d523c23 1# Makefile for buildroot2
ffde94bd 2#
15b26aee 3# Copyright (C) 1999-2005 by Erik Andersen <[email protected]>
ffde94bd 4#
08782ae7 5# This program is free software; you can redistribute it and/or modify
2d523c23
EA
6# it under the terms of the GNU General Public License as published by
7# the Free Software Foundation; either version 2 of the License, or
8# (at your option) any later version.
ffde94bd 9#
2d523c23
EA
10# This program is distributed in the hope that it will be useful,
11# but WITHOUT ANY WARRANTY; without even the implied warranty of
08782ae7 12# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
2d523c23 13# General Public License for more details.
ffde94bd 14#
2d523c23
EA
15# You should have received a copy of the GNU General Public License
16# along with this program; if not, write to the Free Software
17# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
3ad3d8a1 18#
02bf5816 19
2d523c23
EA
20#--------------------------------------------------------------
21# Just run 'make menuconfig', configure stuff, then run 'make'.
22# You shouldn't need to mess with anything beyond this point...
23#--------------------------------------------------------------
24TOPDIR=./
18d979c7
BRF
25CONFIG_CONFIG_IN=Config.in
26CONFIG_DEFCONFIG=.defconfig
27CONFIG=package/config
a8ee1240 28DATE:=$(shell date +%Y%m%d)
a0aef7c4 29
18d979c7 30noconfig_targets:=menuconfig config oldconfig randconfig \
6547bced 31 defconfig allyesconfig allnoconfig release tags \
e491fba2 32 source-check help
9e250356 33
cad58108 34
a1b0651a 35# Use shell variables, if defined
7521f373 36ifneq ($(BUILDROOT_LOCAL),)
efd8576c 37BR2_LOCAL:=$(BUILDROOT_LOCAL)
7521f373 38else
2ad346ab 39BR2_LOCAL:=$(TOPDIR)/local
a1b0651a
US
40endif
41
42# $(shell find . -name *_defconfig |sed 's/.*\///')
43# Pull in the user's configuration file
44ifeq ($(filter $(noconfig_targets),$(MAKECMDGOALS)),)
45ifeq ($(BOARD),)
46# if "make BOARD=xyz" command
d45f355d 47-include .config
a1b0651a
US
48else
49# if "make" command
efd8576c 50-include $(BR2_LOCAL)/$(BOARD)/$(BOARD).config
a1b0651a 51endif
7521f373 52endif
9741a49e 53
efd8576c
US
54# Override BR2_DL_DIR if shell variable defined
55ifneq ($(BUILDROOT_DL_DIR),)
56BR2_DL_DIR:=$(BUILDROOT_DL_DIR)
57endif
58LOCAL:=$(BR2_LOCAL)
59
afc61c6e
BRF
60# To put more focus on warnings, be less verbose as default
61# Use 'make V=1' to see the full commands
62ifdef V
63 ifeq ("$(origin V)", "command line")
18d979c7 64 KBUILD_VERBOSE=$(V)
afc61c6e
BRF
65 endif
66endif
67ifndef KBUILD_VERBOSE
18d979c7 68 KBUILD_VERBOSE=0
afc61c6e
BRF
69endif
70
71ifeq ($(KBUILD_VERBOSE),1)
4df454e9 72 quiet=
18d979c7 73 Q=
1669b6ed
BRF
74ifndef VERBOSE
75 VERBOSE=1
76endif
afc61c6e
BRF
77else
78 quiet=quiet_
18d979c7 79 Q=@
afc61c6e
BRF
80endif
81
18d979c7 82CONFIG_SHELL:=$(shell if [ -x "$$BASH" ]; then echo $$BASH; \
afc61c6e 83 else if [ -x /bin/bash ]; then echo /bin/bash; \
18d979c7 84 else echo sh; fi; fi)
afc61c6e 85
1669b6ed 86export CONFIG_SHELL quiet Q KBUILD_VERBOSE VERBOSE
afc61c6e
BRF
87
88ifndef HOSTAR
89HOSTAR:=ar
90endif
91ifndef HOSTAS
92HOSTAS:=as
93endif
94ifndef HOSTCC
95HOSTCC:=gcc
96else
97endif
98ifndef HOSTCXX
99HOSTCXX:=g++
100endif
5f97580e
BRF
101ifndef HOSTFC
102HOSTFC:=gfortran
103endif
356133b4
US
104ifndef HOSTCPP
105HOSTCPP:=cpp
106endif
afc61c6e
BRF
107ifndef HOSTLD
108HOSTLD:=ld
109endif
0f9c5b11
US
110ifndef HOSTLN
111HOSTLN:=ln
112endif
356133b4
US
113ifndef HOSTNM
114HOSTNM:=nm
115endif
18d979c7
BRF
116HOSTAR:=$(shell $(CONFIG_SHELL) -c "which $(HOSTAR)" || type -p $(HOSTAR) || echo ar)
117HOSTAS:=$(shell $(CONFIG_SHELL) -c "which $(HOSTAS)" || type -p $(HOSTAS) || echo as)
118HOSTCC:=$(shell $(CONFIG_SHELL) -c "which $(HOSTCC)" || type -p $(HOSTCC) || echo gcc)
83832cda 119HOSTCXX:=$(shell $(CONFIG_SHELL) -c "which $(HOSTCXX)" || type -p $(HOSTCXX) || echo g++)
5f97580e 120HOSTFC:=$(shell $(CONFIG_SHELL) -c "which $(HOSTLD)" || type -p $(HOSTLD) || echo || which g77 || type -p g77 || echo gfortran)
356133b4 121HOSTCPP:=$(shell $(CONFIG_SHELL) -c "which $(HOSTCPP)" || type -p $(HOSTCPP) || echo cpp)
18d979c7
BRF
122HOSTLD:=$(shell $(CONFIG_SHELL) -c "which $(HOSTLD)" || type -p $(HOSTLD) || echo ld)
123HOSTLN:=$(shell $(CONFIG_SHELL) -c "which $(HOSTLN)" || type -p $(HOSTLN) || echo ln)
356133b4 124HOSTNM:=$(shell $(CONFIG_SHELL) -c "which $(HOSTNM)" || type -p $(HOSTNM) || echo nm)
54e93328
US
125HOST_GLIB_BIN:=`dirname $(shell $(CONFIG_SHELL) -c "which glib-genmarshal" || echo /usr/bin/glib-genmarshal)`
126HOST_GLIB:=$(shell $(CONFIG_SHELL) -c "dirname $(HOST_GLIB_BIN)" || echo /usr)
127
128
afc61c6e 129ifndef CFLAGS_FOR_BUILD
f987b7a5 130CFLAGS_FOR_BUILD:=-g -O2
afc61c6e 131endif
5f97580e
BRF
132ifndef CXXFLAGS_FOR_BUILD
133CXXFLAGS_FOR_BUILD:=-g -O2
134endif
135ifndef FCFLAGS_FOR_BUILD
136FCFLAGS_FOR_BUILD:=-g -O2
137endif
138export HOSTAR HOSTAS HOSTCC HOSTCXX HOSTFC HOSTLD
afc61c6e
BRF
139
140
cfe511b2 141ifeq ($(BR2_HAVE_DOT_CONFIG),y)
54e098e4 142
99cf7293 143# cc-option
18d979c7 144# Usage: cflags-y+=$(call cc-option, -march=winchip-c6, -march=i586)
99cf7293
BRF
145# sets -march=winchip-c6 if supported else falls back to -march=i586
146# without checking the latter.
18d979c7 147cc-option=$(shell if $(TARGET_CC) $(TARGET_CFLAGS) $(1) -S -o /dev/null -xc /dev/null \
99cf7293
BRF
148 > /dev/null 2>&1; then echo "$(1)"; else echo "$(2)"; fi ;)
149
2c649045
PK
150#############################################################
151#
152# Hide troublesome environment variables from sub processes
153#
154#############################################################
155unexport CROSS_COMPILE
156unexport ARCH
27bc59d4 157
08782ae7
EA
158#############################################################
159#
c6e43c9d 160# Setup the proper filename extensions for the host
08782ae7 161#
7dcbbfbb
BRF
162##############################################################
163ifneq ($(findstring linux,$(BR2_GNU_BUILD_SUFFIX)),)
c6e43c9d
BRF
164HOST_EXEEXT:=
165HOST_LIBEXT:=.a
166HOST_SHREXT:=.so
3096f34d 167endif
7dcbbfbb 168ifneq ($(findstring apple,$(BR2_GNU_BUILD_SUFFIX)),)
c6e43c9d
BRF
169HOST_EXEEXT:=
170HOST_LIBEXT:=.a
171HOST_SHREXT:=.dylib
3096f34d 172endif
7dcbbfbb 173ifneq ($(findstring cygwin,$(BR2_GNU_BUILD_SUFFIX)),)
c6e43c9d
BRF
174HOST_EXEEXT:=.exe
175HOST_LIBEXT:=.lib
176HOST_SHREXT:=.dll
2c279671
PK
177HOST_LOADLIBES="-lcurses -lintl"
178export HOST_LOADLIBES
3096f34d 179endif
7dcbbfbb 180ifneq ($(findstring mingw,$(BR2_GNU_BUILD_SUFFIX)),)
c6e43c9d
BRF
181HOST_EXEEXT:=.exe
182HOST_LIBEXT:=.lib
183HOST_SHREXT:=.dll
3096f34d 184endif
cb7d5b81 185
c6e43c9d 186# The preferred type of libs we build for the target
3096f34d 187ifeq ($(BR2_PREFER_STATIC_LIB),y)
c6e43c9d 188LIBTGTEXT=.a
8027784c 189#PREFERRED_LIB_FLAGS:=--disable-shared --enable-static
3096f34d 190else
c6e43c9d 191LIBTGTEXT=.so
8027784c 192#PREFERRED_LIB_FLAGS:=--disable-static --enable-shared
3096f34d 193endif
8027784c 194PREFERRED_LIB_FLAGS:=--enable-static --enable-shared
ffde94bd 195
6ad07203 196##############################################################
7dcbbfbb
BRF
197#
198# The list of stuff to build for the target toolchain
199# along with the packages to build for the target.
200#
201##############################################################
4b0d5a80 202ifeq ($(BR2_TOOLCHAIN_SOURCE),y)
3d8919a1 203BASE_TARGETS:=uclibc-configured binutils cross_compiler uclibc-target-utils kernel-headers
7dcbbfbb 204else
f85cd12c 205BASE_TARGETS:=uclibc kernel-headers
7dcbbfbb 206endif
acc706b7
BRF
207TARGETS:=
208
18d979c7 209# setup our pathes
f958d897 210include project/Makefile.in
1dbe6e33
BRF
211
212BR2_DEPENDS_DIR=$(PROJECT_BUILD_DIR)/buildroot-config
213
7dcbbfbb
BRF
214include toolchain/Makefile.in
215include package/Makefile.in
216
217#############################################################
218#
219# You should probably leave this stuff alone unless you know
220# what you are doing.
221#
222#############################################################
223
6547bced 224all: world
ffde94bd 225
2d523c23
EA
226# In this section, we need .config
227include .config.cmd
228
f958d897
US
229include project/*.mk
230
d06645d8
EA
231# We also need the various per-package makefiles, which also add
232# each selected package to TARGETS if that package was selected
233# in the .config file.
4b0d5a80 234ifeq ($(BR2_TOOLCHAIN_SOURCE),y)
acc706b7 235# avoid pulling in external toolchain which is broken for toplvl parallel builds
57310ec6
BRF
236# Explicit ordering:
237include toolchain/dependencies/dependencies.mk
238include toolchain/binutils/binutils.mk
239include toolchain/ccache/ccache.mk
240include toolchain/elf2flt/elf2flt.mk
241include toolchain/gcc/gcc-uclibc-3.x.mk
242include toolchain/gcc/gcc-uclibc-4.x.mk
243include toolchain/gdb/gdb.mk
244include toolchain/kernel-headers/kernel-headers.mk
245include toolchain/mklibs/mklibs.mk
246include toolchain/sstrip/sstrip.mk
247include toolchain/uClibc/uclibc.mk
acc706b7 248else
d06645d8 249include toolchain/*/*.mk
acc706b7
BRF
250endif
251
62b5ae4b
SH
252ifeq ($(BR2_PACKAGE_LINUX),y)
253TARGETS+=linux26-modules
254endif
acc706b7 255
d06645d8 256include package/*/*.mk
d06645d8 257
d45de0ca
JV
258TARGETS+=target-devfiles
259
79f5f1e8
EA
260# target stuff is last so it can override anything else
261include target/Makefile.in
262
d45de0ca 263TARGETS+=erase-fakeroots
c2fc93bc 264
08782ae7 265TARGETS_CLEAN:=$(patsubst %,%-clean,$(TARGETS))
3b08e64d 266TARGETS_SOURCE:=$(patsubst %,%-source,$(TARGETS) $(BASE_TARGETS))
08782ae7 267TARGETS_DIRCLEAN:=$(patsubst %,%-dirclean,$(TARGETS))
b3efde23 268TARGETS_ALL:=$(patsubst %,__real_tgt_%,$(TARGETS))
acc706b7 269# all targets depend on the crosscompiler and it's prerequisites
b3efde23 270$(TARGETS_ALL): __real_tgt_%: $(BASE_TARGETS) %
acc706b7 271
1dbe6e33
BRF
272$(BR2_DEPENDS_DIR): .config
273 rm -rf $@
b3efde23 274 mkdir -p $(@D)
1dbe6e33
BRF
275 cp -dpRf $(CONFIG)/buildroot-config $@
276
5ef9e52b 277dirs: $(DL_DIR) $(TOOL_BUILD_DIR) $(BUILD_DIR) $(STAGING_DIR) $(TARGET_DIR) \
1dbe6e33 278 $(BR2_DEPENDS_DIR) \
5ef9e52b 279 $(BINARIES_DIR) $(PROJECT_BUILD_DIR)
f958d897 280
5ef9e52b 281$(BASE_TARGETS): dirs
f958d897 282
b3efde23 283world: dependencies dirs target-host-info $(BASE_TARGETS) $(TARGETS_ALL)
ffde94bd 284
5ef9e52b 285
f958d897 286.PHONY: all world dirs clean dirclean distclean source \
b3efde23 287 $(BASE_TARGETS) $(TARGETS) $(TARGETS_ALL) \
747b16dd 288 $(TARGETS_CLEAN) $(TARGETS_DIRCLEAN) $(TARGETS_SOURCE) \
5ef9e52b 289 $(DL_DIR) $(TOOL_BUILD_DIR) $(BUILD_DIR) $(STAGING_DIR) $(TARGET_DIR) \
1dbe6e33 290 $(BR2_DEPENDS_DIR) \
5ef9e52b 291 $(BINARIES_DIR) $(PROJECT_BUILD_DIR)
ffde94bd 292
08782ae7
EA
293#############################################################
294#
ef407d3d 295# staging and target directories do NOT list these as
d99c31c6 296# dependencies anywhere else
08782ae7
EA
297#
298#############################################################
5ef9e52b 299$(DL_DIR) $(TOOL_BUILD_DIR) $(BUILD_DIR) \
c6771dfb 300 $(PROJECT_BUILD_DIR) $(BINARIES_DIR):
8d583fc0 301 @mkdir -p $@
3ad3d8a1 302
08782ae7 303$(STAGING_DIR):
9c865d75 304 @mkdir -p $(STAGING_DIR)/bin
bf38723f 305 @mkdir -p $(STAGING_DIR)/lib
7e0c890c 306ifeq ($(BR2_TOOLCHAIN_SYSROOT),y)
8027784c
BRF
307 @mkdir -p $(STAGING_DIR)/usr/lib
308else
f5905dc9 309ifneq ($(BR2_TOOLCHAIN_EXTERNAL),y)
8027784c
BRF
310 @ln -snf . $(STAGING_DIR)/usr
311 @mkdir -p $(STAGING_DIR)/usr/$(REAL_GNU_TARGET_NAME)
3da708e4 312 @ln -snf ../lib $(STAGING_DIR)/usr/lib
8027784c 313 @ln -snf ../lib $(STAGING_DIR)/usr/$(REAL_GNU_TARGET_NAME)/lib
f5905dc9 314endif
8027784c
BRF
315endif
316 @mkdir -p $(STAGING_DIR)/usr/include
ffde94bd 317
c6771dfb 318$(PROJECT_BUILD_DIR)/.root:
7547c7eb 319 mkdir -p $(TARGET_DIR)
f0ca4b82
BRF
320 if ! [ -d "$(TARGET_DIR)/bin" ]; then \
321 if [ -d "$(TARGET_SKELETON)" ]; then \
18d979c7 322 cp -fa $(TARGET_SKELETON)/* $(TARGET_DIR)/; \
74cda1e4 323 fi; \
18d979c7 324 touch $(STAGING_DIR)/.fakeroot.00000; \
f0ca4b82 325 fi
e0137736 326 -find $(TARGET_DIR) -type d -name CVS -o -name .svn | xargs rm -rf
6a262b14 327 -find $(TARGET_DIR) -type f -name .empty | xargs rm -rf
7547c7eb 328 touch $@
08782ae7 329
1dbe6e33 330$(TARGET_DIR): $(PROJECT_BUILD_DIR)/.root
c6771dfb 331
c2fc93bc 332erase-fakeroots:
5d2be049 333 rm -f $(PROJECT_BUILD_DIR)/.fakeroot*
412ca2a4 334
bc67ca29 335target-devfiles:
d45de0ca
JV
336ifeq ($(BR2_HAVE_DEVFILES),y)
337 ( scripts/copy.sh $(STAGING_DIR) $(TARGET_DIR) )
bc67ca29 338else
926646d9 339 rm -rf $(TARGET_DIR)/usr/include $(TARGET_DIR)/usr/lib/pkgconfig
d45de0ca
JV
340 find $(TARGET_DIR)/usr/lib -name '*.a' -delete
341 find $(TARGET_DIR)/lib -name '*.a' -delete
342 find $(TARGET_DIR)/usr/lib -name '*.la' -delete
343 find $(TARGET_DIR)/lib -name '*.la' -delete
bc67ca29
JV
344endif
345
3b08e64d 346source: $(TARGETS_SOURCE) $(HOST_SOURCE)
08782ae7 347
6547bced 348_source-check:
e7c08c29 349 $(MAKE) SPIDER=--spider source
825ff341 350
155971e0 351external-deps:
2ad346ab 352 @$(MAKE) -Bs BR2_WGET=$(TOPDIR)/toolchain/wget-show-external-deps.sh \
bcad6288 353 SPIDER=--spider source
155971e0 354
08782ae7
EA
355#############################################################
356#
357# Cleanup and misc junk
358#
359#############################################################
360clean: $(TARGETS_CLEAN)
3ad3d8a1 361 rm -rf $(STAGING_DIR) $(TARGET_DIR) $(IMAGE)
08782ae7
EA
362
363dirclean: $(TARGETS_DIRCLEAN)
3ad3d8a1 364 rm -rf $(STAGING_DIR) $(TARGET_DIR) $(IMAGE)
08782ae7
EA
365
366distclean:
5bc1f0c3
MF
367ifeq ($(DL_DIR),$(BASE_DIR)/dl)
368 rm -rf $(DL_DIR)
369endif
6547bced 370 rm -rf $(BUILD_DIR) $(PROJECT_BUILD_DIR) $(BINARIES_DIR) \
db8eecfc 371 $(LINUX_KERNEL) $(BASE_DIR)/include \
81df2264 372 .config.cmd
b5136193 373 $(MAKE) -C $(CONFIG) clean
08782ae7 374
3ad3d8a1 375sourceball:
6547bced 376 rm -rf $(BUILD_DIR) $(PROJECT_BUILD_DIR) $(BINARIES_DIR)
08782ae7
EA
377 set -e; \
378 cd ..; \
379 rm -f buildroot.tar.bz2; \
380 tar -cvf buildroot.tar buildroot; \
381 bzip2 -9 buildroot.tar; \
2d523c23
EA
382
383
cfe511b2 384else # ifeq ($(BR2_HAVE_DOT_CONFIG),y)
2d523c23
EA
385
386all: menuconfig
387
388# configuration
389# ---------------------------------------------------------------------------
390
c0d7d4e0
BRF
391HOSTCFLAGS=$(CFLAGS_FOR_BUILD)
392export HOSTCFLAGS
393
2d523c23 394$(CONFIG)/conf:
1dbe6e33 395 @mkdir -p $(CONFIG)/buildroot-config
fb2c8fec 396 $(MAKE) CC="$(HOSTCC)" -C $(CONFIG) conf
18d979c7 397 -@if [ ! -f .config ]; then \
2d523c23
EA
398 cp $(CONFIG_DEFCONFIG) .config; \
399 fi
400$(CONFIG)/mconf:
1dbe6e33 401 @mkdir -p $(CONFIG)/buildroot-config
fb2c8fec 402 $(MAKE) CC="$(HOSTCC)" -C $(CONFIG) conf mconf
18d979c7 403 -@if [ ! -f .config ]; then \
2d523c23
EA
404 cp $(CONFIG_DEFCONFIG) .config; \
405 fi
406
407menuconfig: $(CONFIG)/mconf
7b403ada 408 @mkdir -p $(CONFIG)/buildroot-config
153b1bea 409 @if ! KCONFIG_AUTOCONFIG=$(CONFIG)/buildroot-config/auto.conf \
62b5ae4b 410 KCONFIG_AUTOHEADER=$(CONFIG)/buildroot-config/autoconf.h \
153b1bea
BRF
411 $(CONFIG)/mconf $(CONFIG_CONFIG_IN); then \
412 test -f .config.cmd || rm -f .config; \
413 fi
2d523c23
EA
414
415config: $(CONFIG)/conf
7b403ada 416 @mkdir -p $(CONFIG)/buildroot-config
62b5ae4b
SH
417 @KCONFIG_AUTOCONFIG=$(CONFIG)/buildroot-config/auto.conf \
418 KCONFIG_AUTOHEADER=$(CONFIG)/buildroot-config/autoconf.h \
f987b7a5 419 $(CONFIG)/conf $(CONFIG_CONFIG_IN)
2d523c23
EA
420
421oldconfig: $(CONFIG)/conf
7b403ada 422 @mkdir -p $(CONFIG)/buildroot-config
62b5ae4b
SH
423 @KCONFIG_AUTOCONFIG=$(CONFIG)/buildroot-config/auto.conf \
424 KCONFIG_AUTOHEADER=$(CONFIG)/buildroot-config/autoconf.h \
f987b7a5 425 $(CONFIG)/conf -o $(CONFIG_CONFIG_IN)
2d523c23
EA
426
427randconfig: $(CONFIG)/conf
7b403ada 428 @mkdir -p $(CONFIG)/buildroot-config
62b5ae4b
SH
429 @KCONFIG_AUTOCONFIG=$(CONFIG)/buildroot-config/auto.conf \
430 KCONFIG_AUTOHEADER=$(CONFIG)/buildroot-config/autoconf.h \
f987b7a5 431 $(CONFIG)/conf -r $(CONFIG_CONFIG_IN)
2d523c23
EA
432
433allyesconfig: $(CONFIG)/conf
f987b7a5 434 cat $(CONFIG_DEFCONFIG) > .config
7b403ada 435 @mkdir -p $(CONFIG)/buildroot-config
62b5ae4b
SH
436 @KCONFIG_AUTOCONFIG=$(CONFIG)/buildroot-config/auto.conf \
437 KCONFIG_AUTOHEADER=$(CONFIG)/buildroot-config/autoconf.h \
f987b7a5 438 $(CONFIG)/conf -y $(CONFIG_CONFIG_IN)
2d523c23 439 #sed -i -e "s/^CONFIG_DEBUG.*/# CONFIG_DEBUG is not set/" .config
2d523c23
EA
440
441allnoconfig: $(CONFIG)/conf
7b403ada 442 @mkdir -p $(CONFIG)/buildroot-config
62b5ae4b
SH
443 @KCONFIG_AUTOCONFIG=$(CONFIG)/buildroot-config/auto.conf \
444 KCONFIG_AUTOHEADER=$(CONFIG)/buildroot-config/autoconf.h \
f987b7a5 445 $(CONFIG)/conf -n $(CONFIG_CONFIG_IN)
2d523c23
EA
446
447defconfig: $(CONFIG)/conf
7b403ada 448 @mkdir -p $(CONFIG)/buildroot-config
62b5ae4b
SH
449 @KCONFIG_AUTOCONFIG=$(CONFIG)/buildroot-config/auto.conf \
450 KCONFIG_AUTOHEADER=$(CONFIG)/buildroot-config/autoconf.h \
f987b7a5 451 $(CONFIG)/conf -d $(CONFIG_CONFIG_IN)
2d523c23 452
6547bced 453# check if download URLs are outdated
825ff341
BRF
454source-check: allyesconfig
455 $(MAKE) _source-check
456
2d523c23
EA
457#############################################################
458#
459# Cleanup and misc junk
460#
461#############################################################
462clean:
84518dc8 463 rm -f .config .config.old .config.cmd .tmpconfig.h .lognr.*
18d979c7 464 -$(MAKE) -C $(CONFIG) clean
2d523c23
EA
465
466distclean: clean
467 rm -rf sources/*
468
cfe511b2 469endif # ifeq ($(BR2_HAVE_DOT_CONFIG),y)
2d523c23 470
ba2e7e02
BRF
471%_defconfig: $(CONFIG)/conf
472 cp $(shell find ./target/ -name $@) .config
8820d63a 473 -@$(MAKE) oldconfig
ba2e7e02 474
82c92e1e
US
475update:
476 cp .config $(BOARD_PATH)/$(BOARD_NAME)_defconfig
477
5459a9c5 478configured: dirs host-sed kernel-headers uclibc-config busybox-config linux26-config
b8f28d65 479
126bb72f
US
480prepatch: gcc-patched binutils-patched gdb-patched uclibc-patched
481
84518dc8 482.lognr.$(PROJECT):
9220e90b 483 @echo "0" > .lognr.$(PROJECT)
def8b8d1 484
84518dc8 485log: .lognr.$(PROJECT)
9220e90b 486 @expr `cat .lognr.$(PROJECT)` + 1 > .lognr.$(PROJECT)
84518dc8 487 @echo Creating $(PROJECT)-`cat .lognr.$(PROJECT)`.log
552c0d19 488 @$(MAKE) > $(PROJECT)-`cat .lognr.$(PROJECT)`.log 2>&1
9220e90b 489
195df2e1 490
b8f28d65
US
491cross: $(BASE_TARGETS)
492
e491fba2
BRF
493help:
494 @echo 'Cleaning:'
495 @echo ' clean - delete temporary files created by build'
496 @echo ' distclean - delete all non-source files (including .config)'
497 @echo
498 @echo 'Build:'
499 @echo ' all - make world'
500 @echo
501 @echo 'Configuration:'
502 @echo ' menuconfig - interactive curses-based configurator'
503 @echo ' oldconfig - resolve any unresolved symbols in .config'
504 @echo
505 @echo 'Miscellaneous:'
506 @echo ' source - download all sources needed for offline-build'
03380402 507 @echo ' source-check - check all packages for valid download URLs'
155971e0 508 @echo ' external-deps - list external packages used'
e491fba2 509 @echo
232fa7ee 510 @echo 'See docs/README and docs/buildroot.html for further details'
663dee48 511 @echo
ba2e7e02 512
2d523c23 513.PHONY: dummy subdirs release distclean clean config oldconfig \
e491fba2 514 menuconfig tags check test depend defconfig help
50cbb4a1 515
This page took 0.212424 seconds and 4 git commands to generate.