Changeset 344


Ignore:
Timestamp:
2005-03-08T00:24:52+01:00 (13 years ago)
Author:
nbd
Message:

add libshared/libnvram and required includes under version control

Location:
trunk/openwrt/package/openwrt
Files:
27 added
2 deleted
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/openwrt/package/openwrt/Makefile

    r307 r344  
    11include $(TOPDIR)/rules.mk 
    22 
    3 include ./openwrt.mk 
     3SHARED_INCLUDE:=${shell pwd}/include 
    44 
    5 source: openwrt-source 
    6 prepare: $(LINKSYS_SHARED_DIR)/.source 
    7 compile: $(TARGET_DIR)/$(LINKSYS_SHARED_TARGET_BINARY) 
    8 install: compile openwrt 
    9 clean: openwrt-dirclean 
     5libshared-compile libnvram-compile: 
     6        @$(MAKE) -C $(patsubst %-compile,%,$@) compile 
     7         
     8libshared-install libnvram-install: 
     9        @$(MAKE) -C $(patsubst %-install,%,$@) install 
     10 
     11libshared-clean libnvram-clean: 
     12        @$(MAKE) -C $(patsubst %-clean,%,$@) clean 
     13 
     14$(TARGET_DIR)/sbin/mtd: mtd.c 
     15        $(TARGET_CC) -o $@ $< 
     16        $(STRIP) $@ 
     17 
     18$(TARGET_DIR)/sbin/jffs2root: jffs2root.c 
     19        $(TARGET_CC) -o $@ $< 
     20        $(STRIP) $@ 
     21 
     22# wlconf tool extracted from linksys firmware GPL.unpackedtree 
     23# WRT54GS_3_37_2_1109_US 
     24LINKSYS_TGZ_SITE=http://openwrt.openbsd-geek.de 
     25LINKSYS_WLCONF_TGZ=linksys-wlconf.tar.gz 
     26LINKSYS_WLCONF_DIR=$(BUILD_DIR)/linksys-wlconf 
     27LINKSYS_WLCONF_TARGET_BINARY:=usr/sbin/wlconf 
     28 
     29$(DL_DIR)/$(LINKSYS_WLCONF_TGZ): 
     30        $(WGET) -P $(DL_DIR) $(LINKSYS_TGZ_SITE)/$(LINKSYS_WLCONF_TGZ) 
     31 
     32$(LINKSYS_WLCONF_DIR)/.unpacked: $(DL_DIR)/$(LINKSYS_WLCONF_TGZ) 
     33        zcat $(DL_DIR)/$(LINKSYS_WLCONF_TGZ) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) - 
     34        touch $(LINKSYS_WLCONF_DIR)/.unpacked 
     35         
     36$(TARGET_DIR)/$(LINKSYS_WLCONF_TARGET_BINARY): $(LINKSYS_WLCONF_DIR)/.unpacked  
     37        $(MAKE) -C $(LINKSYS_WLCONF_DIR) INSTALLDIR=$(TARGET_DIR) \ 
     38                CC=$(TARGET_CC) LD=$(TARGET_CROSS)ld STRIP="$(STRIP)" \ 
     39                CFLAGS="$(TARGET_CFLAGS) -I. -I$(SHARED_INCLUDE) \ 
     40                        -Wall -DOPENWRT_WLCONF" \ 
     41                LDFLAGS="-lnvram -lshared" \ 
     42                        install 
     43        $(STRIP) $@ 
     44 
     45 
     46source: 
     47prepare:  
     48compile: libnvram-compile libshared-compile 
     49install: libnvram-install libshared-install $(TARGET_DIR)/sbin/mtd $(TARGET_DIR)/sbin/jffs2root $(TARGET_DIR)/$(LINKSYS_WLCONF_TARGET_BINARY) 
     50clean: libnvram-clean libshared-clean 
     51        rm -rf $(LINKSYS_WLCONF_DIR) 
     52        rm -f $(TARGET_DIR)/sbin/mtd 
     53        rm -f $(TARGET_DIR)/sbin/jffs2root 
Note: See TracChangeset for help on using the changeset viewer.