Brian Waters | 13d9601 | 2017-12-08 16:53:31 -0600 | [diff] [blame] | 1 | PROJECT("freeDiameter extensions" C) |
| 2 | |
| 3 | # We want all resulting objects in the same folder |
| 4 | SET(LIBRARY_OUTPUT_PATH ${CMAKE_CURRENT_BINARY_DIR}) |
| 5 | |
| 6 | # Use the macro FD_ADD_EXTENSION(name files...) to create an extension |
| 7 | # It is equivalent to add_library with the appropriate parameters |
| 8 | # and naming conventions (.fdx : FreeDiameter eXtension) |
| 9 | MACRO(FD_ADD_EXTENSION EXTNAME) |
| 10 | ADD_LIBRARY(${EXTNAME} MODULE ${ARGN}) |
| 11 | SET_TARGET_PROPERTIES(${EXTNAME} PROPERTIES PREFIX "" ) |
| 12 | SET_TARGET_PROPERTIES(${EXTNAME} PROPERTIES SUFFIX ".fdx" ) |
| 13 | ENDMACRO(FD_ADD_EXTENSION) |
| 14 | |
| 15 | # Use the macro FD_EXTENSION_SUBDIR(extmacroname subdir descr default) to |
| 16 | # add a new extension subdirectory. |
| 17 | MACRO(FD_EXTENSION_SUBDIR EXTSUBDIR EXTDESCR EXTDEFAULT) |
| 18 | STRING(TOUPPER ${EXTSUBDIR} EXTMACRONAME) |
| 19 | IF (NOT ALL_EXTENSIONS) |
| 20 | OPTION(BUILD_${EXTMACRONAME} "Build ${EXTSUBDIR}.fdx? (${EXTDESCR})" ${EXTDEFAULT}) |
| 21 | ENDIF (NOT ALL_EXTENSIONS) |
| 22 | IF (BUILD_${EXTMACRONAME} OR ALL_EXTENSIONS) |
| 23 | SUBDIRS(${EXTSUBDIR}) |
| 24 | ENDIF (BUILD_${EXTMACRONAME} OR ALL_EXTENSIONS) |
| 25 | ENDMACRO(FD_EXTENSION_SUBDIR) |
| 26 | |
| 27 | OPTION(ALL_EXTENSIONS "Build ALL available extensions? (disable to select individual components)" OFF) |
| 28 | |
| 29 | # The extensions include the headers of freeDiameter that contains gnutls objects |
| 30 | INCLUDE_DIRECTORIES(${LFDCORE_INCLUDES}) |
| 31 | |
| 32 | |
| 33 | ########################### |
| 34 | # Extensions section |
| 35 | |
| 36 | #### |
| 37 | # Diameter applications dictionaries |
| 38 | |
| 39 | FD_EXTENSION_SUBDIR(dict_nasreq "NASREQ (RFC4005) Dictionary definitions" ON) |
| 40 | FD_EXTENSION_SUBDIR(dict_eap "Diameter EAP (RFC4072) Dictionary definitions" ON) |
| 41 | |
| 42 | FD_EXTENSION_SUBDIR(dict_dcca "Diameter CC (RFC4006) Dictionary definitions [incomplete]" ON) |
| 43 | FD_EXTENSION_SUBDIR(dict_dcca_3gpp "Diameter CC 3GPP Dictionary definitions [incomplete]" ON) |
| 44 | FD_EXTENSION_SUBDIR(dict_dcca_starent "Diameter CC Starent Dictionary definitions" ON) |
| 45 | |
| 46 | FD_EXTENSION_SUBDIR(dict_sip "Diameter SIP (RFC4740) Dictionary definitions" ON) |
| 47 | |
| 48 | FD_EXTENSION_SUBDIR(dict_mip6a "Diameter Mobile IPv6 Auth Dictionary definitions" ON) |
| 49 | FD_EXTENSION_SUBDIR(dict_mip6i "Diameter Mobile IPv6 IKE Dictionary definitions" ON) |
| 50 | FD_EXTENSION_SUBDIR(dict_nas_mipv6 "Diameter NAS-to-HAAA Interaction Dictionary definitions" ON) |
| 51 | |
| 52 | FD_EXTENSION_SUBDIR(dict_legacy_xml "Load Diameter dictionary definitions from XML files." OFF) |
| 53 | |
| 54 | |
| 55 | #### |
| 56 | # Diameter applications |
| 57 | |
| 58 | FD_EXTENSION_SUBDIR(app_acct "Simple accounting application that stores accounting records in flat database" OFF) |
| 59 | FD_EXTENSION_SUBDIR(app_diameap "Diameter EAP Application server (RFC 4072)" OFF) |
| 60 | FD_EXTENSION_SUBDIR(app_radgw "RADIUS/Diameter gateway translation - RADIUS client to Diameter server" OFF) |
| 61 | FD_EXTENSION_SUBDIR(app_sip "Diameter SIP Authentication and Authorization server (RFC 4740)" OFF) |
| 62 | |
| 63 | FD_EXTENSION_SUBDIR(app_redirect "Diameter Redirect server: send configurable Redirect indications to other peers" OFF) |
| 64 | |
| 65 | |
| 66 | #### |
| 67 | # Routing extensions |
| 68 | |
| 69 | FD_EXTENSION_SUBDIR(rt_busypeers "Handling of Diameter TOO_BUSY messages and relay timeouts" ON) |
| 70 | FD_EXTENSION_SUBDIR(rt_default "Configurable routing rules for freeDiameter" ON) |
| 71 | FD_EXTENSION_SUBDIR(rt_ereg "Configurable routing based on regexp matching of AVP values" OFF) |
| 72 | FD_EXTENSION_SUBDIR(rt_ignore_dh "Stow Destination-Host in Proxy-Info, restore to Origin-Host for answers" ON) |
| 73 | FD_EXTENSION_SUBDIR(rt_load_balance "Balance load over multiple equal hosts, based on outstanding requests" ON) |
| 74 | FD_EXTENSION_SUBDIR(rt_randomize "Randomly choose one of the highest scored hosts and increase its score by one" ON) |
| 75 | FD_EXTENSION_SUBDIR(rt_redirect "Handling of Diameter Redirect messages" ON) |
| 76 | |
| 77 | |
| 78 | #### |
| 79 | # Peers security extensions |
| 80 | |
| 81 | FD_EXTENSION_SUBDIR(acl_wl "White-list based authorization of incoming connections" ON) |
| 82 | |
| 83 | |
| 84 | #### |
| 85 | # Debug & test extensions |
| 86 | |
| 87 | FD_EXTENSION_SUBDIR(dbg_monitor "Outputs periodical status information" ON) |
| 88 | FD_EXTENSION_SUBDIR(dbg_msg_timings "Show some timing information for messages" ON) |
| 89 | FD_EXTENSION_SUBDIR(dbg_msg_dumps "Show human-readable content of the received & sent messages" ON) |
| 90 | FD_EXTENSION_SUBDIR(dbg_rt "Routing extension for debugging the routing module" ON) |
| 91 | FD_EXTENSION_SUBDIR(test_app "Testing application to send dummy message to another peer, like a Diameter 'ping'" OFF) |
| 92 | FD_EXTENSION_SUBDIR(test_sip "Testing application to simulate Diameter-SIP client (RFC4740)" OFF) |
| 93 | FD_EXTENSION_SUBDIR(dbg_interactive "Python-interpreter based module" OFF) |
| 94 | FD_EXTENSION_SUBDIR(test_netemul "Simple Diameter network emulator proxy extension (latency, PDV, duplicates)" OFF) |
| 95 | |
| 96 | |
| 97 | |
| 98 | # The following extension have very little use except for specific tests, so we disable them except in Debug configurations. |
| 99 | IF (CMAKE_BUILD_TYPE MATCHES "Debug") |
| 100 | FD_EXTENSION_SUBDIR(_sample "Simple extension to demonstrate extension mechanism, for developpers" OFF) |
| 101 | FD_EXTENSION_SUBDIR(test_acct "Receive Accounting-Requests and display the data, but no storage" OFF) |
| 102 | FD_EXTENSION_SUBDIR(test_rt_any "Routing extension randomly sending message to any peer available, for testing purpose" OFF) |
| 103 | ENDIF (CMAKE_BUILD_TYPE MATCHES "Debug") |
| 104 | |
| 105 | |
| 106 | FD_EXTENSION_SUBDIR(dict_3gpp2_avps "dict_3gpp2_avps extension library" ON) |
| 107 | FD_EXTENSION_SUBDIR(dict_CreditControl "dict_CreditControl extension library" ON) |
| 108 | FD_EXTENSION_SUBDIR(dict_CxDx "dict_CxDx extension library" ON) |
| 109 | FD_EXTENSION_SUBDIR(dict_Gx "dict_Gx extension library" ON) |
| 110 | FD_EXTENSION_SUBDIR(dict_NAS "dict_NAS extension library" ON) |
| 111 | FD_EXTENSION_SUBDIR(dict_Rf "dict_Rf extension library" ON) |
| 112 | FD_EXTENSION_SUBDIR(dict_Ro "dict_Ro extension library" ON) |
| 113 | FD_EXTENSION_SUBDIR(dict_Rx "dict_Rx extension library" ON) |
| 114 | FD_EXTENSION_SUBDIR(dict_S6as6d "dict_S6as6d extension library" ON) |
| 115 | FD_EXTENSION_SUBDIR(dict_S6mS6n "dict_S6mS6n extension library" ON) |
| 116 | FD_EXTENSION_SUBDIR(dict_S6t "dict_S6t extension library" ON) |
| 117 | FD_EXTENSION_SUBDIR(dict_SGd "dict_SGd extension library" ON) |
| 118 | FD_EXTENSION_SUBDIR(dict_SLh "dict_SLh extension library" ON) |
| 119 | FD_EXTENSION_SUBDIR(dict_Sd "dict_Sd extension library" ON) |
| 120 | FD_EXTENSION_SUBDIR(dict_Sh "dict_Sh extension library" ON) |
Javier Bravo Conde | eb10c6f | 2018-06-28 08:43:34 -0500 | [diff] [blame] | 121 | FD_EXTENSION_SUBDIR(dict_St "dict_St extension library" ON) |
Brian Waters | 13d9601 | 2017-12-08 16:53:31 -0600 | [diff] [blame] | 122 | FD_EXTENSION_SUBDIR(dict_T4 "dict_T4 extension library" ON) |
| 123 | FD_EXTENSION_SUBDIR(dict_T6aT6bT7 "dict_T6aT6bT7 extension library" ON) |
| 124 | FD_EXTENSION_SUBDIR(dict_Tsp "dict_Tsp extension library" ON) |
| 125 | #FD_EXTENSION_SUBDIR(dict_base_rfc6733 "dict_base_rfc6733 extension library" ON) |
| 126 | FD_EXTENSION_SUBDIR(dict_draftload_avps "dict_draftload_avps extension library" ON) |
| 127 | FD_EXTENSION_SUBDIR(dict_etsi283034_avps "dict_etsi283034_avps extension library" ON) |
| 128 | FD_EXTENSION_SUBDIR(dict_rfc4004_avps "dict_rfc4004_avps extension library" ON) |
| 129 | FD_EXTENSION_SUBDIR(dict_rfc4006bis_avps "dict_rfc4006bis_avps extension library" ON) |
| 130 | FD_EXTENSION_SUBDIR(dict_rfc4072_avps "dict_rfc4072_avps extension library" ON) |
| 131 | FD_EXTENSION_SUBDIR(dict_rfc4590_avps "dict_rfc4590_avps extension library" ON) |
| 132 | FD_EXTENSION_SUBDIR(dict_rfc5447_avps "dict_rfc5447_avps extension library" ON) |
| 133 | FD_EXTENSION_SUBDIR(dict_rfc5580_avps "dict_rfc5580_avps extension library" ON) |
| 134 | FD_EXTENSION_SUBDIR(dict_rfc5777_avps "dict_rfc5777_avps extension library" ON) |
| 135 | FD_EXTENSION_SUBDIR(dict_rfc5778_avps "dict_rfc5778_avps extension library" ON) |
| 136 | FD_EXTENSION_SUBDIR(dict_rfc6734_avps "dict_rfc6734_avps extension library" ON) |
| 137 | FD_EXTENSION_SUBDIR(dict_rfc6942_avps "dict_rfc6942_avps extension library" ON) |
| 138 | FD_EXTENSION_SUBDIR(dict_rfc7155_avps "dict_rfc7155_avps extension library" ON) |
| 139 | FD_EXTENSION_SUBDIR(dict_rfc7683_avps "dict_rfc7683_avps extension library" ON) |
| 140 | FD_EXTENSION_SUBDIR(dict_rfc7944_avps "dict_rfc7944_avps extension library" ON) |
| 141 | FD_EXTENSION_SUBDIR(dict_ts29061_avps "dict_ts29061_avps extension library" ON) |
| 142 | FD_EXTENSION_SUBDIR(dict_ts29128_avps "dict_ts29128_avps extension library" ON) |
| 143 | FD_EXTENSION_SUBDIR(dict_ts29154_avps "dict_ts29154_avps extension library" ON) |
| 144 | FD_EXTENSION_SUBDIR(dict_ts29173_avps "dict_ts29173_avps extension library" ON) |
| 145 | FD_EXTENSION_SUBDIR(dict_ts29212_avps "dict_ts29212_avps extension library" ON) |
| 146 | FD_EXTENSION_SUBDIR(dict_ts29214_avps "dict_ts29214_avps extension library" ON) |
| 147 | FD_EXTENSION_SUBDIR(dict_ts29215_avps "dict_ts29215_avps extension library" ON) |
| 148 | FD_EXTENSION_SUBDIR(dict_ts29217_avps "dict_ts29217_avps extension library" ON) |
| 149 | FD_EXTENSION_SUBDIR(dict_ts29229_avps "dict_ts29229_avps extension library" ON) |
| 150 | FD_EXTENSION_SUBDIR(dict_ts29272_avps "dict_ts29272_avps extension library" ON) |
| 151 | FD_EXTENSION_SUBDIR(dict_ts29273_avps "dict_ts29273_avps extension library" ON) |
| 152 | FD_EXTENSION_SUBDIR(dict_ts29329_avps "dict_ts29329_avps extension library" ON) |
| 153 | FD_EXTENSION_SUBDIR(dict_ts29336_avps "dict_ts29336_avps extension library" ON) |
| 154 | FD_EXTENSION_SUBDIR(dict_ts29337_avps "dict_ts29337_avps extension library" ON) |
| 155 | FD_EXTENSION_SUBDIR(dict_ts29338_avps "dict_ts29338_avps extension library" ON) |
| 156 | FD_EXTENSION_SUBDIR(dict_ts29343_avps "dict_ts29343_avps extension library" ON) |
| 157 | FD_EXTENSION_SUBDIR(dict_ts29344_avps "dict_ts29344_avps extension library" ON) |
| 158 | FD_EXTENSION_SUBDIR(dict_ts29345_avps "dict_ts29345_avps extension library" ON) |
| 159 | FD_EXTENSION_SUBDIR(dict_ts29368_avps "dict_ts29368_avps extension library" ON) |
| 160 | FD_EXTENSION_SUBDIR(dict_ts29468_avps "dict_ts29468_avps extension library" ON) |
| 161 | FD_EXTENSION_SUBDIR(dict_ts32299_avps "dict_ts32299_avps extension library" ON) |
| 162 | FD_EXTENSION_SUBDIR(dict_S6c "dict_S6c extension library" ON) |
| 163 | FD_EXTENSION_SUBDIR(dict_S9 "dict_S9 extension library" ON) |