]> Git Repo - buildroot-mgba.git/blame - Makefile
calao_usb_a9263_defconfig: lock to kernel 3.10.x
[buildroot-mgba.git] / Makefile
CommitLineData
2d523c23 1# Makefile for buildroot2
ffde94bd 2#
15b26aee 3# Copyright (C) 1999-2005 by Erik Andersen <[email protected]>
26b11df7 4# Copyright (C) 2006-2013 by the Buildroot developers <[email protected]>
ffde94bd 5#
08782ae7 6# This program is free software; you can redistribute it and/or modify
2d523c23
EA
7# it under the terms of the GNU General Public License as published by
8# the Free Software Foundation; either version 2 of the License, or
9# (at your option) any later version.
ffde94bd 10#
2d523c23
EA
11# This program is distributed in the hope that it will be useful,
12# but WITHOUT ANY WARRANTY; without even the implied warranty of
08782ae7 13# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
2d523c23 14# General Public License for more details.
b30d673c 15#
2d523c23
EA
16# You should have received a copy of the GNU General Public License
17# along with this program; if not, write to the Free Software
18# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
3ad3d8a1 19#
02bf5816 20
2d523c23
EA
21#--------------------------------------------------------------
22# Just run 'make menuconfig', configure stuff, then run 'make'.
23# You shouldn't need to mess with anything beyond this point...
24#--------------------------------------------------------------
2d239bbe 25
e5e8fae8 26# Set and export the version string
7b48cee9 27export BR2_VERSION:=2013.11-git
e5e8fae8 28
0edfb24c
TDS
29# Check for minimal make version (note: this check will break at make 10.x)
30MIN_MAKE_VERSION=3.81
8139e21c 31ifneq ($(firstword $(sort $(MAKE_VERSION) $(MIN_MAKE_VERSION))),$(MIN_MAKE_VERSION))
0edfb24c
TDS
32$(error You have make '$(MAKE_VERSION)' installed. GNU make >= $(MIN_MAKE_VERSION) is required)
33endif
34
1d4104f0
FP
35export HOSTARCH := $(shell uname -m | \
36 sed -e s/i.86/x86/ \
37 -e s/sun4u/sparc64/ \
38 -e s/arm.*/arm/ \
39 -e s/sa110/arm/ \
40 -e s/ppc64/powerpc/ \
41 -e s/ppc/powerpc/ \
42 -e s/macppc/powerpc/\
43 -e s/sh.*/sh/)
44
2d239bbe
YM
45# This top-level Makefile can *not* be executed in parallel
46.NOTPARALLEL:
47
6b1dd45b
PK
48# absolute path
49TOPDIR:=$(shell pwd)
18d979c7 50CONFIG_CONFIG_IN=Config.in
56da3859 51CONFIG=support/kconfig
a8ee1240 52DATE:=$(shell date +%Y%m%d)
a0aef7c4 53
8258df27
YM
54# Compute the full local version string so packages can use it as-is
55# Need to export it, so it can be got from environment in children (eg. mconf)
f082c7c5 56export BR2_VERSION_FULL:=$(BR2_VERSION)$(shell $(TOPDIR)/support/scripts/setlocalversion)
8258df27 57
8b6585a9 58noconfig_targets:=menuconfig nconfig gconfig xconfig config oldconfig randconfig \
1ed49963 59 %_defconfig allyesconfig allnoconfig silentoldconfig release \
6652770f 60 randpackageconfig allyespackageconfig allnopackageconfig \
9db3b47e 61 source-check print-version olddefconfig
9e250356 62
580c6d9b
TP
63# Strip quotes and then whitespaces
64qstrip=$(strip $(subst ",,$(1)))
65#"))
66
f85f2de1
PK
67# Variables for use in Make constructs
68comma:=,
69empty:=
70space:=$(empty) $(empty)
71
39ca6d50
WW
72ifneq ("$(origin O)", "command line")
73O:=output
74CONFIG_DIR:=$(TOPDIR)
aefad531 75NEED_WRAPPER=
39ca6d50
WW
76else
77# other packages might also support Linux-style out of tree builds
78# with the O=<dir> syntax (E.G. Busybox does). As make automatically
79# forwards command line variable definitions those packages get very
80# confused. Fix this by telling make to not do so
81MAKEOVERRIDES =
82# strangely enough O is still passed to submakes with MAKEOVERRIDES
83# (with make 3.81 atleast), the only thing that changes is the output
84# of the origin function (command line -> environment).
85# Unfortunately some packages don't look at origin (E.G. uClibc 0.9.31+)
86# To really make O go away, we have to override it.
87override O:=$(O)
88CONFIG_DIR:=$(O)
de846f6e
PK
89# we need to pass O= everywhere we call back into the toplevel makefile
90EXTRAMAKEARGS = O=$(O)
aefad531 91NEED_WRAPPER=y
39ca6d50
WW
92endif
93
2b0f4552
YM
94BUILDROOT_CONFIG=$(CONFIG_DIR)/.config
95
a1b0651a
US
96# Pull in the user's configuration file
97ifeq ($(filter $(noconfig_targets),$(MAKECMDGOALS)),)
dcb79995 98-include $(BUILDROOT_CONFIG)
7521f373 99endif
9741a49e 100
afc61c6e
BRF
101# To put more focus on warnings, be less verbose as default
102# Use 'make V=1' to see the full commands
103ifdef V
104 ifeq ("$(origin V)", "command line")
18d979c7 105 KBUILD_VERBOSE=$(V)
afc61c6e
BRF
106 endif
107endif
108ifndef KBUILD_VERBOSE
18d979c7 109 KBUILD_VERBOSE=0
afc61c6e
BRF
110endif
111
112ifeq ($(KBUILD_VERBOSE),1)
4df454e9 113 quiet=
18d979c7 114 Q=
1669b6ed
BRF
115ifndef VERBOSE
116 VERBOSE=1
117endif
afc61c6e
BRF
118else
119 quiet=quiet_
18d979c7 120 Q=@
afc61c6e
BRF
121endif
122
69f85924
PK
123# we want bash as shell
124SHELL:=$(shell if [ -x "$$BASH" ]; then echo $$BASH; \
afc61c6e 125 else if [ -x /bin/bash ]; then echo /bin/bash; \
18d979c7 126 else echo sh; fi; fi)
afc61c6e 127
69f85924
PK
128# kconfig uses CONFIG_SHELL
129CONFIG_SHELL:=$(SHELL)
130
131export SHELL CONFIG_SHELL quiet Q KBUILD_VERBOSE VERBOSE
afc61c6e
BRF
132
133ifndef HOSTAR
134HOSTAR:=ar
135endif
136ifndef HOSTAS
137HOSTAS:=as
138endif
139ifndef HOSTCC
140HOSTCC:=gcc
17b66aff 141HOSTCC:=$(shell which $(HOSTCC) || type -p $(HOSTCC) || echo gcc)
afc61c6e 142endif
0df02e12 143HOSTCC_NOCCACHE:=$(HOSTCC)
afc61c6e
BRF
144ifndef HOSTCXX
145HOSTCXX:=g++
17b66aff 146HOSTCXX:=$(shell which $(HOSTCXX) || type -p $(HOSTCXX) || echo g++)
afc61c6e 147endif
0df02e12 148HOSTCXX_NOCCACHE:=$(HOSTCXX)
5f97580e
BRF
149ifndef HOSTFC
150HOSTFC:=gfortran
151endif
356133b4
US
152ifndef HOSTCPP
153HOSTCPP:=cpp
154endif
afc61c6e
BRF
155ifndef HOSTLD
156HOSTLD:=ld
157endif
0f9c5b11
US
158ifndef HOSTLN
159HOSTLN:=ln
160endif
356133b4
US
161ifndef HOSTNM
162HOSTNM:=nm
163endif
69f85924
PK
164HOSTAR:=$(shell which $(HOSTAR) || type -p $(HOSTAR) || echo ar)
165HOSTAS:=$(shell which $(HOSTAS) || type -p $(HOSTAS) || echo as)
69f85924
PK
166HOSTFC:=$(shell which $(HOSTLD) || type -p $(HOSTLD) || echo || which g77 || type -p g77 || echo gfortran)
167HOSTCPP:=$(shell which $(HOSTCPP) || type -p $(HOSTCPP) || echo cpp)
168HOSTLD:=$(shell which $(HOSTLD) || type -p $(HOSTLD) || echo ld)
169HOSTLN:=$(shell which $(HOSTLN) || type -p $(HOSTLN) || echo ln)
170HOSTNM:=$(shell which $(HOSTNM) || type -p $(HOSTNM) || echo nm)
54e93328 171
5f97580e 172export HOSTAR HOSTAS HOSTCC HOSTCXX HOSTFC HOSTLD
17b66aff 173export HOSTCC_NOCCACHE HOSTCXX_NOCCACHE
afc61c6e 174
670cb306
AV
175# Make sure pkg-config doesn't look outside the buildroot tree
176unexport PKG_CONFIG_PATH
4f607edf 177unexport PKG_CONFIG_SYSROOT_DIR
670cb306 178
91123a6f
TP
179# Having DESTDIR set in the environment confuses the installation
180# steps of some packages.
181unexport DESTDIR
182
bed61a7b
GZ
183# Causes breakage with packages that needs host-ruby
184unexport RUBYOPT
185
39ca6d50
WW
186# bash prints the name of the directory on 'cd <dir>' if CDPATH is
187# set, so unset it here to not cause problems. Notice that the export
188# line doesn't affect the environment of $(shell ..) calls, so
189# explictly throw away any output from 'cd' here.
190export CDPATH:=
191BASE_DIR := $(shell mkdir -p $(O) && cd $(O) >/dev/null && pwd)
192$(if $(BASE_DIR),, $(error output directory "$(O)" does not exist))
193
194BUILD_DIR:=$(BASE_DIR)/build
195
afc61c6e 196
cfe511b2 197ifeq ($(BR2_HAVE_DOT_CONFIG),y)
54e098e4 198
95442bb3 199################################################################################
2c649045
PK
200#
201# Hide troublesome environment variables from sub processes
202#
95442bb3 203################################################################################
2c649045
PK
204unexport CROSS_COMPILE
205unexport ARCH
2bf3c166
DN
206unexport CC
207unexport CXX
208unexport CPP
209unexport CFLAGS
210unexport CXXFLAGS
211unexport GREP_OPTIONS
12c9f7dd 212unexport CONFIG_SITE
32314b44 213unexport QMAKESPEC
20ca008d 214unexport TERMINFO
27bc59d4 215
102a93bd 216GNU_HOST_NAME:=$(shell support/gnuconfig/config.guess)
60281cbf 217
95442bb3 218################################################################################
7dcbbfbb
BRF
219#
220# The list of stuff to build for the target toolchain
221# along with the packages to build for the target.
222#
95442bb3 223################################################################################
17b66aff 224
bc994c53 225ifeq ($(BR2_TOOLCHAIN_BUILDROOT),y)
e236fe48 226BASE_TARGETS += toolchain-buildroot
e57e4b96
TP
227else ifeq ($(BR2_TOOLCHAIN_EXTERNAL),y)
228BASE_TARGETS += toolchain-external
229else ifeq ($(BR2_TOOLCHAIN_CTNG),y)
230BASE_TARGETS += toolchain-crosstool-ng
7dcbbfbb 231endif
e57e4b96 232
acc706b7
BRF
233TARGETS:=
234
89464a96
PK
235# silent mode requested?
236QUIET:=$(if $(findstring s,$(MAKEFLAGS)),-q)
237
397fe5cc
TP
238# Strip off the annoying quoting
239ARCH:=$(call qstrip,$(BR2_ARCH))
65e80a0b 240
891973f5
PK
241KERNEL_ARCH:=$(shell echo "$(ARCH)" | sed -e "s/-.*//" \
242 -e s/i.86/i386/ -e s/sun4u/sparc64/ \
f59aeca6 243 -e s/arcle/arc/ \
8332ffab 244 -e s/arceb/arc/ \
891973f5 245 -e s/arm.*/arm/ -e s/sa110/arm/ \
b90a1030 246 -e s/aarch64/arm64/ \
871db074 247 -e s/bfin/blackfin/ \
891973f5
PK
248 -e s/parisc64/parisc/ \
249 -e s/powerpc64/powerpc/ \
250 -e s/ppc.*/powerpc/ -e s/mips.*/mips/ \
251 -e s/sh.*/sh/)
252
397fe5cc
TP
253ZCAT:=$(call qstrip,$(BR2_ZCAT))
254BZCAT:=$(call qstrip,$(BR2_BZCAT))
177b4b4a 255XZCAT:=$(call qstrip,$(BR2_XZCAT))
397fe5cc
TP
256TAR_OPTIONS=$(call qstrip,$(BR2_TAR_OPTIONS)) -xf
257
a2b4f7fb
GZ
258# packages compiled for the host go here
259HOST_DIR:=$(call qstrip,$(BR2_HOST_DIR))
397fe5cc 260
aebf199f
TP
261# locales to generate
262GENERATE_LOCALE=$(call qstrip,$(BR2_GENERATE_LOCALE))
263
397fe5cc 264# stamp (dependency) files go here
3b2a803d 265STAMP_DIR:=$(BASE_DIR)/stamps
397fe5cc 266
3b2a803d
TP
267BINARIES_DIR:=$(BASE_DIR)/images
268TARGET_DIR:=$(BASE_DIR)/target
6c3e3ad4 269TARGET_SKELETON=$(TOPDIR)/system/skeleton
397fe5cc 270
7e76f904
LC
271LEGAL_INFO_DIR=$(BASE_DIR)/legal-info
272REDIST_SOURCES_DIR=$(LEGAL_INFO_DIR)/sources
273LICENSE_FILES_DIR=$(LEGAL_INFO_DIR)/licenses
274LEGAL_MANIFEST_CSV=$(LEGAL_INFO_DIR)/manifest.csv
275LEGAL_LICENSES_TXT=$(LEGAL_INFO_DIR)/licenses.txt
276LEGAL_WARNINGS=$(LEGAL_INFO_DIR)/.warnings
277LEGAL_REPORT=$(LEGAL_INFO_DIR)/README
278
9226a990
TP
279# Location of a file giving a big fat warning that output/target
280# should not be used as the root filesystem.
281TARGET_DIR_WARNING_FILE=$(TARGET_DIR)/THIS_IS_NOT_YOUR_ROOT_FILESYSTEM
282
17b66aff
TP
283ifeq ($(BR2_CCACHE),y)
284CCACHE:=$(HOST_DIR)/usr/bin/ccache
43329076
TDS
285BUILDROOT_CACHE_DIR = $(call qstrip,$(BR2_CCACHE_DIR))
286export BUILDROOT_CACHE_DIR
17b66aff
TP
287HOSTCC := $(CCACHE) $(HOSTCC)
288HOSTCXX := $(CCACHE) $(HOSTCXX)
289endif
290
2b0f4552
YM
291# Scripts in support/ or post-build scripts may need to reference
292# these locations, so export them so it is easier to use
293export BUILDROOT_CONFIG
294export TARGET_DIR
295export STAGING_DIR
296export HOST_DIR
297export BINARIES_DIR
1300cb55 298export BASE_DIR
2b0f4552 299
95442bb3 300################################################################################
7dcbbfbb
BRF
301#
302# You should probably leave this stuff alone unless you know
303# what you are doing.
304#
95442bb3 305################################################################################
7dcbbfbb 306
6547bced 307all: world
ffde94bd 308
ebcfa987
AVEM
309# Include legacy before the other things, because package .mk files
310# may rely on it.
311ifneq ($(BR2_DEPRECATED),y)
312include Makefile.legacy
313endif
314
486253db 315include package/Makefile.in
a792668b
TDS
316include support/dependencies/dependencies.mk
317
d06645d8
EA
318# We also need the various per-package makefiles, which also add
319# each selected package to TARGETS if that package was selected
320# in the .config file.
bc994c53 321ifeq ($(BR2_TOOLCHAIN_BUILDROOT),y)
ed020099 322include toolchain/toolchain-buildroot.mk
26b44b2b 323else ifeq ($(BR2_TOOLCHAIN_EXTERNAL),y)
ed020099 324include toolchain/toolchain-external.mk
10c1eec2
YM
325else ifeq ($(BR2_TOOLCHAIN_CTNG),y)
326include toolchain/toolchain-crosstool-ng.mk
acc706b7
BRF
327endif
328
ee0246e1
TP
329# Include the package override file if one has been provided in the
330# configuration.
331PACKAGE_OVERRIDE_FILE=$(call qstrip,$(BR2_PACKAGE_OVERRIDE_FILE))
332ifneq ($(PACKAGE_OVERRIDE_FILE),)
333-include $(PACKAGE_OVERRIDE_FILE)
334endif
335
d06645d8 336include package/*/*.mk
d06645d8 337
64d8e9a0 338include boot/common.mk
64d8e9a0 339include linux/linux.mk
ec100c7e 340include system/system.mk
64d8e9a0 341
32faf351 342TARGETS+=target-finalize
d45de0ca 343
b87b4742
PK
344ifeq ($(BR2_ENABLE_LOCALE_PURGE),y)
345TARGETS+=target-purgelocales
346endif
347
381616e7 348ifeq ($(BR2_TOOLCHAIN_USES_GLIBC),y)
aebf199f
TP
349ifneq ($(GENERATE_LOCALE),)
350TARGETS+=target-generatelocales
351endif
352endif
353
217ef08a
TP
354ifeq ($(BR2_ECLIPSE_REGISTER),y)
355TARGETS+=toolchain-eclipse-register
356endif
357
649b5b92 358include fs/common.mk
79f5f1e8 359
9fa32ba0
TP
360TARGETS+=target-post-image
361
08782ae7 362TARGETS_CLEAN:=$(patsubst %,%-clean,$(TARGETS))
3b08e64d 363TARGETS_SOURCE:=$(patsubst %,%-source,$(TARGETS) $(BASE_TARGETS))
08782ae7 364TARGETS_DIRCLEAN:=$(patsubst %,%-dirclean,$(TARGETS))
b3efde23 365TARGETS_ALL:=$(patsubst %,__real_tgt_%,$(TARGETS))
22c2c6b5
PK
366
367# host-* dependencies have to be handled specially, as those aren't
368# visible in Kconfig and hence not added to a variable like TARGETS.
369# instead, find all the host-* targets listed in each <PKG>_DEPENDENCIES
370# variable for each enabled target.
371# Notice: this only works for newstyle gentargets/autotargets packages
372TARGETS_HOST_DEPS = $(sort $(filter host-%,$(foreach dep,\
373 $(addsuffix _DEPENDENCIES,$(call UPPERCASE,$(TARGETS))),\
374 $($(dep)))))
375# Host packages can in turn have their own dependencies. Likewise find
376# all the package names listed in the HOST_<PKG>_DEPENDENCIES for each
377# host package found above. Ideally this should be done recursively until
378# no more packages are found, but that's hard to do in make, so limit to
379# 1 level for now.
380HOST_DEPS = $(sort $(foreach dep,\
381 $(addsuffix _DEPENDENCIES,$(call UPPERCASE,$(TARGETS_HOST_DEPS))),\
382 $($(dep))))
383HOST_SOURCE += $(addsuffix -source,$(sort $(TARGETS_HOST_DEPS) $(HOST_DEPS)))
384
7e76f904
LC
385TARGETS_LEGAL_INFO:=$(patsubst %,%-legal-info,\
386 $(TARGETS) $(BASE_TARGETS) $(TARGETS_HOST_DEPS) $(HOST_DEPS))))
387
acc706b7 388# all targets depend on the crosscompiler and it's prerequisites
b3efde23 389$(TARGETS_ALL): __real_tgt_%: $(BASE_TARGETS) %
acc706b7 390
d21a176b 391dirs: $(BUILD_DIR) $(STAGING_DIR) $(TARGET_DIR) \
d0880f70 392 $(HOST_DIR) $(BINARIES_DIR) $(STAMP_DIR)
f958d897 393
ed7791e2 394$(BASE_TARGETS): dirs $(HOST_DIR)/usr/share/buildroot/toolchainfile.cmake
f958d897 395
dcb79995 396$(BUILD_DIR)/buildroot-config/auto.conf: $(BUILDROOT_CONFIG)
c729829c 397 $(MAKE) $(EXTRAMAKEARGS) HOSTCC="$(HOSTCC_NOCCACHE)" HOSTCXX="$(HOSTCXX_NOCCACHE)" silentoldconfig
0b368800
TP
398
399prepare: $(BUILD_DIR)/buildroot-config/auto.conf
400
2a786415 401toolchain: prepare dirs dependencies $(BASE_TARGETS)
ffde94bd 402
2a786415
FP
403world: toolchain $(TARGETS_ALL)
404
405.PHONY: all world toolchain dirs clean distclean source outputmakefile \
98b616d7 406 legal-info legal-info-prepare legal-info-clean printvars \
b3efde23 407 $(BASE_TARGETS) $(TARGETS) $(TARGETS_ALL) \
7e76f904 408 $(TARGETS_CLEAN) $(TARGETS_DIRCLEAN) $(TARGETS_SOURCE) $(TARGETS_LEGAL_INFO) \
d21a176b 409 $(BUILD_DIR) $(STAGING_DIR) $(TARGET_DIR) \
d0880f70 410 $(HOST_DIR) $(BINARIES_DIR) $(STAMP_DIR)
ffde94bd 411
95442bb3 412################################################################################
08782ae7 413#
ef407d3d 414# staging and target directories do NOT list these as
d99c31c6 415# dependencies anywhere else
08782ae7 416#
95442bb3 417################################################################################
d21a176b 418$(BUILD_DIR) $(HOST_DIR) $(BINARIES_DIR) $(STAMP_DIR) $(LEGAL_INFO_DIR) $(REDIST_SOURCES_DIR):
8d583fc0 419 @mkdir -p $@
3ad3d8a1 420
5628776c
SM
421# We make a symlink lib32->lib or lib64->lib as appropriate
422# MIPS64/n32 requires lib32 even though it's a 64-bit arch.
423ifeq ($(BR2_ARCH_IS_64)$(BR2_MIPS_NABI32),y)
424LIB_SYMLINK = lib64
425else
426LIB_SYMLINK = lib32
427endif
428
08782ae7 429$(STAGING_DIR):
9c865d75 430 @mkdir -p $(STAGING_DIR)/bin
bf38723f 431 @mkdir -p $(STAGING_DIR)/lib
5628776c 432 @ln -snf lib $(STAGING_DIR)/$(LIB_SYMLINK)
8027784c 433 @mkdir -p $(STAGING_DIR)/usr/lib
5628776c 434 @ln -snf lib $(STAGING_DIR)/usr/$(LIB_SYMLINK)
8027784c 435 @mkdir -p $(STAGING_DIR)/usr/include
a05c337d 436 @mkdir -p $(STAGING_DIR)/usr/bin
5ad139eb 437 @ln -snf $(STAGING_DIR) $(BASE_DIR)/staging
ffde94bd 438
2b3a43f4
DM
439ifeq ($(BR2_ROOTFS_SKELETON_CUSTOM),y)
440TARGET_SKELETON=$(BR2_ROOTFS_SKELETON_CUSTOM_PATH)
441endif
442
397fe5cc 443$(BUILD_DIR)/.root:
7547c7eb 444 mkdir -p $(TARGET_DIR)
e97376a0
DM
445 rsync -a \
446 --exclude .empty --exclude .svn --exclude .git \
447 --exclude .hg --exclude=CVS --exclude '*~' \
13c07c79 448 $(TARGET_SKELETON)/ $(TARGET_DIR)/
9226a990 449 cp support/misc/target-dir-warning.txt $(TARGET_DIR_WARNING_FILE)
5628776c
SM
450 @ln -s lib $(TARGET_DIR)/$(LIB_SYMLINK)
451 @mkdir -p $(TARGET_DIR)/usr
452 @ln -s lib $(TARGET_DIR)/usr/$(LIB_SYMLINK)
7547c7eb 453 touch $@
08782ae7 454
397fe5cc 455$(TARGET_DIR): $(BUILD_DIR)/.root
c6771dfb 456
2a97045d
TDS
457STRIP_FIND_CMD = find $(TARGET_DIR)
458ifneq (,$(call qstrip,$(BR2_STRIP_EXCLUDE_DIRS)))
459STRIP_FIND_CMD += \( $(call finddirclauses,$(TARGET_DIR),$(call qstrip,$(BR2_STRIP_EXCLUDE_DIRS))) \) -prune -o
460endif
88418bd2 461STRIP_FIND_CMD += -type f -perm /111
6ae7886f 462STRIP_FIND_CMD += -not \( $(call findfileclauses,libpthread*.so* $(call qstrip,$(BR2_STRIP_EXCLUDE_FILES))) \) -print
2a97045d 463
32faf351 464target-finalize:
94d3aa17 465 rm -rf $(TARGET_DIR)/usr/include $(TARGET_DIR)/usr/share/aclocal \
df99efb3
LC
466 $(TARGET_DIR)/usr/lib/pkgconfig $(TARGET_DIR)/usr/share/pkgconfig \
467 $(TARGET_DIR)/usr/lib/cmake $(TARGET_DIR)/usr/share/cmake
468 find $(TARGET_DIR)/usr/{lib,share}/ -name '*.cmake' -print0 | xargs -0 rm -f
027aa1d2
WB
469 find $(TARGET_DIR)/lib \( -name '*.a' -o -name '*.la' \) -print0 | xargs -0 rm -f
470 find $(TARGET_DIR)/usr/lib \( -name '*.a' -o -name '*.la' \) -print0 | xargs -0 rm -f
e48a72e5
MS
471ifneq ($(BR2_PACKAGE_GDB),y)
472 rm -rf $(TARGET_DIR)/usr/share/gdb
473endif
87b0637b 474ifneq ($(BR2_HAVE_DOCUMENTATION),y)
32faf351 475 rm -rf $(TARGET_DIR)/usr/man $(TARGET_DIR)/usr/share/man
32faf351 476 rm -rf $(TARGET_DIR)/usr/info $(TARGET_DIR)/usr/share/info
87b0637b 477 rm -rf $(TARGET_DIR)/usr/doc $(TARGET_DIR)/usr/share/doc
d701a823 478 rm -rf $(TARGET_DIR)/usr/share/gtk-doc
68ad6d4e 479 -rmdir $(TARGET_DIR)/usr/share 2>/dev/null
b0c86bcc
TP
480endif
481ifeq ($(BR2_PACKAGE_PYTHON_PY_ONLY),y)
482 find $(TARGET_DIR)/usr/lib/ -name '*.pyc' -print0 | xargs -0 rm -f
483endif
484ifeq ($(BR2_PACKAGE_PYTHON_PYC_ONLY),y)
485 find $(TARGET_DIR)/usr/lib/ -name '*.py' -print0 | xargs -0 rm -f
32faf351 486endif
2a97045d 487 $(STRIP_FIND_CMD) | xargs $(STRIPCMD) 2>/dev/null || true
f627ebeb 488 if test -d $(TARGET_DIR)/lib/modules; then \
fde26057 489 find $(TARGET_DIR)/lib/modules -type f -name '*.ko' | \
f627ebeb 490 xargs -r $(KSTRIPCMD); fi
8101c9a3 491
6ae7886f
RB
492# See http://sourceware.org/gdb/wiki/FAQ, "GDB does not see any threads
493# besides the one in which crash occurred; or SIGTRAP kills my program when
494# I set a breakpoint"
495ifeq ($(BR2_TOOLCHAIN_HAS_THREADS),y)
496 find $(TARGET_DIR)/lib -type f -name 'libpthread*.so*' | \
52e7073a 497 xargs -r $(STRIPCMD) $(STRIP_STRIP_DEBUG)
6ae7886f
RB
498endif
499
4ccde7fa
TP
500 mkdir -p $(TARGET_DIR)/etc
501 # Mandatory configuration file and auxilliary cache directory
502 # for recent versions of ldconfig
503 touch $(TARGET_DIR)/etc/ld.so.conf
504 mkdir -p $(TARGET_DIR)/var/cache/ldconfig
e49e2fed
PK
505 if [ -x "$(TARGET_CROSS)ldconfig" ]; \
506 then \
4ccde7fa 507 $(TARGET_CROSS)ldconfig -r $(TARGET_DIR); \
e49e2fed 508 else \
4ccde7fa 509 /sbin/ldconfig -r $(TARGET_DIR); \
e49e2fed 510 fi
451a8878
PK
511 ( \
512 echo "NAME=Buildroot"; \
513 echo "VERSION=$(BR2_VERSION_FULL)"; \
514 echo "ID=buildroot"; \
515 echo "VERSION_ID=$(BR2_VERSION)"; \
516 echo "PRETTY_NAME=\"Buildroot $(BR2_VERSION)\"" \
517 ) > $(TARGET_DIR)/etc/os-release
912ea81a 518
e9b77128
LC
519 @$(foreach d, $(call qstrip,$(BR2_ROOTFS_OVERLAY)), \
520 $(call MESSAGE,"Copying overlay $(d)"); \
7f860892 521 rsync -a \
afea3037 522 --exclude .empty --exclude .svn --exclude .git \
e97376a0 523 --exclude .hg --exclude=CVS --exclude '*~' \
e9b77128 524 $(d)/ $(TARGET_DIR)$(sep))
7f860892 525
dbf4978e 526 @$(foreach s, $(call qstrip,$(BR2_ROOTFS_POST_BUILD_SCRIPT)), \
1b9b1685 527 $(call MESSAGE,"Executing post-build script $(s)"); \
f1f97b3a 528 $(s) $(TARGET_DIR) $(call qstrip,$(BR2_ROOTFS_POST_SCRIPT_ARGS))$(sep))
eed7d873 529
b87b4742 530ifeq ($(BR2_ENABLE_LOCALE_PURGE),y)
397fe5cc 531LOCALE_WHITELIST=$(BUILD_DIR)/locales.nopurge
6cdf2481 532LOCALE_NOPURGE=$(call qstrip,$(BR2_ENABLE_LOCALE_WHITELIST))
b87b4742
PK
533
534target-purgelocales:
535 rm -f $(LOCALE_WHITELIST)
536 for i in $(LOCALE_NOPURGE); do echo $$i >> $(LOCALE_WHITELIST); done
537
538 for dir in $(wildcard $(addprefix $(TARGET_DIR),/usr/share/locale /usr/share/X11/locale /usr/man /usr/share/man)); \
539 do \
540 for lang in $$(cd $$dir; ls .|grep -v man); \
541 do \
542 grep -qx $$lang $(LOCALE_WHITELIST) || rm -rf $$dir/$$lang; \
543 done; \
544 done
545endif
546
aebf199f
TP
547ifneq ($(GENERATE_LOCALE),)
548# Generate locale data. Basically, we call the localedef program
549# (built by the host-localedef package) for each locale. The input
550# data comes preferably from the toolchain, or if the toolchain does
551# not have them (Linaro toolchains), we use the ones available on the
552# host machine.
553target-generatelocales: host-localedef
554 $(Q)mkdir -p $(TARGET_DIR)/usr/lib/locale/
555 $(Q)for locale in $(GENERATE_LOCALE) ; do \
8e2696ea
AV
556 inputfile=`echo $${locale} | cut -f1 -d'.' -s` ; \
557 charmap=`echo $${locale} | cut -f2 -d'.' -s` ; \
aebf199f
TP
558 if test -z "$${charmap}" ; then \
559 charmap="UTF-8" ; \
560 fi ; \
561 echo "Generating locale $${inputfile}.$${charmap}" ; \
562 I18NPATH=$(STAGING_DIR)/usr/share/i18n:/usr/share/i18n \
563 $(HOST_DIR)/usr/bin/localedef \
564 --prefix=$(TARGET_DIR) \
565 --`echo $(BR2_ENDIAN) | tr [A-Z] [a-z]`-endian \
566 -i $${inputfile} -f $${charmap} \
567 $${locale} ; \
568 done
569endif
570
9fa32ba0 571target-post-image:
9fa32ba0 572 @$(foreach s, $(call qstrip,$(BR2_ROOTFS_POST_IMAGE_SCRIPT)), \
6d90a69f 573 $(call MESSAGE,"Executing post-image script $(s)"); \
f1f97b3a 574 $(s) $(BINARIES_DIR) $(call qstrip,$(BR2_ROOTFS_POST_SCRIPT_ARGS))$(sep))
9fa32ba0 575
217ef08a
TP
576toolchain-eclipse-register:
577 ./support/scripts/eclipse-register-toolchain `readlink -f $(O)` $(notdir $(TARGET_CROSS)) $(BR2_ARCH)
578
4eb982cf 579source: dirs $(TARGETS_SOURCE) $(HOST_SOURCE)
08782ae7 580
155971e0 581external-deps:
22c2c6b5 582 @$(MAKE) -Bs DL_MODE=SHOW_EXTERNAL_DEPS $(EXTRAMAKEARGS) source | sort -u
155971e0 583
7e76f904
LC
584legal-info-clean:
585 @rm -fr $(LEGAL_INFO_DIR)
586
587legal-info-prepare: $(LEGAL_INFO_DIR)
588 @$(call MESSAGE,"Collecting legal info")
589 @$(call legal-license-file,buildroot,COPYING,COPYING)
590 @$(call legal-manifest,PACKAGE,VERSION,LICENSE,LICENSE FILES,SOURCE ARCHIVE)
591 @$(call legal-manifest,buildroot,$(BR2_VERSION_FULL),GPLv2+,COPYING,not saved)
592 @$(call legal-warning,the Buildroot source code has not been saved)
593 @$(call legal-warning,the toolchain has not been saved)
dcb79995 594 @cp $(BUILDROOT_CONFIG) $(LEGAL_INFO_DIR)/buildroot.config
7e76f904
LC
595
596legal-info: dirs legal-info-clean legal-info-prepare $(REDIST_SOURCES_DIR) \
597 $(TARGETS_LEGAL_INFO)
598 @cat support/legal-info/README.header >>$(LEGAL_REPORT)
599 @if [ -r $(LEGAL_WARNINGS) ]; then \
600 cat support/legal-info/README.warnings-header \
601 $(LEGAL_WARNINGS) >>$(LEGAL_REPORT); \
602 cat $(LEGAL_WARNINGS); fi
603 @echo "Legal info produced in $(LEGAL_INFO_DIR)"
604 @rm -f $(LEGAL_WARNINGS)
605
b7d6c8ad
TP
606show-targets:
607 @echo $(TARGETS)
608
cfe511b2 609else # ifeq ($(BR2_HAVE_DOT_CONFIG),y)
2d523c23
EA
610
611all: menuconfig
612
1ed49963
AVEM
613endif # ifeq ($(BR2_HAVE_DOT_CONFIG),y)
614
2d523c23
EA
615# configuration
616# ---------------------------------------------------------------------------
617
c0d7d4e0
BRF
618HOSTCFLAGS=$(CFLAGS_FOR_BUILD)
619export HOSTCFLAGS
620
2cc210c9
PK
621$(BUILD_DIR)/buildroot-config/%onf:
622 mkdir -p $(@D)/lxdialog
17b66aff 623 $(MAKE) CC="$(HOSTCC_NOCCACHE)" HOSTCC="$(HOSTCC_NOCCACHE)" obj=$(@D) -C $(CONFIG) -f Makefile.br $(@F)
2d523c23 624
1ed49963
AVEM
625DEFCONFIG = $(call qstrip,$(BR2_DEFCONFIG))
626
627# We don't want to fully expand BR2_DEFCONFIG here, so Kconfig will
628# recognize that if it's still at its default $(CONFIG_DIR)/defconfig
1039eb74 629COMMON_CONFIG_ENV = \
1ed49963 630 BR2_DEFCONFIG='$(call qstrip,$(value BR2_DEFCONFIG))' \
1039eb74
TP
631 KCONFIG_AUTOCONFIG=$(BUILD_DIR)/buildroot-config/auto.conf \
632 KCONFIG_AUTOHEADER=$(BUILD_DIR)/buildroot-config/autoconf.h \
0b368800 633 KCONFIG_TRISTATE=$(BUILD_DIR)/buildroot-config/tristate.config \
dcb79995 634 BUILDROOT_CONFIG=$(BUILDROOT_CONFIG)
2d523c23 635
aefad531 636xconfig: $(BUILD_DIR)/buildroot-config/qconf outputmakefile
39ca6d50 637 @mkdir -p $(BUILD_DIR)/buildroot-config
610255e7 638 @$(COMMON_CONFIG_ENV) $< $(CONFIG_CONFIG_IN)
b0df9df3 639
aefad531 640gconfig: $(BUILD_DIR)/buildroot-config/gconf outputmakefile
39ca6d50 641 @mkdir -p $(BUILD_DIR)/buildroot-config
610255e7 642 @$(COMMON_CONFIG_ENV) srctree=$(TOPDIR) $< $(CONFIG_CONFIG_IN)
2b42aae7 643
aefad531 644menuconfig: $(BUILD_DIR)/buildroot-config/mconf outputmakefile
39ca6d50 645 @mkdir -p $(BUILD_DIR)/buildroot-config
610255e7 646 @$(COMMON_CONFIG_ENV) $< $(CONFIG_CONFIG_IN)
2d523c23 647
aefad531 648nconfig: $(BUILD_DIR)/buildroot-config/nconf outputmakefile
8b6585a9 649 @mkdir -p $(BUILD_DIR)/buildroot-config
610255e7 650 @$(COMMON_CONFIG_ENV) $< $(CONFIG_CONFIG_IN)
2d523c23 651
aefad531 652config: $(BUILD_DIR)/buildroot-config/conf outputmakefile
39ca6d50 653 @mkdir -p $(BUILD_DIR)/buildroot-config
1039eb74 654 @$(COMMON_CONFIG_ENV) $< $(CONFIG_CONFIG_IN)
2d523c23 655
aefad531 656oldconfig: $(BUILD_DIR)/buildroot-config/conf outputmakefile
39ca6d50 657 mkdir -p $(BUILD_DIR)/buildroot-config
1039eb74 658 @$(COMMON_CONFIG_ENV) $< --oldconfig $(CONFIG_CONFIG_IN)
2d523c23 659
aefad531 660randconfig: $(BUILD_DIR)/buildroot-config/conf outputmakefile
39ca6d50 661 @mkdir -p $(BUILD_DIR)/buildroot-config
1039eb74 662 @$(COMMON_CONFIG_ENV) $< --randconfig $(CONFIG_CONFIG_IN)
2d523c23 663
aefad531 664allyesconfig: $(BUILD_DIR)/buildroot-config/conf outputmakefile
39ca6d50 665 @mkdir -p $(BUILD_DIR)/buildroot-config
1039eb74 666 @$(COMMON_CONFIG_ENV) $< --allyesconfig $(CONFIG_CONFIG_IN)
2d523c23 667
aefad531 668allnoconfig: $(BUILD_DIR)/buildroot-config/conf outputmakefile
39ca6d50 669 @mkdir -p $(BUILD_DIR)/buildroot-config
1039eb74 670 @$(COMMON_CONFIG_ENV) $< --allnoconfig $(CONFIG_CONFIG_IN)
2d523c23 671
aefad531 672randpackageconfig: $(BUILD_DIR)/buildroot-config/conf outputmakefile
39ca6d50 673 @mkdir -p $(BUILD_DIR)/buildroot-config
dcb79995 674 @grep -v BR2_PACKAGE_ $(BUILDROOT_CONFIG) > $(CONFIG_DIR)/.config.nopkg
8a46d4bf
PK
675 @grep '^config BR2_PACKAGE_' Config.in.legacy | \
676 while read config pkg; do \
677 echo "# $$pkg is not set" >> $(CONFIG_DIR)/.config.nopkg; done
1039eb74 678 @$(COMMON_CONFIG_ENV) \
39ca6d50 679 KCONFIG_ALLCONFIG=$(CONFIG_DIR)/.config.nopkg \
1039eb74 680 $< --randconfig $(CONFIG_CONFIG_IN)
39ca6d50 681 @rm -f $(CONFIG_DIR)/.config.nopkg
6652770f 682
aefad531 683allyespackageconfig: $(BUILD_DIR)/buildroot-config/conf outputmakefile
39ca6d50 684 @mkdir -p $(BUILD_DIR)/buildroot-config
dcb79995 685 @grep -v BR2_PACKAGE_ $(BUILDROOT_CONFIG) > $(CONFIG_DIR)/.config.nopkg
8a46d4bf
PK
686 @grep '^config BR2_PACKAGE_' Config.in.legacy | \
687 while read config pkg; do \
688 echo "# $$pkg is not set" >> $(CONFIG_DIR)/.config.nopkg; done
1039eb74 689 @$(COMMON_CONFIG_ENV) \
39ca6d50 690 KCONFIG_ALLCONFIG=$(CONFIG_DIR)/.config.nopkg \
1039eb74 691 $< --allyesconfig $(CONFIG_CONFIG_IN)
39ca6d50 692 @rm -f $(CONFIG_DIR)/.config.nopkg
6652770f 693
aefad531 694allnopackageconfig: $(BUILD_DIR)/buildroot-config/conf outputmakefile
39ca6d50 695 @mkdir -p $(BUILD_DIR)/buildroot-config
dcb79995 696 @grep -v BR2_PACKAGE_ $(BUILDROOT_CONFIG) > $(CONFIG_DIR)/.config.nopkg
1039eb74 697 @$(COMMON_CONFIG_ENV) \
39ca6d50 698 KCONFIG_ALLCONFIG=$(CONFIG_DIR)/.config.nopkg \
1039eb74 699 $< --allnoconfig $(CONFIG_CONFIG_IN)
39ca6d50 700 @rm -f $(CONFIG_DIR)/.config.nopkg
6652770f 701
aefad531 702silentoldconfig: $(BUILD_DIR)/buildroot-config/conf outputmakefile
0b368800
TP
703 @mkdir -p $(BUILD_DIR)/buildroot-config
704 $(COMMON_CONFIG_ENV) $< --silentoldconfig $(CONFIG_CONFIG_IN)
705
9db3b47e
TP
706olddefconfig: $(BUILD_DIR)/buildroot-config/conf outputmakefile
707 @mkdir -p $(BUILD_DIR)/buildroot-config
708 $(COMMON_CONFIG_ENV) $< --olddefconfig $(CONFIG_CONFIG_IN)
709
aefad531 710defconfig: $(BUILD_DIR)/buildroot-config/conf outputmakefile
39ca6d50 711 @mkdir -p $(BUILD_DIR)/buildroot-config
1ed49963 712 @$(COMMON_CONFIG_ENV) $< --defconfig$(if $(DEFCONFIG),=$(DEFCONFIG)) $(CONFIG_CONFIG_IN)
2d523c23 713
aefad531 714%_defconfig: $(BUILD_DIR)/buildroot-config/conf $(TOPDIR)/configs/%_defconfig outputmakefile
6f38119c 715 @mkdir -p $(BUILD_DIR)/buildroot-config
1039eb74 716 @$(COMMON_CONFIG_ENV) $< --defconfig=$(TOPDIR)/configs/$@ $(CONFIG_CONFIG_IN)
6f38119c 717
aefad531 718savedefconfig: $(BUILD_DIR)/buildroot-config/conf outputmakefile
e1b1a18a 719 @mkdir -p $(BUILD_DIR)/buildroot-config
1ed49963
AVEM
720 @$(COMMON_CONFIG_ENV) $< \
721 --savedefconfig=$(if $(DEFCONFIG),$(DEFCONFIG),$(CONFIG_DIR)/defconfig) \
722 $(CONFIG_CONFIG_IN)
2d523c23 723
6547bced 724# check if download URLs are outdated
07bae756 725source-check:
7c297459 726 $(MAKE) DL_MODE=SOURCE_CHECK $(EXTRAMAKEARGS) source
825ff341 727
1ed49963 728.PHONY: defconfig savedefconfig
406053d5 729
95442bb3 730################################################################################
2d523c23
EA
731#
732# Cleanup and misc junk
733#
95442bb3 734################################################################################
aefad531
YM
735
736# outputmakefile generates a Makefile in the output directory, if using a
737# separate output directory. This allows convenient use of make in the
738# output directory.
739outputmakefile:
740ifeq ($(NEED_WRAPPER),y)
f082c7c5 741 $(Q)$(TOPDIR)/support/scripts/mkmakefile $(TOPDIR) $(O)
aefad531
YM
742endif
743
98b616d7
ÉV
744# printvars prints all the variables currently defined in our Makefiles
745printvars:
746 @$(foreach V, \
747 $(sort $(.VARIABLES)), \
748 $(if $(filter-out environment% default automatic, \
749 $(origin $V)), \
750 $(info $V=$($V) ($(value $V)))))
751
2d523c23 752clean:
406053d5 753 rm -rf $(STAGING_DIR) $(TARGET_DIR) $(BINARIES_DIR) $(HOST_DIR) \
d21a176b 754 $(STAMP_DIR) $(BUILD_DIR) $(BASE_DIR)/staging \
7e76f904 755 $(LEGAL_INFO_DIR)
2d523c23
EA
756
757distclean: clean
406053d5
PK
758ifeq ($(DL_DIR),$(TOPDIR)/dl)
759 rm -rf $(DL_DIR)
760endif
761ifeq ($(O),output)
762 rm -rf $(O)
763endif
dcb79995 764 rm -rf $(BUILDROOT_CONFIG) $(CONFIG_DIR)/.config.old $(CONFIG_DIR)/.auto.deps
2d523c23 765
e491fba2
BRF
766help:
767 @echo 'Cleaning:'
406053d5 768 @echo ' clean - delete all files created by build'
e491fba2
BRF
769 @echo ' distclean - delete all non-source files (including .config)'
770 @echo
771 @echo 'Build:'
772 @echo ' all - make world'
2a786415 773 @echo ' toolchain - build toolchain'
040f6a32
SH
774 @echo ' <package>-rebuild - force recompile <package>'
775 @echo ' <package>-reconfigure - force reconfigure <package>'
e491fba2
BRF
776 @echo
777 @echo 'Configuration:'
778 @echo ' menuconfig - interactive curses-based configurator'
15f5bef0 779 @echo ' nconfig - interactive ncurses-based configurator'
c48bbb8c 780 @echo ' xconfig - interactive Qt-based configurator'
2b42aae7 781 @echo ' gconfig - interactive GTK-based configurator'
e491fba2 782 @echo ' oldconfig - resolve any unresolved symbols in .config'
9db3b47e
TP
783 @echo ' silentoldconfig - Same as oldconfig, but quietly, additionally update deps'
784 @echo ' olddefconfig - Same as silentoldconfig but sets new symbols to their default value'
c48bbb8c
PK
785 @echo ' randconfig - New config with random answer to all options'
786 @echo ' defconfig - New config with default answer to all options'
33f454bb 787 @echo ' BR2_DEFCONFIG, if set, is used as input'
d7051da8 788 @echo ' savedefconfig - Save current config as ./defconfig (minimal config)'
c48bbb8c
PK
789 @echo ' allyesconfig - New config where all options are accepted with yes'
790 @echo ' allnoconfig - New config where all options are answered with no'
6652770f
PK
791 @echo ' randpackageconfig - New config with random answer to package options'
792 @echo ' allyespackageconfig - New config where pkg options are accepted with yes'
793 @echo ' allnopackageconfig - New config where package options are answered with no'
4bb33dce
PK
794ifeq ($(BR2_PACKAGE_BUSYBOX),y)
795 @echo ' busybox-menuconfig - Run BusyBox menuconfig'
796endif
797ifeq ($(BR2_LINUX_KERNEL),y)
798 @echo ' linux-menuconfig - Run Linux kernel menuconfig'
f5777ce8 799 @echo ' linux-savedefconfig - Run Linux kernel savedefconfig'
4bb33dce
PK
800endif
801ifeq ($(BR2_TOOLCHAIN_BUILDROOT),y)
802 @echo ' uclibc-menuconfig - Run uClibc menuconfig'
803endif
804ifeq ($(BR2_TOOLCHAIN_CTNG),y)
805 @echo ' ctng-menuconfig - Run crosstool-NG menuconfig'
83f1bf9e
JCPV
806endif
807ifeq ($(BR2_TARGET_BAREBOX),y)
808 @echo ' barebox-menuconfig - Run barebox menuconfig'
809 @echo ' barebox-savedefconfig - Run barebox savedefconfig'
4bb33dce 810endif
8792cf9e
TP
811 @echo
812 @echo 'Documentation:'
813 @echo ' manual - build manual in HTML, split HTML, PDF and txt'
814 @echo ' manual-html - build manual in HTML'
815 @echo ' manual-split-html - build manual in split HTML'
816 @echo ' manual-pdf - build manual in PDF'
817 @echo ' manual-txt - build manual in txt'
818 @echo ' manual-epub - build manual in ePub'
e491fba2
BRF
819 @echo
820 @echo 'Miscellaneous:'
821 @echo ' source - download all sources needed for offline-build'
07bae756 822 @echo ' source-check - check selected packages for valid download URLs'
155971e0 823 @echo ' external-deps - list external packages used'
7e76f904 824 @echo ' legal-info - generate info about license compliance'
e491fba2 825 @echo
15f5bef0
PK
826 @echo ' make V=0|1 - 0 => quiet build (default), 1 => verbose build'
827 @echo ' make O=dir - Locate all output files in "dir", including .config'
828 @echo
b9796199 829 @$(foreach b, $(sort $(notdir $(wildcard $(TOPDIR)/configs/*_defconfig))), \
58fd779a
PK
830 printf " %-35s - Build for %s\\n" $(b) $(b:_defconfig=);)
831 @echo
8792cf9e 832 @echo 'See docs/README, or generate the Buildroot manual for further details'
663dee48 833 @echo
ba2e7e02 834
e5e8fae8 835release: OUT=buildroot-$(BR2_VERSION)
0dca7065 836
134ab1ce
PK
837# Create release tarballs. We need to fiddle a bit to add the generated
838# documentation to the git output
0dca7065 839release:
134ab1ce
PK
840 git archive --format=tar --prefix=$(OUT)/ master > $(OUT).tar
841 $(MAKE) O=$(OUT) manual-html manual-txt manual-pdf
842 tar rf $(OUT).tar $(OUT)
843 gzip -9 -c < $(OUT).tar > $(OUT).tar.gz
844 bzip2 -9 -c < $(OUT).tar > $(OUT).tar.bz2
845 rm -rf $(OUT) $(OUT).tar
e62d2ecd 846
2b91ab7a
AVEM
847print-version:
848 @echo $(BR2_VERSION_FULL)
849
b7285d00 850include docs/manual/manual.mk
8792cf9e 851
6652770f 852.PHONY: $(noconfig_targets)
This page took 0.410917 seconds and 4 git commands to generate.