1
0
mirror of git://projects.qi-hardware.com/openwrt-xburst.git synced 2024-11-10 16:36:16 +02:00

move wificonf and nvram stuff back to package/, remove build_mipsel/root, run install part of package/ for every board/kernel - fixes dependency mess

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@1540 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
nbd 2005-07-24 19:58:14 +00:00
parent 29313d8ecf
commit b401d50c8b
28 changed files with 77 additions and 111 deletions

View File

@ -1,6 +1,6 @@
# Makefile for OpenWRT # Makefile for OpenWRT
# #
# Copyright (C) 2005 by Felix Fietkau <nbd@vd-s.ath.cx> # Copyright (C) 2005 by Felix Fietkau <openwrt@nbd.name>
# Copyright (C) 1999-2004 by Erik Andersen <andersen@codepoet.org> # Copyright (C) 1999-2004 by Erik Andersen <andersen@codepoet.org>
# #
# This program is free software; you can redistribute it and/or modify # This program is free software; you can redistribute it and/or modify
@ -47,26 +47,6 @@ all: world
.NOTPARALLEL: .NOTPARALLEL:
##############################################################
#
# Build the toolchain
#
##############################################################
toolchain_install:
$(MAKE) -C toolchain install
##############################################################
#
# Make all packages
#
##############################################################
package_compile: target_compile
$(MAKE) -C package compile
package_install: package_compile toolchain
$(MAKE) -C package install
############################################################# #############################################################
# #
# You should probably leave this stuff alone unless you know # You should probably leave this stuff alone unless you know
@ -77,9 +57,9 @@ package_install: package_compile toolchain
# In this section, we need .config # In this section, we need .config
include .config.cmd include .config.cmd
world: $(DL_DIR) $(BUILD_DIR) configtest toolchain_install package_install target_install package_index world: $(DL_DIR) $(BUILD_DIR) configtest toolchain/install target/compile package/compile target/install package_index
.PHONY: all world clean dirclean distclean image_clean target_clean source target_install toolchain_install package_install configtest .PHONY: all world clean dirclean distclean image_clean target_clean source configtest
configtest: configtest:
-cp .config .config.test -cp .config .config.test
@ -90,12 +70,6 @@ package_index:
$(STAGING_DIR)/usr/bin/ipkg-make-index . > Packages \ $(STAGING_DIR)/usr/bin/ipkg-make-index . > Packages \
) )
target_compile:
$(MAKE) -C target compile
target_install:
$(MAKE) -C target install
$(DL_DIR): $(DL_DIR):
@mkdir -p $(DL_DIR) @mkdir -p $(DL_DIR)
@ -125,7 +99,6 @@ image_clean:
rm -rf $(BIN_DIR) rm -rf $(BIN_DIR)
target_clean: image_clean target_clean: image_clean
rm -rf $(TARGET_DIR)
rm -rf $(BUILD_DIR)/linux-*/root rm -rf $(BUILD_DIR)/linux-*/root
clean: target_clean clean: target_clean
@ -188,8 +161,6 @@ randconfig: $(CONFIG)/conf
-./scripts/configtest.pl -./scripts/configtest.pl
allyesconfig: $(CONFIG)/conf allyesconfig: $(CONFIG)/conf
#@$(CONFIG)/conf -y $(CONFIG_CONFIG_IN)
#sed -i -e "s/^CONFIG_DEBUG.*/# CONFIG_DEBUG is not set/" .config
-touch .config -touch .config
-cp .config .config.test -cp .config .config.test
@$(CONFIG)/conf -o $(CONFIG_CONFIG_IN) @$(CONFIG)/conf -o $(CONFIG_CONFIG_IN)

View File

@ -98,7 +98,7 @@ source "package/wol/Config.in"
source "package/wpa_supplicant/Config.in" source "package/wpa_supplicant/Config.in"
source "package/wput/Config.in" source "package/wput/Config.in"
source "package/xinetd/Config.in" source "package/xinetd/Config.in"
source "target/linux/package/wificonf/Config.in" source "package/wificonf/Config.in"
comment "Libraries" comment "Libraries"
source "package/glib/Config.in" source "package/glib/Config.in"

View File

@ -2,6 +2,7 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
package-:=tcp_wrappers package-:=tcp_wrappers
package-y:=nvram
package-$(BR2_PACKAGE_AICCU) += aiccu package-$(BR2_PACKAGE_AICCU) += aiccu
package-$(BR2_PACKAGE_AMWALL) += amwall package-$(BR2_PACKAGE_AMWALL) += amwall
package-$(BR2_PACKAGE_ARPTABLES) += arptables package-$(BR2_PACKAGE_ARPTABLES) += arptables
@ -134,6 +135,7 @@ package-$(BR2_PACKAGE_ULOGD) += ulogd
package-$(BR2_PACKAGE_USBUTILS) += usbutils package-$(BR2_PACKAGE_USBUTILS) += usbutils
package-$(BR2_PACKAGE_VTUN) += vtun package-$(BR2_PACKAGE_VTUN) += vtun
package-$(BR2_PACKAGE_VSFTPD) += vsftpd package-$(BR2_PACKAGE_VSFTPD) += vsftpd
package-$(BR2_PACKAGE_WIFICONF) += wificonf
package-$(BR2_PACKAGE_WIRELESS_TOOLS) += wireless-tools package-$(BR2_PACKAGE_WIRELESS_TOOLS) += wireless-tools
package-$(BR2_PACKAGE_WOL) += wol package-$(BR2_PACKAGE_WOL) += wol
package-$(BR2_PACKAGE_WPA_SUPPLICANT) += wpa_supplicant package-$(BR2_PACKAGE_WPA_SUPPLICANT) += wpa_supplicant
@ -141,19 +143,19 @@ package-$(BR2_PACKAGE_WPUT) += wput
package-$(BR2_PACKAGE_XINETD) += xinetd package-$(BR2_PACKAGE_XINETD) += xinetd
package-$(BR2_PACKAGE_ZLIB) += zlib package-$(BR2_PACKAGE_ZLIB) += zlib
DEV_LIBS:=tcp_wrappers glib ncurses openssl pcre popt zlib libnet libpcap mysql postgresql iptables matrixssl lzo gmp fuse portmap libelf uclibc++ speex libpng libgd wireless-tools DEV_LIBS:=tcp_wrappers glib ncurses openssl pcre popt zlib libnet libpcap mysql postgresql iptables matrixssl lzo gmp fuse portmap libelf uclibc++ speex libpng libgd wireless-tools nvram
DEV_LIBS_COMPILE:=$(patsubst %,%-compile,$(DEV_LIBS)) DEV_LIBS_COMPILE:=$(patsubst %,%-compile,$(DEV_LIBS))
SDK_DEFAULT_PACKAGES:=busybox dnsmasq iptables wireless-tools dropbear bridge ipkg ppp SDK_DEFAULT_PACKAGES:=busybox dnsmasq iptables wireless-tools dropbear bridge ipkg ppp
SDK_DEFAULT_COMPILE:=$(patsubst %,%-compile,$(SDK_DEFAULT_PACKAGES)) SDK_DEFAULT_COMPILE:=$(patsubst %,%-compile,$(SDK_DEFAULT_PACKAGES))
COMPILE_PACKAGES:=$(patsubst %,%-compile,$(package-y) $(package-m)) COMPILE_PACKAGES:=$(patsubst %,%-compile,$(package-y) $(package-m))
INSTALL_PACKAGES:=$(patsubst %,%-install,$(package-y)) INSTALL_PACKAGES:=$(patsubst %,%-install,$(package-y))
all: compile install all: compile
clean: $(patsubst %,%-clean,$(package-) $(package-y) $(package-m)) clean: $(patsubst %,%-clean,$(package-) $(package-y) $(package-m))
compile: $(COMPILE_PACKAGES) compile: $(COMPILE_PACKAGES)
install: base-files-install $(INSTALL_PACKAGES) install: base-files-install $(INSTALL_PACKAGES)
$(COMPILE_PACKAGES): base-files-install $(COMPILE_PACKAGES): base-files-compile
$(INSTALL_PACKAGES): base-files-install $(INSTALL_PACKAGES): base-files-install
amwall-compile: libamsel-compile amwall-compile: libamsel-compile
@ -199,7 +201,7 @@ tinc-compile: zlib-compile openssl-compile lzo-compile
tor-compile: libevent-compile openssl-compile zlib-compile tor-compile: libevent-compile openssl-compile zlib-compile
usbutils-compile: libusb-compile usbutils-compile: libusb-compile
vtun-compile: zlib-compile openssl-compile lzo-compile vtun-compile: zlib-compile openssl-compile lzo-compile
wificonf-compile: wireless-tools-compile wificonf-compile: wireless-tools-compile nvram-compile
wpa_supplicant-compile: openssl-compile wpa_supplicant-compile: openssl-compile
asterisk-compile: ncurses-compile openssl-compile asterisk-compile: ncurses-compile openssl-compile
@ -292,8 +294,11 @@ $(STAMP_DIR):
@touch $(STAMP_DIR)/.$@ @touch $(STAMP_DIR)/.$@
%-install: %-compile %-install: %-compile
@[ -f $(STAMP_DIR)/.$@ ] || $(MAKE) -C $(patsubst %-install,%,$@) install @$(MAKE) -C $(patsubst %-install,%,$@) \
@touch $(STAMP_DIR)/.$@ TARGET_DIR="$(TARGET_DIR)" \
IPKG_CONF="$(IPKG_CONF)" \
BOARD="$(BOARD)" \
install
%-rebuild: %-rebuild:
@rm -f $(STAMP_DIR)/.$(patsubst %-rebuild,%,$@)-* @rm -f $(STAMP_DIR)/.$(patsubst %-rebuild,%,$@)-*

View File

@ -4,23 +4,29 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=base-files PKG_NAME:=base-files
PKG_RELEASE:=1 PKG_RELEASE:=1
PKG_BUILD_DIR:=$(BUILD_DIR)/base-files
IDIR_BASE:=$(BUILD_DIR)/base-files include $(TOPDIR)/package/rules.mk
IDIR_BASE:=$(PKG_BUILD_DIR)/base-files
IPKG_BASE:=$(PACKAGE_DIR)/$(PKG_NAME)_$(PKG_RELEASE)_$(ARCH).ipk IPKG_BASE:=$(PACKAGE_DIR)/$(PKG_NAME)_$(PKG_RELEASE)_$(ARCH).ipk
LIBC_VERSION:=${shell cat $(STAGING_DIR)/uclibc_version} LIBC_VERSION:=${shell cat $(STAGING_DIR)/uclibc_version}
IDIR_LIBC:=$(BUILD_DIR)/uclibc IDIR_LIBC:=$(PKG_BUILD_DIR)/uclibc
IPKG_LIBC:=$(PACKAGE_DIR)/uclibc_$(LIBC_VERSION)-$(PKG_RELEASE)_$(ARCH).ipk IPKG_LIBC:=$(PACKAGE_DIR)/uclibc_$(LIBC_VERSION)-$(PKG_RELEASE)_$(ARCH).ipk
GCC_VERSION:=${shell cat $(STAGING_DIR)/gcc_version} GCC_VERSION:=${shell cat $(STAGING_DIR)/gcc_version}
IDIR_GCC:=$(BUILD_DIR)/libgcc IDIR_GCC:=$(PKG_BUILD_DIR)/libgcc
IPKG_GCC:=$(PACKAGE_DIR)/libgcc_$(GCC_VERSION)-$(PKG_RELEASE)_$(ARCH).ipk IPKG_GCC:=$(PACKAGE_DIR)/libgcc_$(GCC_VERSION)-$(PKG_RELEASE)_$(ARCH).ipk
PACKAGES:=$(IPKG_BASE) $(IPKG_LIBC) $(IPKG_GCC) PACKAGES:=$(IPKG_BASE) $(IPKG_LIBC) $(IPKG_GCC)
$(PACKAGES): $(PACKAGE_DIR) $(PKG_BUILD_DIR)/.prepared:
$(PACKAGE_DIR): mkdir -p $(PKG_BUILD_DIR) $(PACKAGE_DIR)
mkdir -p $@ touch $@
$(PKG_BUILD_DIR)/.built:
touch $@
$(IPKG_BASE): $(IPKG_BASE):
$(SCRIPT_DIR)/make-ipkg-dir.sh $(IDIR_BASE) ipkg/$(PKG_NAME).control $(PKG_RELEASE) $(ARCH) $(SCRIPT_DIR)/make-ipkg-dir.sh $(IDIR_BASE) ipkg/$(PKG_NAME).control $(PKG_RELEASE) $(ARCH)
@ -63,5 +69,3 @@ compile: $(PACKAGES)
install: compile install: compile
mkdir -p $(TARGET_DIR) mkdir -p $(TARGET_DIR)
$(IPKG) install $(PACKAGES) $(IPKG) install $(PACKAGES)
clean:
rm -rf $(IDIR_BASE) $(IDIR_LIBC) $(IDIR_GCC)

View File

@ -9,7 +9,13 @@ PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)
include $(TOPDIR)/package/rules.mk include $(TOPDIR)/package/rules.mk
BR2_PACKAGE_NVRAM:=y # does not depend on menuconfig # does not depend on menuconfig
ifneq ($(BOARD),brcm)
BR2_PACKAGE_NVRAM:=m
else
BR2_PACKAGE_NVRAM:=y
endif
$(eval $(call PKG_template,NVRAM,nvram,$(PKG_RELEASE),$(ARCH))) $(eval $(call PKG_template,NVRAM,nvram,$(PKG_RELEASE),$(ARCH)))
$(PKG_BUILD_DIR)/.prepared: $(PKG_BUILD_DIR)/.prepared:

View File

@ -1,3 +1,7 @@
# invoke ipkg with configuration in $(STAGING_DIR)/etc/ipkg.conf
IPKG := IPKG_INSTROOT=$(TARGET_DIR) IPKG_CONF_DIR=$(IPKG_CONF) $(SCRIPT_DIR)/ipkg -force-defaults -force-depends
IPKG_STATE_DIR := $(TARGET_DIR)/usr/lib/ipkg
define PKG_template define PKG_template
IPKG_$(1):=$(PACKAGE_DIR)/$(2)_$(3)_$(4).ipk IPKG_$(1):=$(PACKAGE_DIR)/$(2)_$(3)_$(4).ipk
IDIR_$(1):=$(PKG_BUILD_DIR)/ipkg/$(2) IDIR_$(1):=$(PKG_BUILD_DIR)/ipkg/$(2)

View File

@ -11,55 +11,36 @@ PKG_SOURCE_URL:=ftp://ftp.berlios.de/pub/ser/$(PKG_VERSION)/src
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_src.tar.gz PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_src.tar.gz
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION) PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
PKG_CAT:=zcat PKG_CAT:=zcat
PKG_IPK:=$(PACKAGE_DIR)/$(PKG_NAME)_$(PKG_VERSION)-$(PKG_RELEASE)_$(ARCH).ipk
PKG_IPK_DIR:=$(PKG_BUILD_DIR)/ipkg include $(TOPDIR)/package/rules.mk
$(eval $(call PKG_template,SER,ser,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
SER_MODULES := sl tm rr maxfwd usrloc registrar dbtext textops nathelper SER_MODULES := sl tm rr maxfwd usrloc registrar dbtext textops nathelper
SER_MODULE_FILES := $(foreach module,$(SER_MODULES),modules/$(module)/$(module).so) SER_MODULE_FILES := $(foreach module,$(SER_MODULES),modules/$(module)/$(module).so)
SER_MODULES := $(patsubst %,modules/%,$(SER_MODULES)) SER_MODULES := $(patsubst %,modules/%,$(SER_MODULES))
$(DL_DIR)/$(PKG_SOURCE): $(PKG_BUILD_DIR)/.built:
$(SCRIPT_DIR)/download.pl $(DL_DIR) $(PKG_SOURCE) $(PKG_MD5SUM) $(PKG_SOURCE_URL)
$(PKG_BUILD_DIR)/.patched: $(DL_DIR)/$(PKG_SOURCE)
$(PKG_CAT) $(DL_DIR)/$(PKG_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
$(PATCH) $(PKG_BUILD_DIR) ./patches
touch $(PKG_BUILD_DIR)/.patched
$(PKG_BUILD_DIR)/$(PKG_NAME): $(PKG_BUILD_DIR)/.patched
$(MAKE) -C $(PKG_BUILD_DIR) \ $(MAKE) -C $(PKG_BUILD_DIR) \
extra_defs="-DUSE_PTHREAD_MUTEX " \ extra_defs="-DUSE_PTHREAD_MUTEX " \
CC="$(TARGET_CC)" \ CC="$(TARGET_CC)" \
ARCH="$(ARCH)" \ ARCH="$(ARCH)" \
CFLAGS="$(TARGET_CFLAGS)" \ CFLAGS="$(TARGET_CFLAGS)" \
modules all modules all
touch $@
$(PKG_IPK): $(PKG_BUILD_DIR)/$(PKG_NAME) $(IPKG_SER):
$(SCRIPT_DIR)/make-ipkg-dir.sh $(PKG_IPK_DIR) $(PKG_NAME).control $(PKG_VERSION)-$(PKG_RELEASE) $(ARCH) mkdir -p $(IDIR_SER)/usr/sbin
mkdir -p $(PKG_IPK_DIR)/usr/sbin cp -a $(PKG_BUILD_DIR)/$(PKG_NAME) $(IDIR_SER)/usr/sbin/
cp -a $(PKG_BUILD_DIR)/$(PKG_NAME) $(PKG_IPK_DIR)/usr/sbin/ -$(STRIP) $(IDIR_SER)/usr/sbin/*
-$(STRIP) $(PKG_IPK_DIR)/usr/sbin/* cp -a $(PKG_BUILD_DIR)/scripts/sc $(IDIR_SER)/usr/sbin/serctl
cp -a $(PKG_BUILD_DIR)/scripts/sc $(PKG_IPK_DIR)/usr/sbin/serctl mkdir -p $(IDIR_SER)/usr/lib/ser/modules
mkdir -p $(PKG_IPK_DIR)/usr/lib/ser/modules
(cd $(PKG_BUILD_DIR);\ (cd $(PKG_BUILD_DIR);\
cp -a $(SER_MODULE_FILES) $(PKG_IPK_DIR)/usr/lib/ser/modules/; \ cp -a $(SER_MODULE_FILES) $(IDIR_SER)/usr/lib/ser/modules/; \
) )
$(STRIP) $(PKG_IPK_DIR)/usr/lib/ser/modules/* $(STRIP) $(IDIR_SER)/usr/lib/ser/modules/*
mkdir -p $(PKG_IPK_DIR)/etc/ser mkdir -p $(IDIR_SER)/etc/ser
cp -a $(PKG_BUILD_DIR)/etc/ser.cfg $(PKG_IPK_DIR)/etc/ser/ cp -a $(PKG_BUILD_DIR)/etc/ser.cfg $(IDIR_SER)/etc/ser/
mkdir -p $(PACKAGE_DIR) $(IPKG_BUILD) $(IDIR_SER) $(PACKAGE_DIR)
$(IPKG_BUILD) $(PKG_IPK_DIR) $(PACKAGE_DIR)
$(IPKG_STATE_DIR)/info/$(PKG_NAME).list: $(PKG_IPK)
$(IPKG) install $(PKG_IPK)
source: $(DL_DIR)/$(PKG_SOURCE)
prepare: $(PKG_BUILD_DIR)/.patched
compile: $(PKG_IPK)
install: $(IPKG_STATE_DIR)/info/$(PKG_NAME).list
clean:
rm -rf $(PKG_BUILD_DIR)
rm -f $(PKG_IPK)

View File

@ -9,8 +9,9 @@ PKG_BUILD_DIR:=$(BUILD_DIR)/wificonf
include $(TOPDIR)/package/rules.mk include $(TOPDIR)/package/rules.mk
ifneq ($(BOARD),brcm)
BR2_PACKAGE_WIFICONF:=m
endif
$(eval $(call PKG_template,WIFICONF,$(PKG_NAME),$(PKG_RELEASE),$(ARCH))) $(eval $(call PKG_template,WIFICONF,$(PKG_NAME),$(PKG_RELEASE),$(ARCH)))

View File

@ -52,7 +52,6 @@ SCRIPT_DIR:=$(BASE_DIR)/scripts
BIN_DIR:=$(BASE_DIR)/bin BIN_DIR:=$(BASE_DIR)/bin
STAMP_DIR:=$(BUILD_DIR)/stamp STAMP_DIR:=$(BUILD_DIR)/stamp
PACKAGE_DIR:=$(BIN_DIR)/packages PACKAGE_DIR:=$(BIN_DIR)/packages
TARGET_DIR:=$(BUILD_DIR)/root
STAMP_DIR:=$(BUILD_DIR)/stamp STAMP_DIR:=$(BUILD_DIR)/stamp
TOOL_BUILD_DIR=$(BASE_DIR)/toolchain_build_$(ARCH)$(ARCH_FPU_SUFFIX) TOOL_BUILD_DIR=$(BASE_DIR)/toolchain_build_$(ARCH)$(ARCH_FPU_SUFFIX)
# Strip off the annoying quoting # Strip off the annoying quoting
@ -106,11 +105,6 @@ ifeq ($(BR2_ENABLE_MULTILIB),y)
MULTILIB:=--enable-multilib MULTILIB:=--enable-multilib
endif endif
# invoke ipkg with configuration in $(STAGING_DIR)/etc/ipkg.conf
IPKG := IPKG_INSTROOT=$(TARGET_DIR) IPKG_CONF_DIR=$(STAGING_DIR)/etc $(SCRIPT_DIR)/ipkg -force-defaults -force-depends
IPKG_STATE_DIR := $(TARGET_DIR)/usr/lib/ipkg
# invoke ipkg-build with some default options # invoke ipkg-build with some default options
IPKG_BUILD := PATH="$(TARGET_PATH)" ipkg-build -c -o root -g root IPKG_BUILD := PATH="$(TARGET_PATH)" ipkg-build -c -o root -g root

View File

@ -13,11 +13,6 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
include ../rules.mk include ../rules.mk
# for testing
ifeq ($(BOARD),)
BOARD:=brcm
endif
LINUX_VERSION:=2.4.30 LINUX_VERSION:=2.4.30
MODULES_SUBDIR:=lib/modules/$(LINUX_VERSION) MODULES_SUBDIR:=lib/modules/$(LINUX_VERSION)
LINUX_KCONFIG:=./config/$(BOARD) LINUX_KCONFIG:=./config/$(BOARD)
@ -43,7 +38,7 @@ PKG_RELEASE := 2
KERNEL_IPKG:=$(LINUX_BUILD_DIR)/kernel-$(LINUX_VERSION)-$(BOARD)_$(PKG_RELEASE)_$(ARCH).ipk KERNEL_IPKG:=$(LINUX_BUILD_DIR)/kernel-$(LINUX_VERSION)-$(BOARD)_$(PKG_RELEASE)_$(ARCH).ipk
KERNEL_IDIR:=$(LINUX_BUILD_DIR)/kernel-ipkg KERNEL_IDIR:=$(LINUX_BUILD_DIR)/kernel-ipkg
PKG_MAKEOPTS:= IPKG="$(IPKG_KERNEL)" \ KPKG_MAKEOPTS:= IPKG="$(IPKG_KERNEL)" \
BOARD="$(BOARD)" \ BOARD="$(BOARD)" \
TARGET_DIR="$(LINUX_TARGET_DIR)" \ TARGET_DIR="$(LINUX_TARGET_DIR)" \
BUILD_DIR="$(LINUX_BUILD_DIR)" \ BUILD_DIR="$(LINUX_BUILD_DIR)" \
@ -238,20 +233,25 @@ prepare: $(LINUX_DIR)/.configured
compile: $(LINUX_DIR)/.modules_done $(TARGETS) compile: $(LINUX_DIR)/.modules_done $(TARGETS)
ln -sf $(LINUX_BUILD_DIR)/linux-$(LINUX_VERSION) $(LINUX_DIR) ln -sf $(LINUX_BUILD_DIR)/linux-$(LINUX_VERSION) $(LINUX_DIR)
$(MAKE) -C $(TOPDIR)/target/linux/package \ $(MAKE) -C $(TOPDIR)/target/linux/package \
$(PKG_MAKEOPTS) \ $(KPKG_MAKEOPTS) \
compile compile
install: compile $(TARGET_MODULES_DIR) $(KERNEL_IPKG) install: compile $(TARGET_MODULES_DIR) $(KERNEL_IPKG)
rm -rf $(LINUX_BUILD_DIR)/root* rm -rf $(LINUX_BUILD_DIR)/root*
cp -a $(BUILD_DIR)/root $(LINUX_BUILD_DIR)/
echo -e 'dest root /\noption offline_root $(LINUX_BUILD_DIR)/root' > $(LINUX_BUILD_DIR)/ipkg.conf echo -e 'dest root /\noption offline_root $(LINUX_BUILD_DIR)/root' > $(LINUX_BUILD_DIR)/ipkg.conf
[ "$(INSTALL_TARGETS)" != "" ] && $(IPKG_KERNEL) install $(INSTALL_TARGETS) || true [ "$(INSTALL_TARGETS)" != "" ] && $(IPKG_KERNEL) install $(INSTALL_TARGETS) || true
$(MAKE) -C $(TOPDIR)/package \
TARGET_DIR="$(LINUX_TARGET_DIR)" \
IPKG_CONF="$(LINUX_BUILD_DIR)" \
BOARD="$(BOARD)" \
install
$(MAKE) -C $(TOPDIR)/target/linux/package \ $(MAKE) -C $(TOPDIR)/target/linux/package \
$(PKG_MAKEOPTS) \ $(KPKG_MAKEOPTS) \
install install
mostlyclean: mostlyclean:
rm -f $(LINUX_BUILD_DIR)/linux-$(LINUX_VERSION)/.{drivers-unpacked,modules_done} rm -f $(LINUX_BUILD_DIR)/linux-$(LINUX_VERSION)/.modules_done
rm -f $(LINUX_BUILD_DIR)/linux-$(LINUX_VERSION)/.drivers-unpacked
$(MAKE) -C $(LINUX_BUILD_DIR)/linux-$(LINUX_VERSION) clean $(MAKE) -C $(LINUX_BUILD_DIR)/linux-$(LINUX_VERSION) clean
rm -f $(LINUX_KERNEL) $(LINUX_IMAGE) rm -f $(LINUX_KERNEL) $(LINUX_IMAGE)

View File

@ -8,14 +8,10 @@ package-$(BR2_PACKAGE_KMOD_OPENSWAN) += openswan
package-y += openwrt package-y += openwrt
ifeq ($(BOARD),brcm) ifeq ($(BOARD),brcm)
package-$(BR2_PACKAGE_WIFICONF) += wificonf
package-y += nvram
ifeq ($(LINUX_VERSION),2.4.30) ifeq ($(LINUX_VERSION),2.4.30)
package-$(BR2_PACKAGE_KMOD_WLCOMPAT) += wlcompat package-$(BR2_PACKAGE_KMOD_WLCOMPAT) += wlcompat
wlcompat-compile: openwrt-compile
endif endif
nvram-compile: openwrt-compile
endif endif
all: compile install all: compile install

View File

@ -4,12 +4,12 @@ include $(TOPDIR)/rules.mk
PKG_NAME := base-files-arch PKG_NAME := base-files-arch
PKG_RELEASE := 1 PKG_RELEASE := 1
PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME) PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME)-$(BOARD)
include $(TOPDIR)/package/rules.mk include $(TOPDIR)/package/rules.mk
BR2_PACKAGE_OPENWRT:=y # ignore menuconfig IDIR_OPENWRT:=$(PKG_BUILD_DIR)/ipkg
$(eval $(call PKG_template,OPENWRT,$(PKG_NAME),$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH))) IPKG_OPENWRT:=$(PACKAGE_DIR)/base-files-$(BOARD)_$(PKG_RELEASE)_$(ARCH).ipk
$(PKG_BUILD_DIR)/.prepared: $(PKG_BUILD_DIR)/.prepared:
mkdir -p $(PKG_BUILD_DIR) mkdir -p $(PKG_BUILD_DIR)
@ -31,6 +31,10 @@ endif
$(PKG_BUILD_DIR)/.built: $(PKG_BUILD_DIR)/.built:
touch $@ touch $@
$(IDIR_OPENWRT):
$(SCRIPT_DIR)/make-ipkg-dir.sh $(IDIR_OPENWRT) ipkg/base-files-arch.control $(PKG_RELEASE) $(ARCH)
$(SED) s,base-files-arch,base-files-$(BOARD),g $(IDIR_OPENWRT)/CONTROL/control
$(IPKG_OPENWRT): $(IPKG_OPENWRT):
mkdir -p $(IDIR_OPENWRT)/etc mkdir -p $(IDIR_OPENWRT)/etc
cp files/network.overrides.$(BOARD) $(IDIR_OPENWRT)/etc/network.overrides cp files/network.overrides.$(BOARD) $(IDIR_OPENWRT)/etc/network.overrides