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.

139 lines
3.9 KiB

  1. #
  2. # Copyright (C) 2009-2015 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=krb5
  9. PKG_VERSION:=1.13.1
  10. PKG_RELEASE:=1
  11. PKG_MAINTAINER:=W. Michael Petullo <mike@flyn.org>
  12. PKG_LICENSE:=MIT
  13. PKG_LICENSE_FILES:=NOTICE
  14. PKG_SOURCE:=krb5-$(PKG_VERSION)-signed.tar
  15. PKG_SOURCE_URL:=http://web.mit.edu/kerberos/dist/krb5/1.13/
  16. PKG_MD5SUM:=567586cdf02aa8c842c2fab7a94f3c1f
  17. PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
  18. PKG_BUILD_PARALLEL:=1
  19. PKG_INSTALL:=1
  20. PKG_CHECK_FORMAT_SECURITY:=0
  21. include $(INCLUDE_DIR)/package.mk
  22. MAKE_PATH:=src
  23. define Package/krb5/Default
  24. SECTION:=net
  25. CATEGORY:=Network
  26. TITLE:=Kerberos
  27. URL:=http://web.mit.edu/kerberos/
  28. endef
  29. define Package/krb5-libs
  30. SECTION:=net
  31. CATEGORY:=Network
  32. TITLE:=Kerberos
  33. DEPENDS:=+libncurses
  34. TITLE:=Kerberos 5 Shared Libraries
  35. URL:=http://web.mit.edu/kerberos/
  36. endef
  37. define Package/krb5-server
  38. $(call Package/krb5/Default)
  39. DEPENDS:=+krb5-libs +libpthread
  40. TITLE:=Kerberos 5 Server
  41. endef
  42. define Package/krb5-client
  43. $(call Package/krb5/Default)
  44. DEPENDS:=+krb5-libs
  45. TITLE:=Kerberos 5 Client
  46. endef
  47. define Package/krb5/description
  48. Kerberos
  49. endef
  50. define Build/Prepare
  51. # Krb5 tarball contains signature and a second tarball
  52. # containing source code.
  53. tar xf "$(DL_DIR)/$(PKG_SOURCE)" -C "$(BUILD_DIR)"
  54. tar xzf "$(BUILD_DIR)/krb5-$(PKG_VERSION).tar.gz" -C "$(BUILD_DIR)"
  55. patch -p1 -d "$(PKG_BUILD_DIR)" < "$(PATCH_DIR)/001-fix-build.patch"
  56. endef
  57. CONFIGURE_PATH = ./src
  58. CONFIGURE_VARS += \
  59. cross_compiling=yes \
  60. krb5_cv_attr_constructor_destructor=yes,yes \
  61. ac_cv_func_regcomp=yes \
  62. ac_cv_printf_positional=yes \
  63. ac_cv_file__etc_environment=no \
  64. ac_cv_file__etc_TIMEZONE=no
  65. CONFIGURE_ARGS += \
  66. --without-tcl \
  67. --without-libedit \
  68. --localstatedir=/etc
  69. define Build/InstallDev
  70. $(INSTALL_DIR) $(1)/usr/include
  71. $(CP) $(PKG_INSTALL_DIR)/usr/include \
  72. $(1)/usr/include/krb5
  73. $(INSTALL_DIR) $(1)/usr
  74. $(CP) $(PKG_INSTALL_DIR)/usr/lib \
  75. $(1)/usr
  76. rm -f $(1)/usr/lib/libcom_err*
  77. endef
  78. define Package/krb5-libs/install
  79. $(INSTALL_DIR) $(1)/usr/lib
  80. $(INSTALL_DIR) $(1)/usr/lib/krb5
  81. $(INSTALL_DIR) $(1)/usr/lib/krb5/plugins
  82. $(INSTALL_DIR) $(1)/usr/lib/krb5/plugins/kdb
  83. $(INSTALL_DIR) $(1)/usr/lib/krb5/plugins/libkrb5
  84. $(CP) $(PKG_INSTALL_DIR)/usr/lib/krb5/plugins/kdb/db2.so $(1)/usr/lib/krb5/plugins/kdb
  85. $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib
  86. endef
  87. define Package/krb5-client/install
  88. $(INSTALL_DIR) $(1)/usr/bin
  89. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/kdestroy $(1)/usr/bin
  90. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/kinit $(1)/usr/bin
  91. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/klist $(1)/usr/bin
  92. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/kpasswd $(1)/usr/bin
  93. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/ksu $(1)/usr/bin
  94. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/kvno $(1)/usr/bin
  95. $(INSTALL_DIR) $(1)/usr/sbin
  96. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/krb5-send-pr $(1)/usr/sbin
  97. endef
  98. # Removed some server-side software to reduce package size. This should be
  99. # put in a separate package if needed.
  100. define Package/krb5-server/install
  101. $(INSTALL_DIR) $(1)/etc/init.d
  102. $(INSTALL_BIN) ./files/krb5kdc $(1)/etc/init.d/krb5kdc
  103. # $(INSTALL_DIR) $(1)/usr/bin
  104. # $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/sclient $(1)/usr/bin
  105. $(INSTALL_DIR) $(1)/usr/sbin
  106. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/kadmin.local $(1)/usr/sbin
  107. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/kadmind $(1)/usr/sbin
  108. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/kdb5_util $(1)/usr/sbin
  109. # $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/kprop $(1)/usr/sbin
  110. # $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/kpropd $(1)/usr/sbin
  111. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/krb5kdc $(1)/usr/sbin
  112. # $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/sim_server $(1)/usr/sbin
  113. endef
  114. $(eval $(call BuildPackage,krb5-libs))
  115. $(eval $(call BuildPackage,krb5-server))
  116. $(eval $(call BuildPackage,krb5-client))