Changes
2 changed files (+64/-0)
-
openwrt/Makefile (new)
-
@@ -0,0 +1,39 @@include $(TOPDIR)/rules.mk PKG_NAME:=sunwait PKG_VERSION:=1.0 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/risacher/sunwait.git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) include $(INCLUDE_DIR)/package.mk define Package/sunwait SUBMENU:=Utilities SECTION:=util CATEGORY:=Utilities TITLE:=Sunwait URL:=URL:=https://github.com/risacher/sunwait DEPENDS:=+libstdcpp +libc endef define Package/sunwait/description Wait until the specified solar event endef define Build/Compile $(TARGET_CC) $(TARGET_CPPFLAGS) -o $(PKG_BUILD_DIR)/sunwait.o -c $(PKG_BUILD_DIR)/sunwait.cpp $(TARGET_CC) $(TARGET_CPPFLAGS) -o $(PKG_BUILD_DIR)/sunriset.o -c $(PKG_BUILD_DIR)/sunriset.cpp $(TARGET_CC) $(TARGET_CPPFLAGS) -o $(PKG_BUILD_DIR)/print.o -c $(PKG_BUILD_DIR)/print.cpp $(TARGET_CC) $(TARGET_LDFLAGS) -o $(PKG_BUILD_DIR)/$1 $(PKG_BUILD_DIR)/sunwait.o $(PKG_BUILD_DIR)/sunriset.o $(PKG_BUILD_DIR)/print.o -lm -lstdc++ endef define Package/sunwait/install $(INSTALL_DIR) $(1)/usr/bin $(INSTALL_BIN) $(PKG_BUILD_DIR)/sunwait $(1)/usr/bin/ endef $(eval $(call BuildPackage,sunwait))
-
-
openwrt/README (new)
-
@@ -0,0 +1,25 @@This Makefile can be used to build sunwait as a package for OpenWRT. Dependency: OpenWRT SDK Instructions: - Download the OpenWRT SDK for your platform from; https://downloads.openwrt.org/releases/xx.xx.x/targets/{platform}/generic/openwrt-sdk_*.tar.xz - Extract it to somewhere; tar -xf openwrt-sdk_*.Linux-x86_64.tar.xz - Enter the sdk root; cd openwrt-sdk_*.Linux-x86_64 - Set it up; ./scripts/feeds update -a - Copy the Makefile from this path into the sdk, at; {sdk root}/package/sunwait/Makefile - From the sdk root, build it; make package/sunwait/compile This will create the package that can be installed to your router.
-