Skip to content

Commit

Permalink
merge ap-info and mtk-wifi
Browse files Browse the repository at this point in the history
  • Loading branch information
mango committed Feb 10, 2017
1 parent 6537247 commit 35ba2ed
Show file tree
Hide file tree
Showing 6 changed files with 52 additions and 93 deletions.
87 changes: 0 additions & 87 deletions package/ap-iwinfo/Makefile

This file was deleted.

54 changes: 50 additions & 4 deletions package/mtk-wifi/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,23 +10,69 @@ PKG_NAME:=mtk-wifi
PKG_VERSION:=V1.1
PKG_RELEASE=$(PKG_SOURCE_VERSION)

PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=http://git.openwrt.org/project/iwinfo.git
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
PKG_SOURCE_VERSION:=ade8b1b299cbd5748db1acf80dd3e9f567938371
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_LICENSE:=GPL-2.0

PKG_CONFIG_DEPENDS := \
CONFIG_PACKAGE_kmod-brcm-wl \
CONFIG_PACKAGE_kmod-brcm-wl-mini \
CONFIG_PACKAGE_kmod-brcm-wl-mimo \
CONFIG_PACKAGE_kmod-madwifi \
CONFIG_PACKAGE_kmod-cfg80211

include $(INCLUDE_DIR)/package.mk

define Package/mtk-wifi
CATEGORY:=Ralink SDK Mango
TITLE:=Ralink mt7628 wifi AP and Apcli driver
DEPENDS:=@TARGET_ramips_mt7688 +wireless-tools +maccalc
TITLE:=Ralink mt7628 wifi AP and Apcli driver ap_client command and iwinfo patch
DEPENDS:=@TARGET_ramips_mt7688 +wireless-tools +maccalc +libuci
ABI_VERSION:=$(PKG_RELEASE)
endef

define Build/Configure
true
endef

IWINFO_BACKENDS := \
$(if $(CONFIG_TARGET_ramips),rt) \

EXTRA_CFLAGS := \
-I$(STAGING_DIR)/usr/include/libnl-tiny \
-I$(STAGING_DIR)/usr/include \
-D_GNU_SOURCE

MAKE_FLAGS += \
FPIC="$(FPIC)" \
CFLAGS="$(TARGET_CFLAGS)" \
LDFLAGS="$(TARGET_LDFLAGS)" \
BACKENDS="$(IWINFO_BACKENDS)"

define Build/Compile
true
$(call Build/Compile/Default,)
$(TARGET_CC) $(TARGET_CFLAGS) -Wall -Werror -o $(PKG_BUILD_DIR)/ap_client src/ap_client.c
endef

define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/include/iwinfo
$(CP) $(PKG_BUILD_DIR)/include/iwinfo.h $(1)/usr/include/
$(CP) $(PKG_BUILD_DIR)/include/iwinfo/* $(1)/usr/include/iwinfo/
$(INSTALL_DIR) $(1)/usr/lib
$(INSTALL_BIN) $(PKG_BUILD_DIR)/libiwinfo.so $(1)/usr/lib/libiwinfo.so
$(INSTALL_DIR) $(1)/usr/lib/lua
$(INSTALL_BIN) $(PKG_BUILD_DIR)/iwinfo.so $(1)/usr/lib/lua/iwinfo.so
endef


define Package/mtk-wifi/install
$(INSTALL_DIR) $(1)/usr/bin $(1)/lib/modules/$(LINUX_VERSION)/
$(INSTALL_DIR) $(1)/lib
$(INSTALL_BIN) $(PKG_BUILD_DIR)/iwinfo $(1)/usr/bin/iwinfo.rt
$(INSTALL_BIN) $(PKG_BUILD_DIR)/libiwinfo.so $(1)/lib/libiwinfo.so
$(INSTALL_DIR) $(1)/sbin/
$(CP) $(PKG_BUILD_DIR)/ap_client $(1)/sbin/
$(INSTALL_DIR) $(1)/lib/modules/$(LINUX_VERSION)/
$(CP) ./wifi_ko/mt_wifi_$(LINUX_VERSION)_mango.ko $(1)/lib/modules/$(LINUX_VERSION)/mt_wifi.ko
$(CP) ./files/* $(1)/
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion target/linux/ramips/mt7688/profiles/02-widora.mk
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ define Profile/Widora
kmod-sdhci-mt7620 kmod-usb-storage \
kmod-video-core kmod-video-uvc \
kmod-sound-core kmod-sound-mtk madplay-alsa alsa-utils \
ap-iwinfo mtk-wifi airkiss webui\
mtk-wifi airkiss webui\
maccalc shairport_mmap reg
endef

Expand Down
2 changes: 1 addition & 1 deletion target/linux/ramips/mt7688/profiles/03-widora32M.mk
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ define Profile/Widora32M
kmod-sdhci-mt7620 kmod-usb-storage \
kmod-video-core kmod-video-uvc \
kmod-sound-core kmod-sound-mtk madplay-alsa alsa-utils \
ap-iwinfo mtk-wifi airkiss webui\
mtk-wifi airkiss webui\
maccalc shairport_mmap reg
endef

Expand Down

0 comments on commit 35ba2ed

Please sign in to comment.