Navigation


Changeset 8:3e143f047f78 in freeDiameter for cmake


Ignore:
Timestamp:
Sep 18, 2009, 6:54:07 PM (15 years ago)
Author:
Sebastien Decugis <sdecugis@nict.go.jp>
Branch:
default
Phase:
public
Message:

Backup for the week-end

Location:
cmake/Modules
Files:
2 deleted
1 edited

Legend:

Unmodified
Added
Removed
  • cmake/Modules/FindSCTP.cmake

    r0 r8  
    66#  SCTP_LIBRARIES - link these to use SCTP
    77
    8 include(LibFindMacros)
    9 
    10 # Use pkg-config to get hints about paths (Note: not yet supported?)
    11 # libfind_pkg_check_modules(SCTP_PKGCONF sctp)
     8if (SCTP_INCLUDE_DIRS)
     9  set(SCTP_FIND_QUIETLY TRUE)
     10endif (SCTP_INCLUDE_DIRS)
    1211
    1312# Include dir
    1413find_path(SCTP_INCLUDE_DIR
    1514  NAMES netinet/sctp.h
    16   PATHS ${SCTP_PKGCONF_INCLUDE_DIRS}
    1715)
    1816
    19 # Finally the library itself
     17# Library
    2018find_library(SCTP_LIBRARY
    2119  NAMES sctp
    22   PATHS ${SCTP_PKGCONF_LIBRARY_DIRS}
    2320)
    2421
    2522# Set the include dir variables and the libraries and let libfind_process do the rest.
    2623# NOTE: Singular variables for this library, plural for libraries this this lib depends on.
    27 set(SCTP_PROCESS_INCLUDES SCTP_INCLUDE_DIR)
    28 set(SCTP_PROCESS_LIBS SCTP_LIBRARY)
    29 libfind_process(SCTP)
     24#set(SCTP_PROCESS_INCLUDES SCTP_INCLUDE_DIR)
     25#set(SCTP_PROCESS_LIBS SCTP_LIBRARY)
     26#libfind_process(SCTP)
     27
     28
     29# handle the QUIETLY and REQUIRED arguments and set SCTP_FOUND to TRUE if
     30# all listed variables are TRUE
     31INCLUDE(FindPackageHandleStandardArgs)
     32FIND_PACKAGE_HANDLE_STANDARD_ARGS(SCTP DEFAULT_MSG SCTP_LIBRARY SCTP_INCLUDE_DIR)
     33
     34# If we successfully found the sctp library then add the library to the
     35# SCTP_LIBRARIES cmake variable otherwise set SCTP_LIBRARIES to nothing.
     36IF(SCTP_FOUND)
     37   SET( SCTP_LIBRARIES ${SCTP_LIBRARY} )
     38ELSE(SCTP_FOUND)
     39   SET( SCTP_LIBRARIES )
     40ENDIF(SCTP_FOUND)
     41
     42
     43# Lastly make it so that the SCTP_LIBRARY and SCTP_INCLUDE_DIR variables
     44# only show up under the advanced options in the gui cmake applications.
     45MARK_AS_ADVANCED( SCTP_LIBRARY SCTP_INCLUDE_DIR )
     46
Note: See TracChangeset for help on using the changeset viewer.