1 include $(TOPDIR
)/rules.mk
3 # Default target skeleton stuff, may be overridden
4 TARGET_SKEL_DIR
=default
/target_skeleton
10 if
[ -f
"$(TARGET_SKELETON)" ] ; then \
11 zcat
$(TARGET_SKELETON
) |
tar -C
$(BUILD_DIR
) -xf
-; \
13 if
[ -d
"$(TARGET_SKEL_DIR)" ] ; then \
14 cp
-a
$(TARGET_SKEL_DIR
)/* $(TARGET_DIR
)/; \
16 mkdir
-p
$(TARGET_DIR
)/jffs
17 mkdir
-p
$(TARGET_DIR
)/dev
18 mkdir
-p
$(TARGET_DIR
)/proc
19 mkdir
-p
$(TARGET_DIR
)/tmp
20 mkdir
-p
$(TARGET_DIR
)/lib
21 mkdir
-p
$(TARGET_DIR
)/usr
/lib
22 mkdir
-p
$(TARGET_DIR
)/usr
/bin
23 ln
-sf
/tmp
/resolv.conf
$(TARGET_DIR
)/etc
/resolv.conf
24 rm -rf
$(TARGET_DIR
)/var
25 ln
-sf
/tmp
$(TARGET_DIR
)/var
26 -find
$(TARGET_DIR
) -type d
-name CVS | xargs
rm -rf
27 -find
$(TARGET_DIR
) -type d
-name .svn | xargs
rm -rf
32 $(TARGET_DIR
)/etc
/sysconf
:
33 mkdir
-p
$(TARGET_DIR
)/etc
34 -grep \^BR2_SYSCONF
$(TOPDIR
)/.config
> $(TARGET_DIR
)/etc
/sysconf
36 linux-compile
: utils-install lzma-install
37 linux-install
: $(TARGET_DIR
)/etc
/sysconf
$(BIN_DIR
)
39 prepare
: $(TARGET_DIR
)
40 compile
: linux-compile
41 install: image_clean linux-install
42 clean: linux-clean utils-clean lzma-clean image_clean
45 rm -f
$(BIN_DIR
)/openwrt-
*
48 $(MAKE
) -C
$(patsubst %-clean,%,$@
) clean
50 $(MAKE
) -C
$(patsubst %-prepare
,%,$@
) prepare
52 $(MAKE
) -C
$(patsubst %-compile
,%,$@
) compile
54 $(MAKE
) -C
$(patsubst %-rebuild
,%,$@
) rebuild
56 $(MAKE
) -C
$(patsubst %-install,%,$@
) install