Loading Makefile +8 −5 Original line number Diff line number Diff line Loading @@ -9,8 +9,8 @@ include $(TOPDIR)/rules.mk PKG_NAME:=its_bridge PKG_REFV:=2 PKG_VERSION:=0.1.2 PKG_RELEASE:=3 PKG_VERSION:=1.0.0 PKG_RELEASE:=1 include $(INCLUDE_DIR)/package.mk Loading @@ -18,7 +18,7 @@ define Package/its_bridge SECTION:=utils CATEGORY:=Utilities TITLE:=ITS bridge clients and server DEPENDS:=+libpcap +libmicrohttpd +libuci DEPENDS:=+libpcap endef define Build/Prepare Loading @@ -30,7 +30,7 @@ define Build/Configure endef #TARGET_CFLAGS += -ggdb3 MAKE_FLAGS += CFLAGS="$(TARGET_CFLAGS) -Wall -I include -DUSE_UCI" LDFLAGS="-luci" MAKE_FLAGS += CFLAGS="$(TARGET_CFLAGS) -Wall -I include" define Package/its_bridge/install $(INSTALL_DIR) $(1)/usr/bin/ Loading @@ -41,12 +41,15 @@ endef define Package/its_bridge/preinst #!/bin/sh uci add ucitrack its_bridge uci set ucitrack.@its_bridge[0].init='its_bridge' uci commit ucitrack exit 0 endef define Package/its_bridge/prerm #!/bin/sh uci del ucitrack.@its_bridge[0] uci delete ucitrack.@its_bridge[0] uc commit ucitrack exit 0 endef $(eval $(call BuildPackage,its_bridge)) Loading resources/openwrt/etc/init.d/its_bridge +2 −2 Original line number Diff line number Diff line Loading @@ -13,8 +13,8 @@ open_its_port() { [ -z "$port" ] && port=5000 for p in 0 1 2 3 4 5 6 7 8 9; do v=`uci get glfw.@opening[$p].port 2>/dev/null` if [ "$v" == "$port" ]; then echo "Port $port already opened" if [ -z "$v" -o "$v" == "$port" ]; then # echo "Port $port already opened" break fi done Loading resources/openwrt/usr/lib/lua/luci/model/cbi/its_bridge/its_bridge.lua +21 −2 Original line number Diff line number Diff line Loading @@ -15,12 +15,21 @@ s = m:section(TypedSection, "its", translate("ITS Configuration")) s.addremove = false s.anonymous = true o=s:option(Value, "nic", translate("ITS network interface")) o=s:option(Value, "nic", translate("ITS network interface"), translate("The network interface where the ITS device is connected")) o.template = "cbi/network_ifacelist" o.widget = "radio" o.nobridges = true o.noaliases = true o.rmempty = true o.noinactive = true o.nocreate = true --o.network = arg[1] o=s:option(Value, "mac", translate("ITS device MAC address"),translate("MAC address of connected ITS device")) o.rmempty = true --o.datatype = "macaddr" s = m:section(TypedSection, "udp", translate("UDP Configuration")) s.addremove = false Loading @@ -29,10 +38,19 @@ s.anonymous = true o=s:option(Value, "nic", translate("UDP Interface"), translate("UDP interface (optional)")) o.optional = true o.template = "cbi/network_ifacelist" o.widget = "radio" --o.nobridges = true o.noaliases = true o.noinactive = true o.rmempty = true o.nocreate = true --o.network = arg[1] o=s:option(Value, "send", translate("Destnation Address"), translate("IP address or multicast group to send ITS packets")) o.datatype = "ipaddr" o.datatype = "ip4addr" o=s:option(Value, "port", translate("Destnation Port"), translate("Port to send ITS packets")) Loading @@ -42,6 +60,7 @@ o.datatype = "port" o=s:option(DynamicList, "recv", translate("Remote Addresses"), translate("IP addresses or multicast groups to recive ITS packets")) o.addremove = true o.datatype = "ip4addr" --m.submit = translate("Apply") Loading src/Makefile +1 −1 Original line number Diff line number Diff line Loading @@ -7,4 +7,4 @@ csrc := utils.c all: $(bins) $(bins) : % : %.c $(csrc) $(CC) -o $@ $^ $(CFLAGS) $(LDFLAGS) -lpcap -lmicrohttpd $(CC) -o $@ $^ $(CFLAGS) $(LDFLAGS) -lpcap Loading
Makefile +8 −5 Original line number Diff line number Diff line Loading @@ -9,8 +9,8 @@ include $(TOPDIR)/rules.mk PKG_NAME:=its_bridge PKG_REFV:=2 PKG_VERSION:=0.1.2 PKG_RELEASE:=3 PKG_VERSION:=1.0.0 PKG_RELEASE:=1 include $(INCLUDE_DIR)/package.mk Loading @@ -18,7 +18,7 @@ define Package/its_bridge SECTION:=utils CATEGORY:=Utilities TITLE:=ITS bridge clients and server DEPENDS:=+libpcap +libmicrohttpd +libuci DEPENDS:=+libpcap endef define Build/Prepare Loading @@ -30,7 +30,7 @@ define Build/Configure endef #TARGET_CFLAGS += -ggdb3 MAKE_FLAGS += CFLAGS="$(TARGET_CFLAGS) -Wall -I include -DUSE_UCI" LDFLAGS="-luci" MAKE_FLAGS += CFLAGS="$(TARGET_CFLAGS) -Wall -I include" define Package/its_bridge/install $(INSTALL_DIR) $(1)/usr/bin/ Loading @@ -41,12 +41,15 @@ endef define Package/its_bridge/preinst #!/bin/sh uci add ucitrack its_bridge uci set ucitrack.@its_bridge[0].init='its_bridge' uci commit ucitrack exit 0 endef define Package/its_bridge/prerm #!/bin/sh uci del ucitrack.@its_bridge[0] uci delete ucitrack.@its_bridge[0] uc commit ucitrack exit 0 endef $(eval $(call BuildPackage,its_bridge)) Loading
resources/openwrt/etc/init.d/its_bridge +2 −2 Original line number Diff line number Diff line Loading @@ -13,8 +13,8 @@ open_its_port() { [ -z "$port" ] && port=5000 for p in 0 1 2 3 4 5 6 7 8 9; do v=`uci get glfw.@opening[$p].port 2>/dev/null` if [ "$v" == "$port" ]; then echo "Port $port already opened" if [ -z "$v" -o "$v" == "$port" ]; then # echo "Port $port already opened" break fi done Loading
resources/openwrt/usr/lib/lua/luci/model/cbi/its_bridge/its_bridge.lua +21 −2 Original line number Diff line number Diff line Loading @@ -15,12 +15,21 @@ s = m:section(TypedSection, "its", translate("ITS Configuration")) s.addremove = false s.anonymous = true o=s:option(Value, "nic", translate("ITS network interface")) o=s:option(Value, "nic", translate("ITS network interface"), translate("The network interface where the ITS device is connected")) o.template = "cbi/network_ifacelist" o.widget = "radio" o.nobridges = true o.noaliases = true o.rmempty = true o.noinactive = true o.nocreate = true --o.network = arg[1] o=s:option(Value, "mac", translate("ITS device MAC address"),translate("MAC address of connected ITS device")) o.rmempty = true --o.datatype = "macaddr" s = m:section(TypedSection, "udp", translate("UDP Configuration")) s.addremove = false Loading @@ -29,10 +38,19 @@ s.anonymous = true o=s:option(Value, "nic", translate("UDP Interface"), translate("UDP interface (optional)")) o.optional = true o.template = "cbi/network_ifacelist" o.widget = "radio" --o.nobridges = true o.noaliases = true o.noinactive = true o.rmempty = true o.nocreate = true --o.network = arg[1] o=s:option(Value, "send", translate("Destnation Address"), translate("IP address or multicast group to send ITS packets")) o.datatype = "ipaddr" o.datatype = "ip4addr" o=s:option(Value, "port", translate("Destnation Port"), translate("Port to send ITS packets")) Loading @@ -42,6 +60,7 @@ o.datatype = "port" o=s:option(DynamicList, "recv", translate("Remote Addresses"), translate("IP addresses or multicast groups to recive ITS packets")) o.addremove = true o.datatype = "ip4addr" --m.submit = translate("Apply") Loading
src/Makefile +1 −1 Original line number Diff line number Diff line Loading @@ -7,4 +7,4 @@ csrc := utils.c all: $(bins) $(bins) : % : %.c $(csrc) $(CC) -o $@ $^ $(CFLAGS) $(LDFLAGS) -lpcap -lmicrohttpd $(CC) -o $@ $^ $(CFLAGS) $(LDFLAGS) -lpcap