标签:
西电老校区,openwrt上用的认证软件。
在package下新建一目录"xd-h3c",在里面新建一个Makefile,内容如下:
1 include $(TOPDIR)/rules.mk 2 3 PKG_NAME:=xd-h3c 4 PKG_VERSION:=2014-09-28 5 6 PKG_SOURCE_PROTO:=git 7 PKG_SOURCE_URL:=git://github.com/godspeed1989/xd-h3c 8 PKG_MAINTAINER:=godspeed1989 <godspeed1989@gmail.com> 9 10 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME) 11 PKG_SOURCE_SUBDIR:=$(PKG_NAME) 12 PKG_SOURCE:=$(PKG_NAME).tar.gz 13 PKG_SOURCE_VERSION:=HEAD 14 15 include $(INCLUDE_DIR)/package.mk 16 17 define Package/xd-h3c 18 SECTION:=base 19 CATEGORY:=Network 20 DEPENDS:=+libpcap 21 TITLE:=An XiDian network authentication client 22 #DESCRIPTION:=This variable is obsolete. use the Package/name/description define instead! 23 URL:=https://github.com/godspeed1989/xd-h3c 24 endef 25 26 define Package/xd-h3c/description 27 An network authentication client, 28 Most usually used in China collages. 29 endef 30 31 define Build/Prepare 32 $(call Build/Prepare/Default) 33 $(SED) ‘s/RunDHCP(Device/\/\/RunDHCP(Device/g‘ $(PKG_BUILD_DIR)/authenticate.c 34 endef 35 36 define Package/xd-h3c/install 37 $(INSTALL_DIR) $(1)/usr/sbin 38 $(INSTALL_BIN) $(PKG_BUILD_DIR)/xdh3c $(1)/usr/sbin/ 39 endef 40 41 $(eval $(call BuildPackage,xd-h3c))
这里注意,每行前面的不是空格,是Tab。
然后make menuconfig,在network下面选择xd-h3c即可
路由刷好后putty登陆进去,在/etc/rc.local里面加入自启动:(xdh3c -u 帐号 -p 密码 -n 网卡)&
现在的openwrt版本( 我的trunk r45688)在老校区IPV6有问题
修改见我上一篇文章http://www.cnblogs.com/02xiaoma/p/4505169.html
标签:
原文地址:http://www.cnblogs.com/02xiaoma/p/4515248.html