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.

77 lines
3.1 KiB

  1. --- a/lib/crypto/wscript_configure
  2. +++ b/lib/crypto/wscript_configure
  3. @@ -2,11 +2,11 @@
  4. import Options
  5. import Utils
  6. -if not conf.CHECK_FUNCS_IN('MD5Init', 'bsd', headers='bsd/md5.h',
  7. - checklibc=True):
  8. - conf.CHECK_FUNCS_IN('MD5Init', 'md5', headers='sys/md5.h',
  9. - checklibc=True)
  10. - conf.CHECK_FUNCS_IN('MD5Init', 'md', headers='sys/md5.h',
  11. +# if not conf.CHECK_FUNCS_IN('MD5Init', 'bsd', headers='bsd/md5.h',
  12. + # checklibc=True):
  13. +conf.CHECK_FUNCS_IN('MD5Init', 'md5', headers='sys/md5.h',
  14. + checklibc=True)
  15. +conf.CHECK_FUNCS_IN('MD5Init', 'md', headers='sys/md5.h',
  16. checklibc=True)
  17. conf.CHECK_FUNCS_IN('CC_MD5_Init', '', headers='CommonCrypto/CommonDigest.h',
  18. checklibc=True)
  19. --- a/lib/replace/wscript
  20. +++ b/lib/replace/wscript
  21. @@ -340,22 +340,13 @@ def configure(conf):
  22. conf.CHECK_FUNCS('prctl dirname basename')
  23. - strlcpy_in_bsd = False
  24. + # Not checking for libbsd
  25. + conf.CHECK_FUNCS('strlcpy strlcat')
  26. + conf.CHECK_FUNCS('getpeereid')
  27. + conf.CHECK_FUNCS_IN('setproctitle', 'setproctitle', headers='setproctitle.h')
  28. + conf.CHECK_FUNCS('setproctitle_init')
  29. - # libbsd on some platforms provides strlcpy and strlcat
  30. - if not conf.CHECK_FUNCS('strlcpy strlcat'):
  31. - if conf.CHECK_FUNCS_IN('strlcpy strlcat', 'bsd', headers='bsd/string.h',
  32. - checklibc=True):
  33. - strlcpy_in_bsd = True
  34. - if not conf.CHECK_FUNCS('getpeereid'):
  35. - conf.CHECK_FUNCS_IN('getpeereid', 'bsd', headers='sys/types.h bsd/unistd.h')
  36. - if not conf.CHECK_FUNCS_IN('setproctitle', 'setproctitle', headers='setproctitle.h'):
  37. - conf.CHECK_FUNCS_IN('setproctitle', 'bsd', headers='sys/types.h bsd/unistd.h')
  38. - if not conf.CHECK_FUNCS('setproctitle_init'):
  39. - conf.CHECK_FUNCS_IN('setproctitle_init', 'bsd', headers='sys/types.h bsd/unistd.h')
  40. -
  41. - if not conf.CHECK_FUNCS('closefrom'):
  42. - conf.CHECK_FUNCS_IN('closefrom', 'bsd', headers='bsd/unistd.h')
  43. + conf.CHECK_FUNCS('closefrom')
  44. conf.CHECK_CODE('''
  45. struct ucred cred;
  46. @@ -698,9 +689,6 @@ def configure(conf):
  47. # look for a method of finding the list of network interfaces
  48. for method in ['HAVE_IFACE_GETIFADDRS', 'HAVE_IFACE_AIX', 'HAVE_IFACE_IFCONF', 'HAVE_IFACE_IFREQ']:
  49. - bsd_for_strlcpy = ''
  50. - if strlcpy_in_bsd:
  51. - bsd_for_strlcpy = ' bsd'
  52. if conf.CHECK_CODE('''
  53. #define %s 1
  54. #define NO_CONFIG_H 1
  55. @@ -713,7 +701,7 @@ def configure(conf):
  56. #include "test/getifaddrs.c"
  57. ''' % method,
  58. method,
  59. - lib='nsl socket' + bsd_for_strlcpy,
  60. + lib='nsl socket',
  61. addmain=False,
  62. execute=True):
  63. break
  64. @@ -761,7 +749,6 @@ def build(bld):
  65. break
  66. extra_libs = ''
  67. - if bld.CONFIG_SET('HAVE_LIBBSD'): extra_libs += ' bsd'
  68. bld.SAMBA_SUBSYSTEM('LIBREPLACE_HOSTCC',
  69. REPLACE_HOSTCC_SOURCE,