source: trunk/config/config.mk @ 517

Last change on this file since 517 was 517, checked in by amain, 6 years ago

Merge contrib branch 340:516. Main features added:

  • updated plugin architecture
  • improved patch system
  • bitten continous integration support
  • sever build fixed over time to remain in sync with OpenWrt
File size: 2.7 KB
Line 
1# DebWrt - Debian on Embedded devices
2#
3# Copyright (C) 2010 Johan van Zoomeren
4#
5# This program is free software: you can redistribute it and/or modify
6# it under the terms of the GNU General Public License as published by
7# the Free Software Foundation, either version 3 of the License, or
8# (at your option) any later version.
9#
10# This program is distributed in the hope that it will be useful,
11# but WITHOUT ANY WARRANTY; without even the implied warranty of
12# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13# GNU General Public License for more details.
14#
15# You should have received a copy of the GNU General Public License
16# along with this program.  If not, see <http://www.gnu.org/licenses/>.
17
18TOPDIR:=$(CURDIR)
19MCONF_DIR=$(TOPDIR)/config/mconf
20CONF:=$(TOPDIR)/config/mconf/conf
21MCONF:=$(TOPDIR)/config/mconf/mconf
22
23all: config/mconf/mconf
24
25config/mconf/mconf:
26        @$(MAKE) -s -C $(MCONF_DIR) all
27
28config/mconf/conf:
29        @$(MAKE) -s -C $(MCONF_DIR) conf
30
31# Create new config-target.in from OpenWrt's targets config generated file
32# note: include the select <target> lines, exlcude all other selects
33config/target: openwrt/menuconfig
34        LC_ALL=C cat $(OPENWRT_BUILD_DIR)/tmp/.config-target.in \
35          | awk \
36            '/select\W+[[:lower:]]/ { \
37               print $0 \
38             } \
39             \
40             /select.*HAS_SUBTARGETS/ { \
41               print $0 \
42             } \
43             ! /select/ { \
44               print $0 \
45             }' \
46             | sed \
47                -e 's/prompt "Target System"/prompt "Target System" if DO_CONF_TARGETS/' \
48                -e 's/prompt "Target Profile"/prompt "Target Profile" if DO_CONF_TARGETS/' \
49             >$(TOPDIR)/config/target.in
50        cat $(OPENWRT_BUILD_DIR)/target/Config.in \
51          | grep -v "source " \
52          >$(TOPDIR)/config/archs.in
53
54config/clean:
55        $(MAKE) -C $(MCONF_DIR) clean
56
57.config:
58        @echo "Please run make menuconfig to create a configuration. Then run make again. Type make help to get a list of available DebWrt make commands"
59        @exit 1
60
61# stop our value from leaking into the config tool, which can be problematic
62config defconfig oldconfig menuconfig: TARGET_ARCH=
63
64config: plugins/generate-config config/mconf/conf FORCE
65        $(CONF) Config.in
66        @echo "Type make help to get a list of available DebWrt make commands"
67
68defconfig: plugins/generate-config config/mconf/conf FORCE
69        touch .config
70        $(CONF) -D .config Config.in
71        @echo "Type make help to get a list of available DebWrt make commands"
72
73oldconfig: plugins/generate-config config/mconf/conf FORCE
74        $(CONF) -o Config.in
75        @echo "Type make help to get a list of available DebWrt make commands"
76
77menuconfig: plugins/generate-config config/mconf/mconf FORCE
78        $(MCONF) Config.in
79        @echo "Type make help to get a list of available DebWrt make commands"
80
81.PHONY: config/clean
82
Note: See TracBrowser for help on using the repository browser.