006-linux-3.7-compat.patch 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. --- a/configure.ac
  2. +++ b/configure.ac
  3. @@ -74,9 +74,10 @@ case "$host_os" in
  4. [ KERNEL_INCLUDE="/lib/modules/`uname -r`/build/include" ])
  5. AC_CHECK_HEADER($KERNEL_INCLUDE/linux/pfkeyv2.h, ,
  6. - [ AC_CHECK_HEADER(/usr/src/linux/include/linux/pfkeyv2.h,
  7. - KERNEL_INCLUDE=/usr/src/linux/include ,
  8. - [ AC_MSG_ERROR([Unable to find linux-2.6 kernel headers. Aborting.]) ] ) ] )
  9. + [ AC_CHECK_HEADER($KERNEL_INCLUDE/uapi/linux/pfkeyv2.h, ,
  10. + [ AC_CHECK_HEADER(/usr/src/linux/include/linux/pfkeyv2.h,
  11. + KERNEL_INCLUDE=/usr/src/linux/include ,
  12. + [ AC_MSG_ERROR([Unable to find linux-2.6 kernel headers. Aborting.]) ] ) ] ) ] )
  13. AC_SUBST(KERNEL_INCLUDE)
  14. # We need the configure script to run with correct kernel headers.
  15. # However we don't want to point to kernel source tree in compile time,
  16. @@ -643,7 +644,14 @@ AC_EGREP_CPP(yes,
  17. #ifdef SADB_X_EXT_NAT_T_TYPE
  18. yes
  19. #endif
  20. -], [kernel_natt="yes"])
  21. +], [kernel_natt="yes"], [
  22. + AC_EGREP_CPP(yes,
  23. + [#include <uapi/linux/pfkeyv2.h>
  24. + #ifdef SADB_X_EXT_NAT_T_TYPE
  25. + yes
  26. + #endif
  27. + ], [kernel_natt="yes"])
  28. +])
  29. ;;
  30. freebsd*|netbsd*)
  31. # NetBSD case
  32. --- a/src/include-glibc/Makefile.am
  33. +++ b/src/include-glibc/Makefile.am
  34. @@ -1,14 +1,7 @@
  35. -
  36. -.includes: ${top_builddir}/config.status
  37. - ln -snf $(KERNEL_INCLUDE)/linux
  38. - touch .includes
  39. -
  40. -all: .includes
  41. -
  42. EXTRA_DIST = \
  43. glibc-bugs.h \
  44. net/pfkeyv2.h \
  45. netinet/ipsec.h \
  46. sys/queue.h
  47. -DISTCLEANFILES = .includes linux
  48. +DISTCLEANFILES = linux