SmartAudio/package/utils/rftest/Makefile

78 lines
1.8 KiB
Makefile
Executable File

include $(TOPDIR)/rules.mk
PKG_NAME:=rftest
PKG_VERSION:=1.0.0
PKG_RELEASE:=1
PKG_BUILD_DIR := $(COMPILE_DIR)/$(PKG_NAME)
include $(BUILD_DIR)/package.mk
define Package/$(PKG_NAME)/Default
SECTION:=utils
CATEGORY:=Utilities
SUBMENU:=rf test tool
endef
define Package/$(PKG_NAME)/description/Default
If you can't figure out what this program does, you're probably
brain-dead and need immediate medical attention.
endef
define Package/broadcom-rftest
$(Package/$(PKG_NAME)/Default)
TITLE:=broadcom rf test tools
DEPENDS:=+libcutils +liblog +libc +bluez-utils +brcm_patchram_plus
endef
define Package/xr819-rftest
$(Package/$(PKG_NAME)/Default)
TITLE:=xr819 rf test tools
endef
define Package/broadcom-rftest/description
$(call Package/$(PKG_NAME)/description/Default)
endef
define Package/xr819-rftest/description
$(call Package/$(PKG_NAME)/description/Default)
endef
define Build/Prepare
mkdir -p $(PKG_BUILD_DIR)
$(CP) -r ./ $(PKG_BUILD_DIR)/
endef
define Build/Configure
endef
define Build/Compile
endef
define Package/broadcom-rftest/install
$(INSTALL_DIR) $(1)/etc/rftest
ifeq ($(findstring arm,$(TARGET_CC)), arm)
$(INSTALL_BIN) ./broadcom/wl $(1)/etc/rftest/wl
else
ifeq ($(findstring aarch64, $(TARGET_CC)), aarch64)
$(INSTALL_BIN) ./broadcom/wl_64 $(1)/etc/rftest/wl
endif
endif
$(INSTALL_BIN) ./broadcom/*.bin $(1)/etc/rftest/
$(INSTALL_BIN) ./broadcom/wifi_test.sh $(1)/etc/rftest/
$(INSTALL_BIN) ./broadcom/bt_test.sh $(1)/etc/rftest/
endef
define Package/xr819-rftest/install
$(INSTALL_DIR) /$(1)/usr/bin
ifeq ($(TARGET_CPU_VARIANT), arm926ej-s)
$(INSTALL_BIN) ./xr819/$(TARGET_CPU_VARIANT)/$(CONFIG_LIBC)/etf /$(1)/usr/bin
else
$(INSTALL_BIN) ./xr819/$(CONFIG_ARCH)/$(CONFIG_LIBC)/etf /$(1)/usr/bin
endif
endef
$(eval $(call BuildPackage,broadcom-rftest))
$(eval $(call BuildPackage,xr819-rftest))