aboutsummaryrefslogtreecommitdiff
path: root/net/rpcbind/Makefile
blob: 434f7a974d401acb9275fb66b65c2f3ae3fa0a6a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
include $(TOPDIR)/rules.mk

PKG_NAME:=rpcbind
PKG_VERSION:=1.2.5
PKG_RELEASE:=1

PKG_SOURCE_URL:=@SF/rpcbind
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_HASH:=2ce360683963b35c19c43f0ee2c7f18aa5b81ef41c3fdbd15ffcb00b8bffda7a

PKG_MAINTAINER:=Andy Walsh <andy.walsh44+github@gmail.com>
PKG_LICENSE:=BSD-3-Clause

PKG_FIXUP:=autoreconf
PKG_REMOVE_FILES:=autogen.sh aclocal.m4
PKG_INSTALL:=1

PKG_CONFIG_DEPENDS:= \
	CONFIG_RPCBIND_LIBWRAP \
	CONFIG_RPCBIND_WARMSTARTS

include $(INCLUDE_DIR)/package.mk

define Package/rpcbind
  SECTION:=net
  CATEGORY:=Network
  DEPENDS:=+libtirpc +RPCBIND_LIBWRAP:libwrap
  TITLE:=Universal addresses to RPC mapper
  URL:=http://rpcbind.sourceforge.net/
  USERID:=rpc=65533:rpc=65533
endef

define Package/rpcbind/description
  The rpcbind utility is a server that converts RPC program numbers into universal addresses.
  It must be running on the host to be able to make RPC calls on a server on that machine.

  Rpcbind replaces portmap for NFS v2/v3. It has more features, like ipv6 support.
  Note: Nfs4 only configurations can run without it.
endef

define Package/rpcbind/config
if PACKAGE_rpcbind
	config RPCBIND_LIBWRAP
		bool "Enable libwrap (TCP wrappers) support."
		default y

	config RPCBIND_WARMSTARTS
		bool "Enable warmstarts support"
		default y
		help
		  The warmstart feature saves RPC registrations on termination.
endif
endef

CONFIGURE_ARGS += \
	--with-rpcuser=rpc \
	--without-systemdsystemunitdir

ifeq ($(CONFIG_RPCBIND_LIBWRAP),y)
	CONFIGURE_ARGS += --enable-libwrap
else
	CONFIGURE_ARGS += --disable-libwrap
endif
ifeq ($(CONFIG_RPCBIND_WARMSTARTS),y)
	CONFIGURE_ARGS += --enable-warmstarts
endif

define Package/rpcbind/install
	$(INSTALL_DIR) $(1)/usr/bin
	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/rpcinfo $(1)/usr/bin/
	$(INSTALL_DIR) $(1)/usr/sbin
	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/rpcbind $(1)/usr/sbin/
	$(INSTALL_DIR) $(1)/etc/init.d
	$(INSTALL_BIN) ./files/rpcbind.init $(1)/etc/init.d/rpcbind
endef

$(eval $(call BuildPackage,rpcbind))