1 include $(TOPDIR
)/rules.mk
3 SHARED_INCLUDE
:=${shell pwd
}/include
5 libshared-compile libnvram-compile wlc-compile
:
6 @
$(MAKE
) -C
$(patsubst %-compile
,%,$@
) compile
8 libshared-install libnvram-install wlc-install
:
9 @
$(MAKE
) -C
$(patsubst %-install,%,$@
) install
11 libshared-clean libnvram-clean wlc-clean
:
12 @
$(MAKE
) -C
$(patsubst %-clean,%,$@
) clean
14 $(TARGET_DIR
)/sbin
/mtd
: mtd.c
18 $(TARGET_DIR
)/sbin
/jffs2root
: jffs2root.c
22 # wlconf tool extracted from linksys firmware GPL.unpackedtree
23 # WRT54GS_3_37_2_1109_US
24 LINKSYS_TGZ_SITE
=http
://openwrt.openbsd-geek.de
25 LINKSYS_WLCONF_TGZ
=linksys-wlconf.
tar.gz
26 LINKSYS_WLCONF_DIR
=$(BUILD_DIR
)/linksys-wlconf
28 $(DL_DIR
)/$(LINKSYS_WLCONF_TGZ
):
29 $(WGET
) -P
$(DL_DIR
) $(LINKSYS_TGZ_SITE
)/$(LINKSYS_WLCONF_TGZ
)
31 $(LINKSYS_WLCONF_DIR
)/.unpacked
: $(DL_DIR
)/$(LINKSYS_WLCONF_TGZ
)
32 zcat
$(DL_DIR
)/$(LINKSYS_WLCONF_TGZ
) |
tar -C
$(BUILD_DIR
) $(TAR_OPTIONS
) -
33 touch
$(LINKSYS_WLCONF_DIR
)/.unpacked
35 $(TARGET_DIR
)/usr
/sbin
/wlconf
: $(LINKSYS_WLCONF_DIR
)/.unpacked
36 $(MAKE
) -C
$(LINKSYS_WLCONF_DIR
) INSTALLDIR
=$(TARGET_DIR
) \
37 CC
=$(TARGET_CC
) LD
=$(TARGET_CROSS
)ld STRIP
="$(STRIP)" \
38 CFLAGS
="$(TARGET_CFLAGS) -I. -I$(SHARED_INCLUDE) \
39 -Wall -DOPENWRT_WLCONF" \
40 LDFLAGS
="-lnvram -lshared" \
46 compile
: libnvram-compile libshared-compile wlc-compile
47 install: libnvram-install libshared-install wlc-install \
48 $(TARGET_DIR
)/sbin
/mtd
$(TARGET_DIR
)/sbin
/jffs2root
$(TARGET_DIR
)/usr
/sbin
/wlconf
50 clean: libnvram-clean libshared-clean wlc-clean
51 rm -rf
$(LINKSYS_WLCONF_DIR
)
52 rm -f
$(TARGET_DIR
)/sbin
/mtd
53 rm -f
$(TARGET_DIR
)/sbin
/jffs2root