# HG changeset patch # User Sebastien Decugis # Date 1281926671 -32400 # Node ID 6e53be78d65826c5905ed213d9727416001ed7b3 # Parent 6e9c1ea44262ba27dce66d7512036cee7b1cd813# Parent d68f27e7e814bf61574498069aa8887174ca69fd Merged with downstream diff -r 6e9c1ea44262 -r 6e53be78d658 cmake/Modules/FindGnuTLS.cmake --- a/cmake/Modules/FindGnuTLS.cmake Mon Aug 16 11:43:55 2010 +0900 +++ b/cmake/Modules/FindGnuTLS.cmake Mon Aug 16 11:44:31 2010 +0900 @@ -2,12 +2,12 @@ # Find the native GNUTLS includes and library # # GNUTLS_FOUND - True if gnutls found. -# GNUTLS_INCLUDE_DIRS - where to find gnutls.h, etc. +# GNUTLS_INCLUDE_DIR - where to find gnutls.h, etc. # GNUTLS_LIBRARIES - List of libraries when using gnutls. -if (GNUTLS_INCLUDE_DIRS AND GNUTLS_LIBRARIES) +if (GNUTLS_INCLUDE_DIR AND GNUTLS_LIBRARIES) set(GNUTLS_FIND_QUIETLY TRUE) -endif (GNUTLS_INCLUDE_DIRS AND GNUTLS_LIBRARIES) +endif (GNUTLS_INCLUDE_DIR AND GNUTLS_LIBRARIES) # Include dir find_path(GNUTLS_INCLUDE_DIR diff -r 6e9c1ea44262 -r 6e53be78d658 cmake/Modules/FindSCTP.cmake --- a/cmake/Modules/FindSCTP.cmake Mon Aug 16 11:43:55 2010 +0900 +++ b/cmake/Modules/FindSCTP.cmake Mon Aug 16 11:44:31 2010 +0900 @@ -2,12 +2,12 @@ # Once done, this will define # # SCTP_FOUND - system has SCTP -# SCTP_INCLUDE_DIRS - the SCTP include directories +# SCTP_INCLUDE_DIR - the SCTP include directories # SCTP_LIBRARIES - link these to use SCTP -if (SCTP_INCLUDE_DIRS AND SCTP_LIBRARIES) +if (SCTP_INCLUDE_DIR AND SCTP_LIBRARIES) set(SCTP_FIND_QUIETLY TRUE) -endif (SCTP_INCLUDE_DIRS AND SCTP_LIBRARIES) +endif (SCTP_INCLUDE_DIR AND SCTP_LIBRARIES) # Include dir find_path(SCTP_INCLUDE_DIR diff -r 6e9c1ea44262 -r 6e53be78d658 contrib/OpenWRT/HOWTO --- a/contrib/OpenWRT/HOWTO Mon Aug 16 11:43:55 2010 +0900 +++ b/contrib/OpenWRT/HOWTO Mon Aug 16 11:44:31 2010 +0900 @@ -89,7 +89,9 @@ We will now describe how to install these dependencies. At the time this HOWTO is written, the OpenWRT repositories contain ipv6, gnutls, pthreads and hostapd. Follow these instruction to -build them: +build them. + +Alternatively, you can find these packages pre-compiled in the OpenWRT packages repository. a) GNU TLS packages $ scripts/feeds install libgnutls diff -r 6e9c1ea44262 -r 6e53be78d658 contrib/OpenWRT/packages/sctp/Makefile --- a/contrib/OpenWRT/packages/sctp/Makefile Mon Aug 16 11:43:55 2010 +0900 +++ b/contrib/OpenWRT/packages/sctp/Makefile Mon Aug 16 11:44:31 2010 +0900 @@ -22,20 +22,10 @@ PKG_INSTALL:=1 include $(INCLUDE_DIR)/package.mk -include $(INCLUDE_DIR)/kernel.mk -define KernelPackage/sctp - SUBMENU:=Network Support - TITLE:=SCTP support - KCONFIG:= CONFIG_IP_SCTP=m - FILES:=$(LINUX_DIR)/net/sctp/sctp.$(LINUX_KMOD_SUFFIX) - AUTOLOAD:=$(call AutoLoad,20,sctp) - DEPENDS:=@LINUX_2_6 -endef - -define KernelPackage/sctp/description - Kernel modules for SCTP support -endef +##### +## lksctp library: provides sctp_* functions in user space +##### define Package/sctp SECTION:=libs @@ -59,4 +49,32 @@ endef $(eval $(call BuildPackage,sctp)) + + +##### +## SCTP kernel support +##### + +include $(INCLUDE_DIR)/kernel.mk + +define KernelPackage/sctp + SUBMENU:=Network Support + TITLE:=SCTP support + KCONFIG:=\ + CONFIG_IP_SCTP=m \ + CONFIG_LIBCRC32C=m + FILES:=\ + $(LINUX_DIR)/net/sctp/sctp.$(LINUX_KMOD_SUFFIX) \ + $(LINUX_DIR)/lib/libcrc32c.$(LINUX_KMOD_SUFFIX) + AUTOLOAD:=\ + $(call AutoLoad,30,crc32c libcrc32c,1) \ + $(call AutoLoad,35,sctp) + DEPENDS:=@LINUX_2_6 +kmod-crypto-core +kmod-crypto-misc +endef + +define KernelPackage/sctp/description + Kernel modules for SCTP support +endef + $(eval $(call KernelPackage,sctp)) + diff -r 6e9c1ea44262 -r 6e53be78d658 extensions/CMakeLists.txt --- a/extensions/CMakeLists.txt Mon Aug 16 11:43:55 2010 +0900 +++ b/extensions/CMakeLists.txt Mon Aug 16 11:44:31 2010 +0900 @@ -14,7 +14,7 @@ # The extensions include the headers of freeDiameter that contains gnutls objects FIND_PACKAGE(GnuTLS REQUIRED) -INCLUDE_DIRECTORIES(${GNUTLS_INCLUDE_DIRS}) +INCLUDE_DIRECTORIES(${GNUTLS_INCLUDE_DIR}) find_path(GCRYPT_INCLUDE_DIR NAMES gcrypt.h) If ( NOT GCRYPT_INCLUDE_DIR ) MESSAGE(SEND_ERROR "Unable to find gcrypt.h, please install libgcrypt-dev or equivalent") diff -r 6e9c1ea44262 -r 6e53be78d658 freeDiameter/CMakeLists.txt --- a/freeDiameter/CMakeLists.txt Mon Aug 16 11:43:55 2010 +0900 +++ b/freeDiameter/CMakeLists.txt Mon Aug 16 11:44:31 2010 +0900 @@ -50,7 +50,7 @@ # Require GNU TLS for building the daemon FIND_PACKAGE(GnuTLS REQUIRED) -INCLUDE_DIRECTORIES(${GNUTLS_INCLUDE_DIRS}) +INCLUDE_DIRECTORIES(${GNUTLS_INCLUDE_DIR}) SET(FD_LIBS ${FD_LIBS} ${GNUTLS_LIBRARIES}) find_path(GCRYPT_INCLUDE_DIR NAMES gcrypt.h) If ( NOT GCRYPT_INCLUDE_DIR ) diff -r 6e9c1ea44262 -r 6e53be78d658 include/freeDiameter/CMakeLists.txt --- a/include/freeDiameter/CMakeLists.txt Mon Aug 16 11:43:55 2010 +0900 +++ b/include/freeDiameter/CMakeLists.txt Mon Aug 16 11:44:31 2010 +0900 @@ -79,7 +79,7 @@ CHECK_FUNCTION_EXISTS(sctp_connectx HAVE_NATIVE_SCTP) IF(NOT HAVE_NATIVE_SCTP) FIND_PACKAGE(SCTP REQUIRED) - INCLUDE_DIRECTORIES(${SCTP_INCLUDE_DIRS}) + INCLUDE_DIRECTORIES(${SCTP_INCLUDE_DIR}) ENDIF(NOT HAVE_NATIVE_SCTP) # Now check the number of args of this function, since it changed between Ubuntu 9.04 and 9.10 SET(CHECK_SCTP_CONNECTX_4_ARGS_SOURCE_CODE " @@ -89,6 +89,7 @@ return sctp_connectx(0, NULL, 0, NULL); } ") + SET(CMAKE_REQUIRED_INCLUDES ${SCTP_INCLUDE_DIR}) SET(CMAKE_REQUIRED_LIBRARIES ${SCTP_LIBRARIES}) CHECK_C_SOURCE_COMPILES("${CHECK_SCTP_CONNECTX_4_ARGS_SOURCE_CODE}" SCTP_CONNECTX_4_ARGS) ELSE (NOT DISABLE_SCTP)