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.

80 lines
2.1 KiB

  1. include $(TOPDIR)/rules.mk
  2. PKG_NAME:=containerd
  3. PKG_VERSION:=1.2.10
  4. PKG_RELEASE:=4
  5. PKG_LICENSE:=Apache-2.0
  6. PKG_LICENSE_FILES:=LICENSE
  7. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  8. PKG_SOURCE_URL:=https://codeload.github.com/containerd/containerd/tar.gz/v${PKG_VERSION}?
  9. PKG_HASH:=a0965e1492fca558629826f1aa89a9675de3d451cec67540400b30c0bf6ac387
  10. PKG_SOURCE_VERSION:=b34a5c8af56e510852c35414db4c1f4fa6172339
  11. PKG_MAINTAINER:=Gerard Ryan <G.M0N3Y.2503@gmail.com>
  12. PKG_BUILD_DEPENDS:=golang/host
  13. PKG_BUILD_PARALLEL:=1
  14. PKG_INSTALL:=1
  15. GO_PKG:=github.com/containerd/containerd
  16. include $(INCLUDE_DIR)/package.mk
  17. include ../../lang/golang/golang-package.mk
  18. define Package/containerd/config
  19. config CONTAINERD_SECCOMP
  20. depends on PACKAGE_containerd
  21. bool "Enable support for seccomp in containerd"
  22. default DOCKER_SECCOMP
  23. select KERNEL_SECCOMP
  24. select PACKAGE_libseccomp
  25. help
  26. Build containerd with support for seccomp filters.
  27. Select libseccomp which also pulls-in the needed kernel features.
  28. endef
  29. define Package/containerd
  30. SECTION:=utils
  31. CATEGORY:=Utilities
  32. TITLE:=containerd container runtime
  33. URL:=https://containerd.io/
  34. DEPENDS:=$(GO_ARCH_DEPENDS) @(aarch64||arm||x86_64) +btrfs-progs +runc +CONTAINERD_SECCOMP:libseccomp
  35. MENU:=1
  36. endef
  37. define Package/containerd/description
  38. An industry-standard container runtime with an emphasis on simplicity, robustness and portability
  39. endef
  40. GO_PKG_INSTALL_ALL:=1
  41. MAKE_PATH:=$(GO_PKG_WORK_DIR_NAME)/build/src/$(GO_PKG)
  42. MAKE_VARS += $(call GoPackage/Environment)
  43. MAKE_FLAGS += \
  44. DESTDIR="$(PKG_INSTALL_DIR)" \
  45. VERSION=$(PKG_VERSION) \
  46. REVISION=$(PKG_SOURCE_VERSION)
  47. ifeq ($(CONFIG_CONTAINERD_SECCOMP),y)
  48. MAKE_FLAGS += BUILDTAGS='seccomp'
  49. else
  50. MAKE_FLAGS += BUILDTAGS=''
  51. endif
  52. define Build/Compile
  53. $(call Build/Compile/Default)
  54. endef
  55. # Avoid installing binaries
  56. define Build/InstallDev
  57. $(call Build/Compile/Default,clean)
  58. rm -f $(STAMP_BUILT)
  59. $(call GoPackage/Build/InstallDev,$(1))
  60. endef
  61. define Package/containerd/install
  62. $(INSTALL_DIR) $(1)/usr/bin/
  63. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/bin/{ctr,containerd,containerd-stress,containerd-shim} $(1)/usr/bin/
  64. endef
  65. $(eval $(call BuildPackage,containerd))