-define Package/kmod-madwifi/install
- mkdir -p $(1)/etc/modules.d
- mkdir -p $(1)/etc/init.d
- mkdir -p $(1)/lib/modules/$(LINUX_VERSION)
- mkdir -p $(1)/usr/sbin
- install -m0644 ./files/madwifi.modules $(1)/etc/modules.d/20-madwifi
-ifeq ($(findstring AHB,$(BUS)),AHB)
- echo ath_ahb >> $(1)/etc/modules.d/20-madwifi
-endif
-ifeq ($(findstring PCI,$(BUS)),PCI)
- echo ath_pci >> $(1)/etc/modules.d/20-madwifi
-endif
- install -m0755 ./files/madwifi.init $(1)/etc/init.d/S20madwifi
- $(CP) \
- $(PKG_BUILD_DIR)/ath_hal/ath_hal.$(LINUX_KMOD_SUFFIX) \
- $(BUS_MODULES) \
- $(PKG_BUILD_DIR)/ath_rate/sample/ath_rate_sample.$(LINUX_KMOD_SUFFIX) \
- $(PKG_BUILD_DIR)/net80211/*.$(LINUX_KMOD_SUFFIX) \
- $(1)/lib/modules/$(LINUX_VERSION)/
- $(CP) $(PKG_BUILD_DIR)/tools/{madwifi_multi,80211debug,80211stats,athchans,athctrl,athdebug,athkey,athstats,wlanconfig} $(1)/usr/sbin/
+define KernelPackage/madwifi/install
+ $(INSTALL_DIR) $(1)/lib/wifi
+ $(INSTALL_DATA) ./files/lib/wifi/madwifi.sh $(1)/lib/wifi
+ $(INSTALL_DIR) $(1)/usr/sbin
+ $(CP) $(PKG_BUILD_DIR)/tools/{madwifi_multi,$(MADWIFI_APPLETS)} $(1)/usr/sbin/