add board tag to kernel module version and add versioned depend (does not work with...
authornbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Sat, 11 Jun 2005 15:36:31 +0000 (15:36 +0000)
committernbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Sat, 11 Jun 2005 15:36:31 +0000 (15:36 +0000)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@1202 3c298f89-4303-0410-b956-a3cf2f4a3e73

openwrt/target/linux/control/kmod-ip6tables.control
openwrt/target/linux/control/kmod-usb-ohci.control
openwrt/target/linux/control/kmod-usb-uhci.control
openwrt/target/linux/control/kmod-usb2.control
openwrt/target/linux/linux-2.4/Makefile
openwrt/target/linux/package/Makefile
openwrt/target/linux/package/fuse/Makefile
openwrt/target/linux/package/openswan/Makefile
openwrt/target/linux/package/shfs/Makefile
openwrt/target/linux/package/wlcompat/Makefile
openwrt/target/linux/rules.mk

index 32a72aa..777ab14 100644 (file)
@@ -4,4 +4,3 @@ Section: net
 Maintainer: Felix Fietkau <nbd@vd-s.ath.cx>
 Source: buildroot internal
 Description: Kernel modules for ip6tables
 Maintainer: Felix Fietkau <nbd@vd-s.ath.cx>
 Source: buildroot internal
 Description: Kernel modules for ip6tables
-Depends: kmod-ipv6
index cc87fa8..adb6e27 100644 (file)
@@ -3,5 +3,4 @@ Priority: optional
 Section: sys
 Maintainer: Felix Fietkau <nbd@vd-s.ath.cx>
 Source: buildroot internal
 Section: sys
 Maintainer: Felix Fietkau <nbd@vd-s.ath.cx>
 Source: buildroot internal
-Depends: kmod-usb-core
 Description: Kernel driver for OHCI USB controllers
 Description: Kernel driver for OHCI USB controllers
index 53a07d8..c7e678f 100644 (file)
@@ -3,5 +3,4 @@ Priority: optional
 Section: sys
 Maintainer: Felix Fietkau <nbd@vd-s.ath.cx>
 Source: buildroot internal
 Section: sys
 Maintainer: Felix Fietkau <nbd@vd-s.ath.cx>
 Source: buildroot internal
-Depends: kmod-usb-core
 Description: Kernel driver for UHCI USB controllers
 Description: Kernel driver for UHCI USB controllers
index 8fef6cd..48da3a6 100644 (file)
@@ -3,5 +3,4 @@ Priority: optional
 Section: sys
 Maintainer: Felix Fietkau <nbd@vd-s.ath.cx>
 Source: buildroot internal
 Section: sys
 Maintainer: Felix Fietkau <nbd@vd-s.ath.cx>
 Source: buildroot internal
-Depends: kmod-usb-core
 Description: Kernel driver for USB2 controllers
 Description: Kernel driver for USB2 controllers
index db7d71c..e8ce928 100644 (file)
@@ -40,7 +40,10 @@ MODULES_DIR := $(LINUX_BUILD_DIR)/modules/$(MODULES_SUBDIR)
 TARGET_MODULES_DIR := $(TARGET_DIR)/lib/modules/$(LINUX_VERSION)
 IPKG_KERNEL:=IPKG_TMP=$(BUILD_DIR)/tmp IPKG_INSTROOT=$(LINUX_TARGET_DIR) IPKG_CONF_DIR=$(LINUX_BUILD_DIR) $(SCRIPT_DIR)/ipkg -force-defaults -force-depends
 
 TARGET_MODULES_DIR := $(TARGET_DIR)/lib/modules/$(LINUX_VERSION)
 IPKG_KERNEL:=IPKG_TMP=$(BUILD_DIR)/tmp IPKG_INSTROOT=$(LINUX_TARGET_DIR) IPKG_CONF_DIR=$(LINUX_BUILD_DIR) $(SCRIPT_DIR)/ipkg -force-defaults -force-depends
 
-KERNEL_IPKG:=$(LINUX_BUILD_DIR)/kernel_$(LINUX_VERSION)-$(BOARD)_$(ARCH).ipk
+PKG_BUILD_DIR := $(LINUX_BUILD_DIR)/linux-modules
+PKG_RELEASE := 1
+
+KERNEL_IPKG:=$(LINUX_BUILD_DIR)/kernel_$(LINUX_VERSION)-$(BOARD)-$(PKG_RELEASE)_$(ARCH).ipk
 KERNEL_IDIR:=$(LINUX_BUILD_DIR)/kernel-ipkg
 
 include $(LINUX_KCONFIG)
 KERNEL_IDIR:=$(LINUX_BUILD_DIR)/kernel-ipkg
 
 include $(LINUX_KCONFIG)
@@ -48,9 +51,6 @@ ifeq ($(BOARD),brcm)
 include ./broadcom.mk
 endif
 
 include ./broadcom.mk
 endif
 
-PKG_BUILD_DIR := $(LINUX_BUILD_DIR)/linux-modules
-PKG_RELEASE := 1
-
 TARGETS := 
 INSTALL_TARGETS := $(KERNEL_IPKG)
 
 TARGETS := 
 INSTALL_TARGETS := $(KERNEL_IPKG)
 
@@ -77,7 +77,7 @@ $(eval $(call KMOD_template,IPTABLES_V4_EXTRA,iptables-extra,\
 ))
 $(eval $(call KMOD_template,IPTABLES_V6,ip6tables,\
        $(MODULES_DIR)/kernel/net/ipv6/netfilter/ip*.o \
 ))
 $(eval $(call KMOD_template,IPTABLES_V6,ip6tables,\
        $(MODULES_DIR)/kernel/net/ipv6/netfilter/ip*.o \
-,CONFIG_IP6_NF_IPTABLES))
+,CONFIG_IP6_NF_IPTABLES,kmod-ipv6))
 $(eval $(call KMOD_template,IPV6,ipv6,\
        $(MODULES_DIR)/kernel/net/ipv6/ipv6.o \
 ,CONFIG_IPV6))
 $(eval $(call KMOD_template,IPV6,ipv6,\
        $(MODULES_DIR)/kernel/net/ipv6/ipv6.o \
 ,CONFIG_IPV6))
@@ -94,13 +94,13 @@ $(eval $(call KMOD_template,USB,usb-core,\
 ,CONFIG_USB))
 $(eval $(call KMOD_template,USB_UHCI,usb-uhci,\
        $(MODULES_DIR)/kernel/drivers/usb/host/uhci.o \
 ,CONFIG_USB))
 $(eval $(call KMOD_template,USB_UHCI,usb-uhci,\
        $(MODULES_DIR)/kernel/drivers/usb/host/uhci.o \
-,CONFIG_USB_UHCI_ALT))
+,CONFIG_USB_UHCI_ALT,kmod-usb-core))
 $(eval $(call KMOD_template,USB_OHCI,usb-ohci,\
        $(MODULES_DIR)/kernel/drivers/usb/host/usb-ohci.o \
 $(eval $(call KMOD_template,USB_OHCI,usb-ohci,\
        $(MODULES_DIR)/kernel/drivers/usb/host/usb-ohci.o \
-,CONFIG_USB_OHCI))
+,CONFIG_USB_OHCI,kmod-usb-core))
 $(eval $(call KMOD_template,USB2,usb2,\
        $(MODULES_DIR)/kernel/drivers/usb/host/ehci-hcd.o \
 $(eval $(call KMOD_template,USB2,usb2,\
        $(MODULES_DIR)/kernel/drivers/usb/host/ehci-hcd.o \
-,CONFIG_USB_EHCI_HCD))
+,CONFIG_USB_EHCI_HCD,kmod-usb-core))
 $(eval $(call KMOD_template,USB_STORAGE,usb-storage,\
        $(MODULES_DIR)/kernel/drivers/scsi/*.o \
        $(MODULES_DIR)/kernel/drivers/usb/storage/*.o \
 $(eval $(call KMOD_template,USB_STORAGE,usb-storage,\
        $(MODULES_DIR)/kernel/drivers/scsi/*.o \
        $(MODULES_DIR)/kernel/drivers/usb/storage/*.o \
@@ -216,7 +216,7 @@ $(TARGET_MODULES_DIR):
 $(KERNEL_IPKG):
        rm -rf $(KERNEL_IDIR)
        mkdir -p $(KERNEL_IDIR)/etc
 $(KERNEL_IPKG):
        rm -rf $(KERNEL_IDIR)
        mkdir -p $(KERNEL_IDIR)/etc
-       $(SCRIPT_DIR)/make-ipkg-dir.sh $(KERNEL_IDIR) ../control/kernel.control $(LINUX_VERSION)-$(BOARD) $(ARCH)
+       $(SCRIPT_DIR)/make-ipkg-dir.sh $(KERNEL_IDIR) ../control/kernel.control $(LINUX_VERSION)-$(BOARD)-$(PKG_RELEASE) $(ARCH)
        if [ -f ./config/$(BOARD).modules ]; then \
                cp ./config/$(BOARD).modules $(KERNEL_IDIR)/etc/modules; \
        fi
        if [ -f ./config/$(BOARD).modules ]; then \
                cp ./config/$(BOARD).modules $(KERNEL_IDIR)/etc/modules; \
        fi
@@ -227,10 +227,12 @@ prepare: $(LINUX_DIR)/.configured
 compile: $(LINUX_DIR)/.modules_done $(TARGETS)
        ln -sf $(LINUX_BUILD_DIR)/linux-$(LINUX_VERSION) $(LINUX_DIR)
        $(MAKE) -C $(TOPDIR)/target/linux/package \
 compile: $(LINUX_DIR)/.modules_done $(TARGETS)
        ln -sf $(LINUX_BUILD_DIR)/linux-$(LINUX_VERSION) $(LINUX_DIR)
        $(MAKE) -C $(TOPDIR)/target/linux/package \
+               BOARD="$(BOARD)" \
                TARGET_DIR="$(LINUX_TARGET_DIR)" \
                BUILD_DIR="$(LINUX_BUILD_DIR)" \
                KERNEL_DIR="$(LINUX_SOURCE_DIR)" \
                TARGET_DIR="$(LINUX_TARGET_DIR)" \
                BUILD_DIR="$(LINUX_BUILD_DIR)" \
                KERNEL_DIR="$(LINUX_SOURCE_DIR)" \
-               LINUX_VERSION="$(LINUX_VERSION)"
+               LINUX_VERSION="$(LINUX_VERSION)" \
+               KERNEL_RELEASE="$(PKG_RELEASE)"
 
 install: compile $(TARGET_MODULES_DIR) $(KERNEL_IPKG)
        rm -rf $(LINUX_BUILD_DIR)/root*
 
 install: compile $(TARGET_MODULES_DIR) $(KERNEL_IPKG)
        rm -rf $(LINUX_BUILD_DIR)/root*
index 055bd2f..fd66e5a 100644 (file)
@@ -13,28 +13,27 @@ clean: $(patsubst %,%-clean,$(package-) $(package-y) $(package-m))
 compile: $(patsubst %,%-compile,$(package-y) $(package-m))
 install: $(patsubst %,%-install,$(package-y))
 
 compile: $(patsubst %,%-compile,$(package-y) $(package-m))
 install: $(patsubst %,%-install,$(package-y))
 
-%-prepare:
-       $(MAKE) -C $(patsubst %-prepare,%,$@) \
+MAKEOPTS:=     BOARD="$(BOARD)" \
                TARGET_DIR="$(TARGET_DIR)" \
                BUILD_DIR="$(BUILD_DIR)" \
                KERNEL_DIR="$(KERNEL_DIR)" \
                LINUX_VERSION="$(LINUX_VERSION)" \
                TARGET_DIR="$(TARGET_DIR)" \
                BUILD_DIR="$(BUILD_DIR)" \
                KERNEL_DIR="$(KERNEL_DIR)" \
                LINUX_VERSION="$(LINUX_VERSION)" \
+               KERNEL_RELEASE="$(KERNEL_RELEASE)"
+
+
+%-prepare:
+       $(MAKE) -C $(patsubst %-prepare,%,$@) \
+               $(MAKEOPTS) \
                prepare
 
 %-compile: %-prepare 
        $(MAKE) -C $(patsubst %-compile,%,$@) \
                prepare
 
 %-compile: %-prepare 
        $(MAKE) -C $(patsubst %-compile,%,$@) \
-               TARGET_DIR="$(TARGET_DIR)" \
-               BUILD_DIR="$(BUILD_DIR)" \
-               KERNEL_DIR="$(KERNEL_DIR)" \
-               LINUX_VERSION="$(LINUX_VERSION)" \
+               $(MAKEOPTS) \
                compile
 
 %-install: %-compile
        $(MAKE) -C $(patsubst %-install,%,$@) \
                compile
 
 %-install: %-compile
        $(MAKE) -C $(patsubst %-install,%,$@) \
-               TARGET_DIR="$(TARGET_DIR)" \
-               BUILD_DIR="$(BUILD_DIR)" \
-               KERNEL_DIR="$(KERNEL_DIR)" \
-               LINUX_VERSION="$(LINUX_VERSION)" \
+               $(MAKEOPTS) \
                install
 
 %-clean:
                install
 
 %-clean:
index 9db6295..8b997d6 100644 (file)
@@ -20,7 +20,7 @@ endif
 
 include $(TOPDIR)/package/rules.mk
 
 
 include $(TOPDIR)/package/rules.mk
 
-$(eval $(call PKG_template,KMOD_FUSE,kmod-fuse,$(LINUX_VERSION)+$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
+$(eval $(call PKG_template,KMOD_FUSE,kmod-fuse,$(LINUX_VERSION)$(BOARD)+$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH),kernel ($(LINUX_VERSION)-$(BOARD)-$(KERNEL_RELEASE))))
 
 $(PKG_BUILD_DIR)/.configured:
        (cd $(PKG_BUILD_DIR); \
 
 $(PKG_BUILD_DIR)/.configured:
        (cd $(PKG_BUILD_DIR); \
index 5ebb870..a105a1f 100644 (file)
@@ -18,7 +18,7 @@ ifeq ($(KERNEL_DIR),)
 KERNEL_DIR:=$(LINUX_DIR)
 endif
 
 KERNEL_DIR:=$(LINUX_DIR)
 endif
 
-$(eval $(call PKG_template,KMOD_OPENSWAN,kmod-openswan,$(LINUX_VERSION)+$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
+$(eval $(call PKG_template,KMOD_OPENSWAN,kmod-openswan,$(LINUX_VERSION)$(BOARD)+$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH),kernel ($(LINUX_VERSION)-$(BOARD)-$(KERNEL_RELEASE))))
 
 FLAGS := $(TARGET_CFLAGS) -I$(PKG_BUILD_DIR)/linux/include -L$(STAGING_DIR)/usr/lib -I$(STAGING_DIR)/usr/include
 
 
 FLAGS := $(TARGET_CFLAGS) -I$(PKG_BUILD_DIR)/linux/include -L$(STAGING_DIR)/usr/lib -I$(STAGING_DIR)/usr/include
 
index a329bbf..3604606 100644 (file)
@@ -20,7 +20,7 @@ endif
 
 include $(TOPDIR)/package/rules.mk
 
 
 include $(TOPDIR)/package/rules.mk
 
-$(eval $(call PKG_template,KMOD_SHFS,kmod-shfs,$(LINUX_VERSION)+$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
+$(eval $(call PKG_template,KMOD_SHFS,kmod-shfs,$(LINUX_VERSION)$(BOARD)+$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH),kernel ($(LINUX_VERSION)-$(BOARD)-$(KERNEL_RELEASE))))
 
 $(PKG_BUILD_DIR)/.configured:
        touch $@
 
 $(PKG_BUILD_DIR)/.configured:
        touch $@
index da90552..706948e 100644 (file)
@@ -8,7 +8,7 @@ PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME)
 
 include $(TOPDIR)/package/rules.mk
 
 
 include $(TOPDIR)/package/rules.mk
 
-$(eval $(call PKG_template,KMOD_WLCOMPAT,$(PKG_NAME),$(LINUX_VERSION)-$(PKG_RELEASE),$(ARCH)))
+$(eval $(call PKG_template,KMOD_WLCOMPAT,$(PKG_NAME),$(LINUX_VERSION)-$(BOARD)-$(PKG_RELEASE),$(ARCH),kernel ($(LINUX_VERSION)-$(BOARD)-$(KERNEL_RELEASE))))
 
 ifeq ($(KERNEL_DIR),)
 KERNEL_DIR:=$(LINUX_DIR)
 
 ifeq ($(KERNEL_DIR),)
 KERNEL_DIR:=$(LINUX_DIR)
index 451ec26..9446c34 100644 (file)
@@ -5,7 +5,13 @@ else
 KDEPEND_$(1):=$($(4))
 endif
 
 KDEPEND_$(1):=$($(4))
 endif
 
-PKG_$(1) := $(PACKAGE_DIR)/kmod-$(2)_$(LINUX_VERSION)-$(PKG_RELEASE)_$(ARCH).ipk
+ifeq ($$(strip $(5)),)
+IDEPEND_$(1):=kernel ($(LINUX_VERSION)-$(BOARD)-$(PKG_RELEASE))
+else
+IDEPEND_$(1):=kernel ($(LINUX_VERSION)-$(BOARD)-$(PKG_RELEASE)), $(5)
+endif
+
+PKG_$(1) := $(PACKAGE_DIR)/kmod-$(2)_$(LINUX_VERSION)-$(BOARD)-$(PKG_RELEASE)_$(ARCH).ipk
 I_$(1) := $(PKG_BUILD_DIR)/ipkg/$(2)
 
 ifeq ($$(KDEPEND_$(1)),m)
 I_$(1) := $(PKG_BUILD_DIR)/ipkg/$(2)
 
 ifeq ($$(KDEPEND_$(1)),m)
@@ -18,8 +24,10 @@ endif
 endif
 
 $$(PKG_$(1)): $(LINUX_DIR)/.modules_done
 endif
 
 $$(PKG_$(1)): $(LINUX_DIR)/.modules_done
+       rm -rf $$(I_$(1))
        mkdir -p $$(I_$(1))/lib/modules/$(LINUX_VERSION)
        mkdir -p $$(I_$(1))/lib/modules/$(LINUX_VERSION)
-       $(SCRIPT_DIR)/make-ipkg-dir.sh $$(I_$(1)) ../control/kmod-$(2).control $(LINUX_VERSION)-$(PKG_RELEASE) $(ARCH)
+       $(SCRIPT_DIR)/make-ipkg-dir.sh $$(I_$(1)) ../control/kmod-$(2).control $(LINUX_VERSION)-$(BOARD)-$(PKG_RELEASE) $(ARCH)
+       echo "Depends: $$(IDEPEND_$(1))" >> $$(I_$(1))/CONTROL/control
        cp $(3) $$(I_$(1))/lib/modules/$(LINUX_VERSION)
        $(IPKG_BUILD) $$(I_$(1)) $(PACKAGE_DIR)
 
        cp $(3) $$(I_$(1))/lib/modules/$(LINUX_VERSION)
        $(IPKG_BUILD) $$(I_$(1)) $(PACKAGE_DIR)
 
This page took 0.032256 seconds and 4 git commands to generate.