mirror of
https://github.com/samba-team/samba.git
synced 2025-02-01 05:47:28 +03:00
build: deal with recent glibc sunrpc header removal
We need to rely on libtirpc or libntirpc to be around in that case. BUG: https://bugzilla.samba.org/show_bug.cgi?id=13238 BUG: https://bugzilla.samba.org/show_bug.cgi?id=10976 Guenther Pair-Programmed-With: Andreas Schneider <asn@samba.org> Signed-off-by: Guenther Deschner <gd@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Alexander Bokovoy <ab@samba.org>
This commit is contained in:
parent
c29d087e1e
commit
ee0be7eb72
@ -559,7 +559,7 @@ def build(bld):
|
||||
bld.SAMBA_BINARY('smnotify',
|
||||
source=bld.SUBDIR('utils/smnotify',
|
||||
'smnotify.c gen_smnotify.c gen_xdr.c'),
|
||||
deps='ctdb-smnotify-h ctdb-smnotify-c ctdb-smnotify-x popt',
|
||||
deps='ctdb-smnotify-h ctdb-smnotify-c ctdb-smnotify-x popt tirpc',
|
||||
includes='utils utils/smnotify',
|
||||
install_path='${CTDB_HELPER_BINDIR}')
|
||||
|
||||
|
@ -5,7 +5,7 @@ VERSION = '1.2.1'
|
||||
|
||||
blddir = 'bin'
|
||||
|
||||
import sys, os
|
||||
import Logs, sys, os
|
||||
|
||||
# find the buildtools directory
|
||||
srcdir = '.'
|
||||
@ -65,14 +65,42 @@ def configure(conf):
|
||||
headers='sys/inotify.h')
|
||||
|
||||
conf.CHECK_HEADERS('security/pam_appl.h zlib.h asm/unistd.h')
|
||||
conf.CHECK_HEADERS('aio.h sys/unistd.h rpc/rpc.h rpc/nettype.h alloca.h float.h')
|
||||
conf.CHECK_HEADERS('aio.h sys/unistd.h alloca.h float.h')
|
||||
|
||||
conf.CHECK_HEADERS('rpcsvc/nis.h rpcsvc/ypclnt.h sys/sysctl.h')
|
||||
conf.SET_TARGET_TYPE('tirpc', 'EMPTY')
|
||||
conf.CHECK_HEADERS('rpc/rpc.h rpc/nettype.h')
|
||||
if not conf.CONFIG_SET('HAVE_RPC_RPC_H'):
|
||||
if conf.CHECK_CFG(package='libtirpc', args='--cflags',
|
||||
msg='Checking for libtirpc headers',
|
||||
uselib_store='TIRPC'):
|
||||
conf.CHECK_HEADERS('rpc/rpc.h rpc/nettype.h', lib='tirpc', together=True)
|
||||
conf.SET_TARGET_TYPE('tirpc', 'SYSLIB')
|
||||
if not conf.CONFIG_SET('HAVE_RPC_RPC_H'):
|
||||
if conf.CHECK_CFG(package='libntirpc', args='--cflags',
|
||||
msg='Checking for libntirpc headers',
|
||||
uselib_store='TIRPC'):
|
||||
conf.CHECK_HEADERS('rpc/rpc.h rpc/nettype.h', lib='tirpc', together=True)
|
||||
conf.SET_TARGET_TYPE('tirpc', 'SYSLIB')
|
||||
if not conf.CONFIG_SET('HAVE_RPC_RPC_H'):
|
||||
Logs.error('ERROR: No rpc/rpc.h header found, tirpc or libntirpc missing?')
|
||||
sys.exit(1)
|
||||
|
||||
conf.SET_TARGET_TYPE('nsl', 'EMPTY')
|
||||
conf.CHECK_HEADERS('rpc/rpc.h rpcsvc/yp_prot.h', lib='tirpc')
|
||||
if not conf.CONFIG_SET('HAVE_RPCSVC_YP_PROT_H'):
|
||||
if conf.CHECK_CFG(package='libnsl', args='--cflags --libs',
|
||||
msg='Checking for libnsl',
|
||||
uselib_store='NSL'):
|
||||
conf.SET_TARGET_TYPE('nsl', 'SYSLIB')
|
||||
conf.CHECK_HEADERS('rpc/rpc.h rpcsvc/yp_prot.h', lib='tirpc nsl')
|
||||
else:
|
||||
conf.SET_TARGET_TYPE('nsl', 'SYSLIB')
|
||||
conf.CHECK_HEADERS('rpcsvc/nis.h rpcsvc/ypclnt.h', lib='tirpc nsl')
|
||||
|
||||
conf.CHECK_HEADERS('sys/sysctl.h')
|
||||
conf.CHECK_HEADERS('sys/fileio.h sys/filesys.h sys/dustat.h sys/sysmacros.h')
|
||||
conf.CHECK_HEADERS('xfs/libxfs.h netgroup.h')
|
||||
|
||||
conf.CHECK_CODE('', headers='rpc/rpc.h rpcsvc/yp_prot.h', define='HAVE_RPCSVC_YP_PROT_H')
|
||||
|
||||
conf.CHECK_HEADERS('valgrind.h valgrind/valgrind.h valgrind/memcheck.h')
|
||||
conf.CHECK_HEADERS('nss_common.h nsswitch.h ns_api.h')
|
||||
conf.CHECK_HEADERS('sys/extattr.h sys/ea.h sys/proplist.h sys/cdefs.h')
|
||||
|
@ -204,7 +204,7 @@ else:
|
||||
|
||||
bld.SAMBA_SUBSYSTEM('access',
|
||||
source='access.c',
|
||||
deps='interfaces samba-util',
|
||||
deps='interfaces samba-util tirpc nsl',
|
||||
local_include=False)
|
||||
|
||||
bld.SAMBA_SUBSYSTEM('util_str_escape',
|
||||
|
@ -6,7 +6,7 @@ bld.SAMBA3_SUBSYSTEM('TOKEN_UTIL',
|
||||
|
||||
bld.SAMBA3_SUBSYSTEM('USER_UTIL',
|
||||
source='user_util.c',
|
||||
deps='TOKEN_UTIL')
|
||||
deps='TOKEN_UTIL tirpc nsl')
|
||||
|
||||
bld.SAMBA3_SUBSYSTEM('AUTH_COMMON',
|
||||
source='''auth_util.c
|
||||
|
@ -119,7 +119,6 @@ def configure(conf):
|
||||
conf.CHECK_FUNCS('memalign posix_memalign hstrerror')
|
||||
conf.CHECK_FUNCS('shmget')
|
||||
conf.CHECK_FUNCS_IN('shm_open', 'rt', checklibc=True)
|
||||
#FIXME: for some reason this one still fails
|
||||
conf.CHECK_FUNCS_IN('yp_get_default_domain', 'nsl')
|
||||
conf.CHECK_FUNCS_IN('dn_expand _dn_expand __dn_expand', 'resolv')
|
||||
conf.CHECK_FUNCS_IN('dn_expand', 'inet')
|
||||
@ -1446,7 +1445,7 @@ main() {
|
||||
#darwin style quota bytecount
|
||||
conf.CHECK_STRUCTURE_MEMBER('struct dqblk', 'dqb_curbytes', define='HAVE_STRUCT_DQBLK_DQB_CURBYTES',
|
||||
headers='sys/quota.h')
|
||||
if conf.CHECK_HEADERS('rpcsvc/rquota.h'):
|
||||
if conf.CHECK_HEADERS('rpcsvc/rquota.h', lib='tirpc'):
|
||||
conf.DEFINE('HAVE_NFS_QUOTAS', '1')
|
||||
conf.CHECK_STRUCTURE_MEMBER('struct getquota_rslt', 'getquota_rslt_u',
|
||||
define='HAVE_GETQUOTA_RSLT_GETQUOTA_RSLT_U',
|
||||
@ -1484,7 +1483,8 @@ main() {
|
||||
define='HAVE_NFS_QUOTAS',
|
||||
msg='for NFS QUOTAS',
|
||||
execute=True,
|
||||
local_include=False)
|
||||
local_include=False,
|
||||
lib='tirpc')
|
||||
|
||||
if conf.CONFIG_SET('HAVE_QUOTACTL_LINUX') or \
|
||||
conf.CONFIG_SET('HAVE_QUOTACTL_4A') or \
|
||||
@ -1650,7 +1650,7 @@ main() {
|
||||
Logs.info("building with Spotlight support")
|
||||
default_static_modules.extend(TO_LIST('rpc_mdssvc_module'))
|
||||
|
||||
conf.CHECK_HEADERS('rpc/xdr.h')
|
||||
conf.CHECK_HEADERS('rpc/xdr.h', lib='tirpc')
|
||||
|
||||
forced_static_modules.extend(TO_LIST('auth_builtin auth_sam auth_winbind'))
|
||||
default_static_modules.extend(TO_LIST('''pdb_smbpasswd pdb_tdbsam
|
||||
|
Loading…
x
Reference in New Issue
Block a user