2 # Copyright (C) 2006 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 include $(TOPDIR
)/rules.mk
10 include $(TOPDIR
)/.config
11 include $(TMP_DIR
)/.pkgdeps
12 include $(INCLUDE_DIR
)/host.mk
14 PREREQ_PACKAGES
:=$(patsubst %,%-prereq
,$(prereq-y
) $(prereq-m
))
15 DOWNLOAD_PACKAGES
:=$(patsubst %,%-download
,$(package-y
) $(package-m
))
16 COMPILE_PACKAGES
:=$(patsubst %,%-compile
,$(package-y
) $(package-m
))
17 INSTALL_PACKAGES
:=$(patsubst %,%-install,$(package-y
))
19 $(STAMP_DIR
) $(TARGET_DIR
):
22 %-prereq
: $(STAMP_DIR
) $(TARGET_DIR
)
23 $(MAKE
) -C
$(patsubst %-prereq
,%,$@
) prereq
25 %-download
: $(STAMP_DIR
) $(TARGET_DIR
)
26 $(MAKE
) -C
$(patsubst %-download
,%,$@
) download
28 %-prepare
: $(STAMP_DIR
) $(TARGET_DIR
)
29 $(MAKE
) -C
$(patsubst %-prepare
,%,$@
) prepare
31 %-compile
: $(STAMP_DIR
) $(TARGET_DIR
)
32 $(MAKE
) -C
$(patsubst %-compile
,%,$@
) compile
34 %-install: $(STAMP_DIR
) $(TARGET_DIR
)
35 $(MAKE
) -C
$(patsubst %-install,%,$@
) install
37 %-clean: $(STAMP_DIR
) $(TARGET_DIR
)
38 $(MAKE
) -C
$(patsubst %-clean,%,$@
) clean
44 $(TMP_DIR
)/.pkgdeps
: $(TMP_DIR
)/.pkginfo
45 @
$(TOPDIR
)/scripts
/gen_deps.pl
$(GENDEP_OPTS
) < $< > $@ ||
rm -f
$@
48 clean: $(patsubst %,%-clean,$(package-
) $(package-y
) $(package-m
))
49 prereq
: $(PREREQ_PACKAGES
)
50 download
: $(DOWNLOAD_PACKAGES
)
51 compile-targets
: $(COMPILE_PACKAGES
)
53 @
-rm -f
$(PACKAGE_DIR
)/*.ipk
54 $(MAKE
) compile-targets
56 install-targets
: $(INSTALL_PACKAGES
)
58 rm -rf
$(BUILD_DIR
)/root
59 $(MAKE
) install-targets
60 @if
[ -d
$(TOPDIR
)/files
]; then \
61 $(CP
) $(TOPDIR
)/files
/.
$(BUILD_DIR
)/root
; \
64 cd
$(BUILD_DIR
)/root
; \
65 for script in .
/etc
/init.d
/*; do \
66 grep
'#!/bin/sh /etc/rc.common' $$script >/dev
/null || continue
; \
67 IPKG_INSTROOT
=$(BUILD_DIR
)/root
$(which bash
) .
/etc
/rc.common
$$script enable
; \
71 index
: $(PACKAGE_DIR
)/Packages
73 $(PACKAGE_DIR
)/Packages
: $(PACKAGE_DIR
)/*.ipk
74 (cd
$(PACKAGE_DIR
); $(SCRIPT_DIR
)/ipkg-make-index.sh .
> Packages
)
77 ifeq ($(MAKECMDGOALS
),compile-targets
)
78 MAKEFLAGS
:=$(MAKEFLAGS
) -j
$(CONFIG_JLEVEL
)
This page took 0.03995 seconds and 5 git commands to generate.