build variants: only build opkg packages for the requested build variant (or any...
authorFelix Fietkau <nbd@openwrt.org>
Sun, 22 Nov 2009 07:08:39 +0000 (07:08 +0000)
committerFelix Fietkau <nbd@openwrt.org>
Sun, 22 Nov 2009 07:08:39 +0000 (07:08 +0000)
SVN-Revision: 18464

include/package-ipkg.mk
package/hostapd/Makefile

index bd4e28ce35559438c17a7c9f9e48405406f7a6cb..1ddd80a8dc11031bae9516b9b19c37ff4ab4c1e7 100644 (file)
@@ -36,6 +36,7 @@ ifeq ($(DUMP),)
     IDIR_$(1):=$(PKG_BUILD_DIR)/ipkg-$(PKGARCH)/$(1)
     INFO_$(1):=$(IPKG_STATE_DIR)/info/$(1).list
 
+    ifeq ($(if $(VARIANT),$(BUILD_VARIANT)),$(VARIANT))
     ifdef Package/$(1)/install
       ifneq ($(CONFIG_PACKAGE_$(1))$(SDK)$(DEVELOPER),)
         compile: $$(IPKG_$(1)) $(STAGING_DIR_ROOT)/stamp/.$(1)_installed
@@ -49,6 +50,7 @@ ifeq ($(DUMP),)
                @echo "WARNING: skipping $(1) -- package not selected"
       endif
     endif
+    endif
 
     IDEPEND_$(1):=$$(call filter_deps,$$(DEPENDS))
   
index 5e10ea27b960e32c8495ce663fafbb44dc5c9836..bb497fec3b09136e541b25bb33c4d4e8498cacc6 100644 (file)
@@ -108,7 +108,7 @@ define Build/Compile
                hostapd hostapd_cli
 endef
 
-define Package/InstallTemplate
+define Package/hostapd/install
        $(INSTALL_DIR) $(1)/etc/hotplug.d/net
        $(INSTALL_DATA) ./files/hostapd.hotplug $(1)/etc/hotplug.d/net/
        $(INSTALL_DIR) $(1)/lib/wifi
@@ -116,12 +116,7 @@ define Package/InstallTemplate
        $(INSTALL_DIR) $(1)/usr/sbin
        $(INSTALL_BIN) $(PKG_BUILD_DIR)/hostapd/hostapd $(1)/usr/sbin/
 endef
-
-ifeq ($(BUILD_VARIANT),full)
-  Package/hostapd/install = $(Package/InstallTemplate)
-else
-  Package/hostapd-mini/install = $(Package/InstallTemplate)
-endif
+Package/hostapd-mini/install = $(Package/hostapd/install)
 
 define Package/hostapd-utils/install
        $(INSTALL_DIR) $(1)/usr/sbin