You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

65 lines
1.7 KiB

  1. include $(TOPDIR)/rules.mk
  2. PKG_NAME:=libcgroup
  3. PKG_VERSION:=0.41
  4. PKG_RELEASE:=2
  5. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
  6. PKG_SOURCE_URL:=@SF/libcg
  7. PKG_HASH:=e4e38bdc7ef70645ce33740ddcca051248d56b53283c0dc6d404e17706f6fb51
  8. PKG_MAINTAINER:=Daniel Danzberger <daniel@dd-wrt.com>
  9. PKG_LICENSE:=LGPL-2.1-or-later
  10. PKG_LICENSE_FILES:=COPYING
  11. PKG_INSTALL:=1
  12. PKG_BUILD_PARALLEL:=1
  13. include $(INCLUDE_DIR)/package.mk
  14. define Package/libcgroup
  15. TITLE:=CGroup config and exec library
  16. SECTION:=libs
  17. CATEGORY:=Libraries
  18. DEPENDS:=+USE_MUSL:musl-fts +@KERNEL_CGROUPS
  19. endef
  20. define Package/cgroup-tools
  21. TITLE:=CGroup config and exec tools
  22. DEPENDS:=+libcgroup
  23. CATEGORY:=Utilities
  24. endef
  25. define Package/libcgroup/description
  26. Helpers utils for working with cgroups.
  27. endef
  28. CONFIGURE_ARGS += \
  29. --enable-tools \
  30. --enable-shared \
  31. --disable-daemon \
  32. --disable-pam
  33. TARGET_LDFLAGS += $(if $(CONFIG_USE_MUSL),-lfts)
  34. define Build/InstallDev
  35. $(INSTALL_DIR) $(1)/usr/include $(1)/usr/lib $(1)/usr/lib/pkgconfig
  36. $(CP) $(PKG_INSTALL_DIR)/usr/include/libcgroup.h $(1)/usr/include
  37. $(CP) $(PKG_INSTALL_DIR)/usr/include/libcgroup $(1)/usr/include
  38. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libcgroup.so* $(1)/usr/lib
  39. $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libcgroup.pc $(1)/usr/lib/pkgconfig/
  40. endef
  41. define Package/libcgroup/install
  42. $(INSTALL_DIR) $(1)/usr/lib
  43. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libcgroup.so* $(1)/usr/lib
  44. endef
  45. define Package/cgroup-tools/install
  46. $(INSTALL_DIR) $(1)/usr/bin $(1)/usr/sbin
  47. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin
  48. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/* $(1)/usr/sbin
  49. endef
  50. $(eval $(call BuildPackage,libcgroup))
  51. $(eval $(call BuildPackage,cgroup-tools))