Makefile 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. include $(TOPDIR)/rules.mk
  2. include $(INCLUDE_DIR)/kernel.mk
  3. PKG_NAME:=tmon
  4. PKG_VERSION:=$(LINUX_VERSION)
  5. PKG_RELEASE:=1
  6. PKG_MAINTAINER:=Florian Eckert <[email protected]>
  7. PKG_LICENSE:=GPL-2.0-only
  8. include $(INCLUDE_DIR)/package.mk
  9. define Package/tmon
  10. SECTION:=devel
  11. CATEGORY:=Development
  12. TITLE:=Thermal monitoring and testing tool
  13. VERSION:=$(LINUX_VERSION)-$(PKG_RELEASE)
  14. URL:=http://www.kernel.org
  15. DEPENDS:=+libncursesw
  16. endef
  17. define Package/tmon/description
  18. As hardware vendors cope with the thermal constraints on their products,
  19. more and more sensors are added, new cooling capabilities are introduced.
  20. To expose such relationship to the userspace, Linux generic thermal layer
  21. introduced sysfs entry at /sys/class/thermal with a matrix of symbolic
  22. links, trip point bindings, and device instances. To traverse such
  23. matrix by hand is not a trivial task.
  24. 'TMON' is conceived as a tool to help visualize, tune, and test the
  25. complex thermal subsystem.
  26. endef
  27. MAKE_FLAGS = \
  28. ARCH="$(LINUX_KARCH)" \
  29. CROSS_COMPILE="$(TARGET_CROSS)" \
  30. CC="$(TARGET_CC)" \
  31. CFLAGS="$(TARGET_CFLAGS) $(TARGET_CPPFLAGS)" \
  32. LDFLAGS="$(TARGET_LDFLAGS)"
  33. define Build/Compile
  34. -$(MAKE) clean \
  35. -C $(LINUX_DIR)/tools/thermal/tmon
  36. +$(MAKE_FLAGS) $(MAKE) \
  37. -C $(LINUX_DIR)/tools/thermal/tmon
  38. endef
  39. define Package/tmon/install
  40. $(INSTALL_DIR) $(1)/usr/bin
  41. $(INSTALL_BIN) $(LINUX_DIR)/tools/thermal/tmon/tmon \
  42. $(1)/usr/bin/
  43. endef
  44. $(eval $(call BuildPackage,tmon))