diff options
author | Eric Andersen <andersen@codepoet.org> | 2001-10-24 07:58:02 +0000 |
---|---|---|
committer | Eric Andersen <andersen@codepoet.org> | 2001-10-24 07:58:02 +0000 |
commit | 3cd2760ba1b235f3ead9feaaa1d3c41def3fb3bc (patch) | |
tree | d1aa8310f145b546b4f791c09f39f953959739ff /Makefile | |
parent | b36e684fd7dc7d66f64eac9e4215029823586999 (diff) | |
download | busybox-w32-3cd2760ba1b235f3ead9feaaa1d3c41def3fb3bc.tar.gz busybox-w32-3cd2760ba1b235f3ead9feaaa1d3c41def3fb3bc.tar.bz2 busybox-w32-3cd2760ba1b235f3ead9feaaa1d3c41def3fb3bc.zip |
Fixup the new buildsystem a bit.
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 29 |
1 files changed, 22 insertions, 7 deletions
@@ -200,6 +200,7 @@ CONFIGURATION = menuconfig | |||
200 | do-it-all: menuconfig | 200 | do-it-all: menuconfig |
201 | endif | 201 | endif |
202 | 202 | ||
203 | |||
203 | SUBDIRS =applets archival console-tools editors fileutils findutils init \ | 204 | SUBDIRS =applets archival console-tools editors fileutils findutils init \ |
204 | miscutils modutils networking pwd_grp shell shellutils sysklogd \ | 205 | miscutils modutils networking pwd_grp shell shellutils sysklogd \ |
205 | textutils util-linux libbb | 206 | textutils util-linux libbb |
@@ -209,7 +210,7 @@ bbsubdirs: $(patsubst %, _dir_%, $(SUBDIRS)) | |||
209 | $(patsubst %, _dir_%, $(SUBDIRS)) : dummy include/config/MARKER | 210 | $(patsubst %, _dir_%, $(SUBDIRS)) : dummy include/config/MARKER |
210 | $(MAKE) CFLAGS="$(CFLAGS)" -C $(patsubst _dir_%, %, $@) | 211 | $(MAKE) CFLAGS="$(CFLAGS)" -C $(patsubst _dir_%, %, $@) |
211 | 212 | ||
212 | busybox: bbsubdirs | 213 | busybox: config.h depend bbsubdirs |
213 | $(CC) $(LDFLAGS) -o $@ $(shell find $(SUBDIRS) -name \*.a) $(LIBCONFIG_LIB) $(LIBRARIES) | 214 | $(CC) $(LDFLAGS) -o $@ $(shell find $(SUBDIRS) -name \*.a) $(LIBCONFIG_LIB) $(LIBRARIES) |
214 | $(STRIPCMD) | 215 | $(STRIPCMD) |
215 | 216 | ||
@@ -291,13 +292,19 @@ scripts/mkdep: scripts/mkdep.c | |||
291 | scripts/split-include: scripts/split-include.c | 292 | scripts/split-include: scripts/split-include.c |
292 | $(HOSTCC) $(HOSTCFLAGS) -o scripts/split-include scripts/split-include.c | 293 | $(HOSTCC) $(HOSTCFLAGS) -o scripts/split-include scripts/split-include.c |
293 | 294 | ||
294 | dep-files: scripts/mkdep #archdep | 295 | dep-files: scripts/mkdep |
295 | rm -f .depend .hdepend | 296 | if [ ! -f .depend ] ; then \ |
296 | scripts/mkdep -I $(TOPDIR)/include -- `find $(TOPDIR) -name \*.c -print` >> .depend | 297 | rm -f .depend .hdepend; \ |
297 | scripts/mkdep -I $(TOPDIR)/include -- `find $(TOPDIR) -name \*.h -print` >> .hdepend | 298 | mkdir -p $(TOPDIR)/include/config; \ |
298 | $(MAKE) $(patsubst %,_sfdep_%,$(SUBDIRS)) _FASTDEP_ALL_SUB_DIRS="$(SUBDIRS)" | 299 | scripts/mkdep -I $(TOPDIR)/include -- \ |
300 | `find $(TOPDIR) -name \*.c -print` >> .depend; \ | ||
301 | scripts/mkdep -I $(TOPDIR)/include -- \ | ||
302 | `find $(TOPDIR) -name \*.h -print` >> .hdepend; \ | ||
303 | $(MAKE) $(patsubst %,_sfdep_%,$(SUBDIRS)) _FASTDEP_ALL_SUB_DIRS="$(SUBDIRS)" ; \ | ||
304 | fi; | ||
305 | |||
299 | 306 | ||
300 | depend dep: dep-files | 307 | depend dep: config.h dep-files |
301 | @ echo -e "\n\nNow run 'make' to build BusyBox\n\n" | 308 | @ echo -e "\n\nNow run 'make' to build BusyBox\n\n" |
302 | 309 | ||
303 | CONFIG_SHELL := ${shell if [ -x "$$BASH" ]; then echo $$BASH; \ | 310 | CONFIG_SHELL := ${shell if [ -x "$$BASH" ]; then echo $$BASH; \ |
@@ -308,14 +315,22 @@ include/config/MARKER: scripts/split-include include/config.h | |||
308 | scripts/split-include include/config.h include/config | 315 | scripts/split-include include/config.h include/config |
309 | @ touch include/config/MARKER | 316 | @ touch include/config/MARKER |
310 | 317 | ||
318 | config.h: | ||
319 | @if [ ! -f include/config.h ] ; then \ | ||
320 | make oldconfig; \ | ||
321 | fi; | ||
322 | |||
311 | menuconfig: | 323 | menuconfig: |
324 | mkdir -p $(TOPDIR)/include/config | ||
312 | $(MAKE) -C scripts/lxdialog all | 325 | $(MAKE) -C scripts/lxdialog all |
313 | $(CONFIG_SHELL) scripts/Menuconfig sysdeps/$(TARGET_OS)/config.in | 326 | $(CONFIG_SHELL) scripts/Menuconfig sysdeps/$(TARGET_OS)/config.in |
314 | 327 | ||
315 | config: | 328 | config: |
329 | mkdir -p $(TOPDIR)/include/config | ||
316 | $(CONFIG_SHELL) scripts/Configure sysdeps/$(TARGET_OS)/config.in | 330 | $(CONFIG_SHELL) scripts/Configure sysdeps/$(TARGET_OS)/config.in |
317 | 331 | ||
318 | oldconfig: | 332 | oldconfig: |
333 | mkdir -p $(TOPDIR)/include/config | ||
319 | $(CONFIG_SHELL) scripts/Configure -d sysdeps/$(TARGET_OS)/config.in | 334 | $(CONFIG_SHELL) scripts/Configure -d sysdeps/$(TARGET_OS)/config.in |
320 | 335 | ||
321 | 336 | ||