summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCorey Farrell <git@cfware.com>2017-11-19 17:30:49 -0500
committerCorey Farrell <git@cfware.com>2018-01-15 13:25:51 -0500
commit9cfdb81e913a8dd363ca4570b4eb4137de3b5837 (patch)
tree9f45c6c8a4dc0e78ecb43d5226424f9efe64a346
parent35ae99c712d2b0de2f780269fbabf8ceaf8c11ec (diff)
loader: Add dependency fields to module structures.
* Declare 'requires' and 'enhances' text fields on module info structure. * Rename 'nonoptreq' to 'optional_modules'. * Update doxygen comments. Still need to investigate dependencies among modules I cannot compile. Change-Id: I3ad9547a0a6442409ff4e352a6d897bef2cc04bf
-rw-r--r--apps/app_adsiprog.c2
-rw-r--r--apps/app_getcpeid.c2
-rw-r--r--apps/app_queue.c2
-rw-r--r--apps/app_speech_utils.c2
-rw-r--r--apps/app_stack.c2
-rw-r--r--apps/app_stasis.c2
-rw-r--r--apps/app_voicemail.c2
-rw-r--r--channels/chan_dahdi.c2
-rw-r--r--channels/chan_iax2.c2
-rw-r--r--channels/chan_mgcp.c2
-rw-r--r--channels/chan_motif.c1
-rw-r--r--channels/chan_pjsip.c1
-rw-r--r--channels/chan_rtp.c1
-rw-r--r--channels/chan_sip.c2
-rw-r--r--funcs/func_aes.c2
-rw-r--r--funcs/func_pjsip_aor.c7
-rw-r--r--funcs/func_pjsip_contact.c7
-rw-r--r--funcs/func_pjsip_endpoint.c7
-rw-r--r--include/asterisk/module.h60
-rw-r--r--pbx/pbx_ael.c1
-rw-r--r--pbx/pbx_dundi.c2
-rw-r--r--res/res_agi.c1
-rw-r--r--res/res_ari.c3
-rw-r--r--res/res_ari_applications.c2
-rw-r--r--res/res_ari_asterisk.c2
-rw-r--r--res/res_ari_bridges.c2
-rw-r--r--res/res_ari_channels.c2
-rw-r--r--res/res_ari_device_states.c2
-rw-r--r--res/res_ari_endpoints.c2
-rw-r--r--res/res_ari_events.c2
-rw-r--r--res/res_ari_mailboxes.c2
-rw-r--r--res/res_ari_playbacks.c2
-rw-r--r--res/res_ari_recordings.c2
-rw-r--r--res/res_ari_sounds.c2
-rw-r--r--res/res_chan_stats.c2
-rw-r--r--res/res_endpoint_stats.c2
-rw-r--r--res/res_fax_spandsp.c1
-rw-r--r--res/res_hep_pjsip.c1
-rw-r--r--res/res_hep_rtcp.c1
-rw-r--r--res/res_mwi_external_ami.c2
-rw-r--r--res/res_pjsip.c1
-rw-r--r--res/res_pjsip_acl.c1
-rw-r--r--res/res_pjsip_authenticator_digest.c1
-rw-r--r--res/res_pjsip_caller_id.c2
-rw-r--r--res/res_pjsip_dialog_info_body_generator.c2
-rw-r--r--res/res_pjsip_diversion.c2
-rw-r--r--res/res_pjsip_dlg_options.c2
-rw-r--r--res/res_pjsip_dtmf_info.c2
-rw-r--r--res/res_pjsip_empty_info.c2
-rw-r--r--res/res_pjsip_endpoint_identifier_anonymous.c1
-rw-r--r--res/res_pjsip_endpoint_identifier_ip.c1
-rw-r--r--res/res_pjsip_endpoint_identifier_user.c1
-rw-r--r--res/res_pjsip_exten_state.c1
-rw-r--r--res/res_pjsip_header_funcs.c1
-rw-r--r--res/res_pjsip_history.c1
-rw-r--r--res/res_pjsip_logger.c1
-rw-r--r--res/res_pjsip_messaging.c2
-rw-r--r--res/res_pjsip_mwi.c1
-rw-r--r--res/res_pjsip_mwi_body_generator.c1
-rw-r--r--res/res_pjsip_nat.c1
-rw-r--r--res/res_pjsip_notify.c1
-rw-r--r--res/res_pjsip_one_touch_record_info.c2
-rw-r--r--res/res_pjsip_outbound_authenticator_digest.c1
-rw-r--r--res/res_pjsip_outbound_publish.c1
-rw-r--r--res/res_pjsip_outbound_registration.c1
-rw-r--r--res/res_pjsip_path.c1
-rw-r--r--res/res_pjsip_phoneprov_provider.c1
-rw-r--r--res/res_pjsip_pidf_body_generator.c1
-rw-r--r--res/res_pjsip_pidf_digium_body_supplement.c1
-rw-r--r--res/res_pjsip_pidf_eyebeam_body_supplement.c1
-rw-r--r--res/res_pjsip_publish_asterisk.c1
-rw-r--r--res/res_pjsip_pubsub.c1
-rw-r--r--res/res_pjsip_refer.c1
-rw-r--r--res/res_pjsip_registrar.c1
-rw-r--r--res/res_pjsip_registrar_expire.c1
-rw-r--r--res/res_pjsip_rfc3326.c2
-rw-r--r--res/res_pjsip_sdp_rtp.c1
-rw-r--r--res/res_pjsip_send_to_voicemail.c1
-rw-r--r--res/res_pjsip_session.c1
-rw-r--r--res/res_pjsip_sips_contact.c1
-rw-r--r--res/res_pjsip_t38.c1
-rw-r--r--res/res_pjsip_transport_management.c1
-rw-r--r--res/res_pjsip_transport_websocket.c1
-rw-r--r--res/res_pjsip_xpidf_body_generator.c2
-rw-r--r--res/res_stasis_answer.c2
-rw-r--r--res/res_stasis_device_state.c2
-rw-r--r--res/res_stasis_mailbox.c2
-rw-r--r--res/res_stasis_playback.c2
-rw-r--r--res/res_stasis_recording.c2
-rw-r--r--res/res_stasis_snoop.c2
-rw-r--r--rest-api-templates/res_ari_resource.c.mustache2
-rw-r--r--tests/test_ari.c2
-rw-r--r--tests/test_ari_model.c7
-rw-r--r--tests/test_res_pjsip_scheduler.c7
-rw-r--r--tests/test_res_stasis.c2
-rw-r--r--tests/test_stasis_endpoints.c2
96 files changed, 170 insertions, 64 deletions
diff --git a/apps/app_adsiprog.c b/apps/app_adsiprog.c
index 2dd226fbd..688168e52 100644
--- a/apps/app_adsiprog.c
+++ b/apps/app_adsiprog.c
@@ -1613,5 +1613,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "Asterisk ADSI Programmin
.support_level = AST_MODULE_SUPPORT_EXTENDED,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_adsi",
+ .requires = "res_adsi",
);
diff --git a/apps/app_getcpeid.c b/apps/app_getcpeid.c
index e0b9f1239..868dc97c3 100644
--- a/apps/app_getcpeid.c
+++ b/apps/app_getcpeid.c
@@ -140,5 +140,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "Get ADSI CPE ID",
.support_level = AST_MODULE_SUPPORT_EXTENDED,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_adsi",
+ .requires = "res_adsi",
);
diff --git a/apps/app_queue.c b/apps/app_queue.c
index c62828cfd..e7779b732 100644
--- a/apps/app_queue.c
+++ b/apps/app_queue.c
@@ -11345,5 +11345,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "True Call Queueing",
.unload = unload_module,
.reload = reload,
.load_pri = AST_MODPRI_DEVSTATE_CONSUMER,
- .nonoptreq = "res_monitor",
+ .optional_modules = "res_monitor",
);
diff --git a/apps/app_speech_utils.c b/apps/app_speech_utils.c
index 339c3161f..2ba297e33 100644
--- a/apps/app_speech_utils.c
+++ b/apps/app_speech_utils.c
@@ -1003,5 +1003,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "Dialplan Speech Applicat
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_speech",
+ .requires = "res_speech",
);
diff --git a/apps/app_stack.c b/apps/app_stack.c
index 459c06df2..1f98378c9 100644
--- a/apps/app_stack.c
+++ b/apps/app_stack.c
@@ -1320,5 +1320,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT | AST_MODFLAG_LOAD_ORDER,
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
- .nonoptreq = "res_agi",
+ .optional_modules = "res_agi",
);
diff --git a/apps/app_stasis.c b/apps/app_stasis.c
index 81c58e8b0..8d09349b9 100644
--- a/apps/app_stasis.c
+++ b/apps/app_stasis.c
@@ -144,5 +144,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "Stasis dialplan applicat
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_stasis",
+ .requires = "res_stasis",
);
diff --git a/apps/app_voicemail.c b/apps/app_voicemail.c
index 0bcfa4f3a..4853a53f9 100644
--- a/apps/app_voicemail.c
+++ b/apps/app_voicemail.c
@@ -16488,5 +16488,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, tdesc,
.load = load_module,
.unload = unload_module,
.reload = reload,
- .nonoptreq = "res_adsi,res_smdi",
+ .optional_modules = "res_adsi,res_smdi",
);
diff --git a/channels/chan_dahdi.c b/channels/chan_dahdi.c
index 4859d1a60..de2c15279 100644
--- a/channels/chan_dahdi.c
+++ b/channels/chan_dahdi.c
@@ -19542,5 +19542,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, tdesc,
.unload = unload_module,
.reload = reload,
.load_pri = AST_MODPRI_CHANNEL_DRIVER,
- .nonoptreq = "res_smdi",
+ .optional_modules = "res_smdi",
);
diff --git a/channels/chan_iax2.c b/channels/chan_iax2.c
index 469fcda9e..eade5d13c 100644
--- a/channels/chan_iax2.c
+++ b/channels/chan_iax2.c
@@ -14902,5 +14902,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "Inter Asterisk eXchan
.unload = unload_module,
.reload = reload,
.load_pri = AST_MODPRI_CHANNEL_DRIVER,
- .nonoptreq = "res_crypto",
+ .optional_modules = "res_crypto",
);
diff --git a/channels/chan_mgcp.c b/channels/chan_mgcp.c
index 547226c80..2ac7690a6 100644
--- a/channels/chan_mgcp.c
+++ b/channels/chan_mgcp.c
@@ -5025,5 +5025,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "Media Gateway Control
.unload = unload_module,
.reload = reload,
.load_pri = AST_MODPRI_CHANNEL_DRIVER,
- .nonoptreq = "res_pktccops",
+ .optional_modules = "res_pktccops",
);
diff --git a/channels/chan_motif.c b/channels/chan_motif.c
index df1eeb8ce..05184ca04 100644
--- a/channels/chan_motif.c
+++ b/channels/chan_motif.c
@@ -2821,4 +2821,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "Motif Jingle Channel
.unload = unload_module,
.reload = reload,
.load_pri = AST_MODPRI_CHANNEL_DRIVER,
+ .requires = "res_xmpp",
);
diff --git a/channels/chan_pjsip.c b/channels/chan_pjsip.c
index 4c30d335b..68da4a1bb 100644
--- a/channels/chan_pjsip.c
+++ b/channels/chan_pjsip.c
@@ -3110,4 +3110,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Channel Driver"
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DRIVER,
+ .requires = "res_pjsip,res_pjsip_session",
);
diff --git a/channels/chan_rtp.c b/channels/chan_rtp.c
index 0a59e330e..7d9e26db8 100644
--- a/channels/chan_rtp.c
+++ b/channels/chan_rtp.c
@@ -432,4 +432,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "RTP Media Channel",
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DRIVER,
+ .requires = "res_rtp_multicast",
);
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index e8cc591a3..fa9899027 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -35737,5 +35737,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "Session Initiation Pr
.unload = unload_module,
.reload = reload,
.load_pri = AST_MODPRI_CHANNEL_DRIVER,
- .nonoptreq = "res_crypto,res_http_websocket",
+ .optional_modules = "res_crypto,res_http_websocket",
);
diff --git a/funcs/func_aes.c b/funcs/func_aes.c
index 7208cd4c8..af3f257e5 100644
--- a/funcs/func_aes.c
+++ b/funcs/func_aes.c
@@ -180,5 +180,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "AES dialplan functions",
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_crypto",
+ .requires = "res_crypto",
);
diff --git a/funcs/func_pjsip_aor.c b/funcs/func_pjsip_aor.c
index 799e9e4ed..589f667af 100644
--- a/funcs/func_pjsip_aor.c
+++ b/funcs/func_pjsip_aor.c
@@ -181,4 +181,9 @@ static int load_module(void)
return ast_custom_function_register(&pjsip_aor_function);
}
-AST_MODULE_INFO_STANDARD(ASTERISK_GPL_KEY, "Get information about a PJSIP AOR");
+AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "Get information about a PJSIP AOR",
+ .support_level = AST_MODULE_SUPPORT_CORE,
+ .load = load_module,
+ .unload = unload_module,
+ .requires = "res_pjsip",
+);
diff --git a/funcs/func_pjsip_contact.c b/funcs/func_pjsip_contact.c
index c8403655a..fac4cb68c 100644
--- a/funcs/func_pjsip_contact.c
+++ b/funcs/func_pjsip_contact.c
@@ -198,4 +198,9 @@ static int load_module(void)
return ast_custom_function_register(&pjsip_contact_function);
}
-AST_MODULE_INFO_STANDARD(ASTERISK_GPL_KEY, "Get information about a PJSIP contact");
+AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "Get information about a PJSIP contact",
+ .support_level = AST_MODULE_SUPPORT_CORE,
+ .load = load_module,
+ .unload = unload_module,
+ .requires = "res_pjsip",
+);
diff --git a/funcs/func_pjsip_endpoint.c b/funcs/func_pjsip_endpoint.c
index a64d93b1e..e4a6abab3 100644
--- a/funcs/func_pjsip_endpoint.c
+++ b/funcs/func_pjsip_endpoint.c
@@ -156,4 +156,9 @@ static int load_module(void)
return ast_custom_function_register(&pjsip_endpoint_function);
}
-AST_MODULE_INFO_STANDARD(ASTERISK_GPL_KEY, "Get information about a PJSIP endpoint");
+AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "Get information about a PJSIP endpoint",
+ .support_level = AST_MODULE_SUPPORT_CORE,
+ .load = load_module,
+ .unload = unload_module,
+ .requires = "res_pjsip",
+);
diff --git a/include/asterisk/module.h b/include/asterisk/module.h
index 103cd3053..ebd41c06d 100644
--- a/include/asterisk/module.h
+++ b/include/asterisk/module.h
@@ -304,26 +304,28 @@ enum ast_module_load_priority {
};
struct ast_module_info {
-
/*!
* The 'self' pointer for a module; it will be set by the loader before
* it calls the module's load_module() entrypoint, and used by various
* other macros that need to identify the module.
*/
-
struct ast_module *self;
- enum ast_module_load_result (*load)(void); /*!< register stuff etc. Optional. */
- int (*reload)(void); /*!< config etc. Optional. */
- int (*unload)(void); /*!< unload. called with the module locked */
- const char *name; /*!< name of the module for loader reference and CLI commands */
- const char *description; /*!< user friendly description of the module. */
+ /*! Register stuff etc. Optional. */
+ enum ast_module_load_result (*load)(void);
+ /*! Config etc. Optional. */
+ int (*reload)(void);
+ /*! Unload. called with the module locked */
+ int (*unload)(void);
+ /*! Name of the module for loader reference and CLI commands */
+ const char *name;
+ /*! User friendly description of the module. */
+ const char *description;
/*!
* This holds the ASTERISK_GPL_KEY, signifiying that you agree to the terms of
* the Asterisk license as stated in the ASTERISK_GPL_KEY. Your module will not
* load if it does not return the EXACT key string.
*/
-
const char *key;
unsigned int flags;
@@ -337,10 +339,42 @@ struct ast_module_info {
* on load. */
unsigned char load_pri;
- /*! Modules which should be loaded first, in comma-separated string format.
- * These are only required for loading, when the optional_api header file
- * detects that the compiler does not support the optional API featureset. */
- const char *nonoptreq;
+ /*! Modules which must always be started first, in comma-separated string format. */
+ const char *requires;
+
+ /*!
+ * \brief Comma-separated list of optionally required modules.
+ *
+ * The listed modules are optional, but load order is enforced. For example
+ * app_voicemail optionally requires res_adsi. This means that app_voicemail
+ * will happily load without res_adsi, but if both are being loaded the module
+ * loader will force res_adsi to start first.
+ */
+ const char *optional_modules;
+
+ /*!
+ * \brief Modules that we provide enhanced functionality for.
+ *
+ * This is similar to a "requires" but specifies that we add functionality to
+ * the other modules. Any module that requires something we "enhances" will
+ * also require us, but only if we are dlopen'ed.
+ *
+ * Example:
+ * - res_fax_spandsp has .enhances = "res_fax".
+ * - res_my_module has .requires = "res_fax" but has no direct knowledge
+ * of res_fax_spandsp.
+ *
+ * This forces the following startup order among the 3 modules:
+ * 1) res_fax starts.
+ * 2) res_fax_spandsp starts, holds a reference to res_fax.
+ * 3) res_mymod starts, holds a reference to res_fax and res_fax_spandsp.
+ *
+ * If res_fax_spandsp were not being loaded res_mymod would load with
+ * res_fax only. If res_fax_spandsp were later loaded res_mymod would
+ * get a reference to it.
+ */
+ const char *enhances;
+
/*! The support level for the given module */
enum ast_module_support_level support_level;
};
@@ -411,6 +445,8 @@ void __ast_module_unref(struct ast_module *mod, const char *file, int line, cons
AST_BUILDOPT_SUM, \
load_pri, \
NULL, \
+ NULL, \
+ NULL, \
support_level, \
}; \
static void __attribute__((constructor)) __reg_module(void) \
diff --git a/pbx/pbx_ael.c b/pbx/pbx_ael.c
index 6517b3aeb..d55f2d42a 100644
--- a/pbx/pbx_ael.c
+++ b/pbx/pbx_ael.c
@@ -292,6 +292,7 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "Asterisk Extension Langu
.load = load_module,
.unload = unload_module,
.reload = reload,
+ .requires = "res_ael_share",
);
#ifdef AAL_ARGCHECK
diff --git a/pbx/pbx_dundi.c b/pbx/pbx_dundi.c
index e0aeb4903..92e71981f 100644
--- a/pbx/pbx_dundi.c
+++ b/pbx/pbx_dundi.c
@@ -5063,5 +5063,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "Distributed Universal Nu
.load = load_module,
.unload = unload_module,
.reload = reload,
- .nonoptreq = "res_crypto",
+ .optional_modules = "res_crypto",
);
diff --git a/res/res_agi.c b/res/res_agi.c
index 393a50351..2d0dc2743 100644
--- a/res/res_agi.c
+++ b/res/res_agi.c
@@ -4717,4 +4717,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_GLOBAL_SYMBOLS | AST_MODFLAG_LOAD_
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_speech",
);
diff --git a/res/res_ari.c b/res/res_ari.c
index 9104eded3..6ce25a582 100644
--- a/res/res_ari.c
+++ b/res/res_ari.c
@@ -1197,6 +1197,7 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_GLOBAL_SYMBOLS | AST_MODFLAG_LOAD_
.load = load_module,
.unload = unload_module,
.reload = reload_module,
- .nonoptreq = "res_http_websocket",
+ .optional_modules = "res_http_websocket",
+ .requires = "res_stasis",
.load_pri = AST_MODPRI_APP_DEPEND,
);
diff --git a/res/res_ari_applications.c b/res/res_ari_applications.c
index cf700c464..323bdb39a 100644
--- a/res/res_ari_applications.c
+++ b/res/res_ari_applications.c
@@ -518,5 +518,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "RESTful API module - Sta
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_ari,res_stasis",
+ .requires = "res_ari,res_ari_model,res_stasis",
);
diff --git a/res/res_ari_asterisk.c b/res/res_ari_asterisk.c
index eb0617b4c..9f76f939b 100644
--- a/res/res_ari_asterisk.c
+++ b/res/res_ari_asterisk.c
@@ -1239,5 +1239,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "RESTful API module - Ast
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_ari,res_stasis",
+ .requires = "res_ari,res_ari_model,res_stasis",
);
diff --git a/res/res_ari_bridges.c b/res/res_ari_bridges.c
index 35fd3bd7f..34b9d898c 100644
--- a/res/res_ari_bridges.c
+++ b/res/res_ari_bridges.c
@@ -1579,5 +1579,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "RESTful API module - Bri
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_ari,res_stasis",
+ .requires = "res_ari,res_ari_model,res_stasis",
);
diff --git a/res/res_ari_channels.c b/res/res_ari_channels.c
index f6befcc90..7862c1006 100644
--- a/res/res_ari_channels.c
+++ b/res/res_ari_channels.c
@@ -2869,5 +2869,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "RESTful API module - Cha
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_ari,res_stasis",
+ .requires = "res_ari,res_ari_model,res_stasis",
);
diff --git a/res/res_ari_device_states.c b/res/res_ari_device_states.c
index f39393562..ec8890b1e 100644
--- a/res/res_ari_device_states.c
+++ b/res/res_ari_device_states.c
@@ -349,5 +349,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "RESTful API module - Dev
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_ari,res_stasis",
+ .requires = "res_ari,res_ari_model,res_stasis",
);
diff --git a/res/res_ari_endpoints.c b/res/res_ari_endpoints.c
index d1242c0fb..07197ca97 100644
--- a/res/res_ari_endpoints.c
+++ b/res/res_ari_endpoints.c
@@ -473,5 +473,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "RESTful API module - End
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_ari,res_stasis",
+ .requires = "res_ari,res_ari_model,res_stasis",
);
diff --git a/res/res_ari_events.c b/res/res_ari_events.c
index f916d0e4e..f750a5454 100644
--- a/res/res_ari_events.c
+++ b/res/res_ari_events.c
@@ -473,5 +473,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "RESTful API module - Web
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_ari,res_stasis",
+ .requires = "res_ari,res_ari_model,res_stasis",
);
diff --git a/res/res_ari_mailboxes.c b/res/res_ari_mailboxes.c
index 1f6d2cc81..6469f936e 100644
--- a/res/res_ari_mailboxes.c
+++ b/res/res_ari_mailboxes.c
@@ -355,5 +355,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "RESTful API module - Mai
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_ari,res_stasis",
+ .requires = "res_ari,res_ari_model,res_stasis",
);
diff --git a/res/res_ari_playbacks.c b/res/res_ari_playbacks.c
index 40099cfb4..0148a7400 100644
--- a/res/res_ari_playbacks.c
+++ b/res/res_ari_playbacks.c
@@ -307,5 +307,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "RESTful API module - Pla
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_ari,res_stasis",
+ .requires = "res_ari,res_ari_model,res_stasis",
);
diff --git a/res/res_ari_recordings.c b/res/res_ari_recordings.c
index fe3d343ee..531ff6574 100644
--- a/res/res_ari_recordings.c
+++ b/res/res_ari_recordings.c
@@ -891,5 +891,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "RESTful API module - Rec
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_ari,res_stasis",
+ .requires = "res_ari,res_ari_model,res_stasis",
);
diff --git a/res/res_ari_sounds.c b/res/res_ari_sounds.c
index 8d5928a50..5c27ebd92 100644
--- a/res/res_ari_sounds.c
+++ b/res/res_ari_sounds.c
@@ -237,5 +237,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "RESTful API module - Sou
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_ari,res_stasis",
+ .requires = "res_ari,res_ari_model,res_stasis",
);
diff --git a/res/res_chan_stats.c b/res/res_chan_stats.c
index 061d0867e..dbc79f03e 100644
--- a/res/res_chan_stats.c
+++ b/res/res_chan_stats.c
@@ -182,5 +182,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "Example of how to use St
.support_level = AST_MODULE_SUPPORT_EXTENDED,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_statsd"
+ .requires = "res_statsd"
);
diff --git a/res/res_endpoint_stats.c b/res/res_endpoint_stats.c
index 1e3f104c2..7ce44f958 100644
--- a/res/res_endpoint_stats.c
+++ b/res/res_endpoint_stats.c
@@ -151,5 +151,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "Endpoint statistics",
.support_level = AST_MODULE_SUPPORT_EXTENDED,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_statsd"
+ .requires = "res_statsd"
);
diff --git a/res/res_fax_spandsp.c b/res/res_fax_spandsp.c
index a3a82e463..045dbc708 100644
--- a/res/res_fax_spandsp.c
+++ b/res/res_fax_spandsp.c
@@ -1266,4 +1266,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "Spandsp G.711 and T.38 F
.support_level = AST_MODULE_SUPPORT_EXTENDED,
.load = load_module,
.unload = unload_module,
+ .enhances = "res_fax",
);
diff --git a/res/res_hep_pjsip.c b/res/res_hep_pjsip.c
index 6283efc76..ff0267501 100644
--- a/res/res_hep_pjsip.c
+++ b/res/res_hep_pjsip.c
@@ -253,4 +253,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "PJSIP HEPv3 Logger",
.support_level = AST_MODULE_SUPPORT_EXTENDED,
.load = load_module,
.unload = unload_module,
+ .requires = "res_hep,res_pjsip",
);
diff --git a/res/res_hep_rtcp.c b/res/res_hep_rtcp.c
index afad0c845..199c8164d 100644
--- a/res/res_hep_rtcp.c
+++ b/res/res_hep_rtcp.c
@@ -184,4 +184,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "RTCP HEPv3 Logger",
.support_level = AST_MODULE_SUPPORT_EXTENDED,
.load = load_module,
.unload = unload_module,
+ .requires = "res_hep",
);
diff --git a/res/res_mwi_external_ami.c b/res/res_mwi_external_ami.c
index 8419f2fff..8639fad40 100644
--- a/res/res_mwi_external_ami.c
+++ b/res/res_mwi_external_ami.c
@@ -370,4 +370,6 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "AMI support for external
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
+ .load_pri = AST_MODPRI_CHANNEL_DEPEND - 5,
+ .requires = "res_mwi_external",
);
diff --git a/res/res_pjsip.c b/res/res_pjsip.c
index 0311dfd4b..3f9574d2a 100644
--- a/res/res_pjsip.c
+++ b/res/res_pjsip.c
@@ -5125,4 +5125,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_GLOBAL_SYMBOLS | AST_MODFLAG_LOAD_
.unload = unload_module,
.reload = reload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND - 5,
+ .requires = "res_pjproject",
);
diff --git a/res/res_pjsip_acl.c b/res/res_pjsip_acl.c
index 5c10e5779..926986422 100644
--- a/res/res_pjsip_acl.c
+++ b/res/res_pjsip_acl.c
@@ -321,4 +321,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP ACL Resource",
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_authenticator_digest.c b/res/res_pjsip_authenticator_digest.c
index ef57e3754..b6f2b74ff 100644
--- a/res/res_pjsip_authenticator_digest.c
+++ b/res/res_pjsip_authenticator_digest.c
@@ -554,4 +554,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP authentication
.unload = unload_module,
.reload = reload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND - 5,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_caller_id.c b/res/res_pjsip_caller_id.c
index 64191a750..16731479e 100644
--- a/res/res_pjsip_caller_id.c
+++ b/res/res_pjsip_caller_id.c
@@ -19,7 +19,6 @@
/*** MODULEINFO
<depend>pjproject</depend>
<depend>res_pjsip</depend>
- <depend>res_pjsip_session</depend>
<support_level>core</support_level>
***/
@@ -764,4 +763,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Caller ID Suppo
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_dialog_info_body_generator.c b/res/res_pjsip_dialog_info_body_generator.c
index 7c386e3b2..866ea9df8 100644
--- a/res/res_pjsip_dialog_info_body_generator.c
+++ b/res/res_pjsip_dialog_info_body_generator.c
@@ -20,7 +20,6 @@
<depend>pjproject</depend>
<depend>res_pjsip</depend>
<depend>res_pjsip_pubsub</depend>
- <depend>res_pjsip_exten_state</depend>
<support_level>core</support_level>
***/
@@ -219,4 +218,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Extension State
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND,
+ .requires = "res_pjsip,res_pjsip_pubsub",
);
diff --git a/res/res_pjsip_diversion.c b/res/res_pjsip_diversion.c
index efb5489f8..84c42dca8 100644
--- a/res/res_pjsip_diversion.c
+++ b/res/res_pjsip_diversion.c
@@ -19,7 +19,6 @@
/*** MODULEINFO
<depend>pjproject</depend>
<depend>res_pjsip</depend>
- <depend>res_pjsip_session</depend>
<support_level>core</support_level>
***/
@@ -429,4 +428,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Add Diversion H
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_dlg_options.c b/res/res_pjsip_dlg_options.c
index de1ac97ef..565ad2afc 100644
--- a/res/res_pjsip_dlg_options.c
+++ b/res/res_pjsip_dlg_options.c
@@ -19,7 +19,6 @@
/*** MODULEINFO
<depend>pjproject</depend>
<depend>res_pjsip</depend>
- <depend>res_pjsip_session</depend>
<support_level>core</support_level>
***/
@@ -103,4 +102,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "SIP OPTIONS in dialog
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_dtmf_info.c b/res/res_pjsip_dtmf_info.c
index e534f3e27..68df61785 100644
--- a/res/res_pjsip_dtmf_info.c
+++ b/res/res_pjsip_dtmf_info.c
@@ -19,7 +19,6 @@
/*** MODULEINFO
<depend>pjproject</depend>
<depend>res_pjsip</depend>
- <depend>res_pjsip_session</depend>
<support_level>core</support_level>
***/
@@ -178,4 +177,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP DTMF INFO Suppo
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_empty_info.c b/res/res_pjsip_empty_info.c
index 774f9de7e..c67835ce0 100644
--- a/res/res_pjsip_empty_info.c
+++ b/res/res_pjsip_empty_info.c
@@ -19,7 +19,6 @@
/*** MODULEINFO
<depend>pjproject</depend>
<depend>res_pjsip</depend>
- <depend>res_pjsip_session</depend>
<support_level>core</support_level>
***/
@@ -84,4 +83,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Empty INFO Supp
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_endpoint_identifier_anonymous.c b/res/res_pjsip_endpoint_identifier_anonymous.c
index b47aefa94..16662ebd5 100644
--- a/res/res_pjsip_endpoint_identifier_anonymous.c
+++ b/res/res_pjsip_endpoint_identifier_anonymous.c
@@ -132,4 +132,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "PJSIP Anonymous endpoint
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_endpoint_identifier_ip.c b/res/res_pjsip_endpoint_identifier_ip.c
index a672b333a..58e462460 100644
--- a/res/res_pjsip_endpoint_identifier_ip.c
+++ b/res/res_pjsip_endpoint_identifier_ip.c
@@ -764,4 +764,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP IP endpoint ide
.reload = reload_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND - 4,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_endpoint_identifier_user.c b/res/res_pjsip_endpoint_identifier_user.c
index ff97a62e4..1b0c7d99a 100644
--- a/res/res_pjsip_endpoint_identifier_user.c
+++ b/res/res_pjsip_endpoint_identifier_user.c
@@ -214,4 +214,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP username endpoi
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND - 4,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_exten_state.c b/res/res_pjsip_exten_state.c
index 3e756134c..e70eba7cd 100644
--- a/res/res_pjsip_exten_state.c
+++ b/res/res_pjsip_exten_state.c
@@ -1015,4 +1015,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Extension State
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND + 5,
+ .requires = "res_pjsip,res_pjsip_pubsub,res_pjsip_outbound_publish",
);
diff --git a/res/res_pjsip_header_funcs.c b/res/res_pjsip_header_funcs.c
index 648f1c860..06fba0635 100644
--- a/res/res_pjsip_header_funcs.c
+++ b/res/res_pjsip_header_funcs.c
@@ -629,4 +629,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Header Function
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip,res_pjsip_session",
);
diff --git a/res/res_pjsip_history.c b/res/res_pjsip_history.c
index d6b3eebe9..40d26d59d 100644
--- a/res/res_pjsip_history.c
+++ b/res/res_pjsip_history.c
@@ -1403,4 +1403,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP History",
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_logger.c b/res/res_pjsip_logger.c
index d29a6e213..460b6a34f 100644
--- a/res/res_pjsip_logger.c
+++ b/res/res_pjsip_logger.c
@@ -262,4 +262,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Packet Logger",
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_messaging.c b/res/res_pjsip_messaging.c
index b6e7a64c3..3739bcf93 100644
--- a/res/res_pjsip_messaging.c
+++ b/res/res_pjsip_messaging.c
@@ -19,7 +19,6 @@
/*** MODULEINFO
<depend>pjproject</depend>
<depend>res_pjsip</depend>
- <depend>res_pjsip_session</depend>
<support_level>core</support_level>
***/
@@ -850,4 +849,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Messaging Suppo
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_mwi.c b/res/res_pjsip_mwi.c
index 5423038e6..92dc7dc65 100644
--- a/res/res_pjsip_mwi.c
+++ b/res/res_pjsip_mwi.c
@@ -1397,4 +1397,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP MWI resource",
.unload = unload_module,
.reload = reload,
.load_pri = AST_MODPRI_CHANNEL_DEPEND + 5,
+ .requires = "res_pjsip,res_pjsip_pubsub",
);
diff --git a/res/res_pjsip_mwi_body_generator.c b/res/res_pjsip_mwi_body_generator.c
index e8279101c..65ac60067 100644
--- a/res/res_pjsip_mwi_body_generator.c
+++ b/res/res_pjsip_mwi_body_generator.c
@@ -116,4 +116,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP MWI resource",
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND,
+ .requires = "res_pjsip,res_pjsip_pubsub",
);
diff --git a/res/res_pjsip_nat.c b/res/res_pjsip_nat.c
index e1d56e6af..4231a1ec3 100644
--- a/res/res_pjsip_nat.c
+++ b/res/res_pjsip_nat.c
@@ -378,4 +378,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP NAT Support",
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_notify.c b/res/res_pjsip_notify.c
index 59b7c6ea4..9767c56b5 100644
--- a/res/res_pjsip_notify.c
+++ b/res/res_pjsip_notify.c
@@ -1032,4 +1032,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "CLI/AMI PJSIP NOTIFY
.reload = reload_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_one_touch_record_info.c b/res/res_pjsip_one_touch_record_info.c
index ec5f9be3e..ef59fca13 100644
--- a/res/res_pjsip_one_touch_record_info.c
+++ b/res/res_pjsip_one_touch_record_info.c
@@ -19,7 +19,6 @@
/*** MODULEINFO
<depend>pjproject</depend>
<depend>res_pjsip</depend>
- <depend>res_pjsip_session</depend>
<support_level>core</support_level>
***/
@@ -129,4 +128,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP INFO One Touch
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_outbound_authenticator_digest.c b/res/res_pjsip_outbound_authenticator_digest.c
index 7e2d71129..54bba08de 100644
--- a/res/res_pjsip_outbound_authenticator_digest.c
+++ b/res/res_pjsip_outbound_authenticator_digest.c
@@ -224,4 +224,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP authentication
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_outbound_publish.c b/res/res_pjsip_outbound_publish.c
index e5f12951f..b4e3320f4 100644
--- a/res/res_pjsip_outbound_publish.c
+++ b/res/res_pjsip_outbound_publish.c
@@ -1702,4 +1702,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_GLOBAL_SYMBOLS | AST_MODFLAG_LOAD_
.reload = reload_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND,
+ .requires = "res_pjproject,res_pjsip",
);
diff --git a/res/res_pjsip_outbound_registration.c b/res/res_pjsip_outbound_registration.c
index d9afcd284..79bea482b 100644
--- a/res/res_pjsip_outbound_registration.c
+++ b/res/res_pjsip_outbound_registration.c
@@ -2289,4 +2289,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Outbound Regist
.reload = reload_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_path.c b/res/res_pjsip_path.c
index e170a750d..b245f159d 100644
--- a/res/res_pjsip_path.c
+++ b/res/res_pjsip_path.c
@@ -264,4 +264,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Path Header Sup
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_phoneprov_provider.c b/res/res_pjsip_phoneprov_provider.c
index 7e082c4b5..11031c3c1 100644
--- a/res/res_pjsip_phoneprov_provider.c
+++ b/res/res_pjsip_phoneprov_provider.c
@@ -418,4 +418,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Phoneprov Provi
.reload = reload_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip,res_phoneprov",
);
diff --git a/res/res_pjsip_pidf_body_generator.c b/res/res_pjsip_pidf_body_generator.c
index 29c9e6be2..6426dfa9d 100644
--- a/res/res_pjsip_pidf_body_generator.c
+++ b/res/res_pjsip_pidf_body_generator.c
@@ -135,4 +135,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Extension State
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND,
+ .requires = "res_pjsip,res_pjsip_pubsub",
);
diff --git a/res/res_pjsip_pidf_digium_body_supplement.c b/res/res_pjsip_pidf_digium_body_supplement.c
index 93e4982e2..f855e2153 100644
--- a/res/res_pjsip_pidf_digium_body_supplement.c
+++ b/res/res_pjsip_pidf_digium_body_supplement.c
@@ -114,4 +114,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP PIDF Digium pre
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND,
+ .requires = "res_pjsip,res_pjsip_pubsub",
);
diff --git a/res/res_pjsip_pidf_eyebeam_body_supplement.c b/res/res_pjsip_pidf_eyebeam_body_supplement.c
index 40470840c..6629aa3c1 100644
--- a/res/res_pjsip_pidf_eyebeam_body_supplement.c
+++ b/res/res_pjsip_pidf_eyebeam_body_supplement.c
@@ -111,4 +111,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP PIDF Eyebeam su
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND,
+ .requires = "res_pjsip,res_pjsip_pubsub",
);
diff --git a/res/res_pjsip_publish_asterisk.c b/res/res_pjsip_publish_asterisk.c
index 53ee60fe4..13d7fd43b 100644
--- a/res/res_pjsip_publish_asterisk.c
+++ b/res/res_pjsip_publish_asterisk.c
@@ -934,4 +934,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Asterisk Event
.reload = reload_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND + 5,
+ .requires = "res_pjsip,res_pjsip_outbound_publish,res_pjsip_pubsub",
);
diff --git a/res/res_pjsip_pubsub.c b/res/res_pjsip_pubsub.c
index 1f24de050..af696b849 100644
--- a/res/res_pjsip_pubsub.c
+++ b/res/res_pjsip_pubsub.c
@@ -5518,4 +5518,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_GLOBAL_SYMBOLS | AST_MODFLAG_LOAD_
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_refer.c b/res/res_pjsip_refer.c
index 62f8b67de..3100993de 100644
--- a/res/res_pjsip_refer.c
+++ b/res/res_pjsip_refer.c
@@ -1229,4 +1229,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Blind and Atten
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip,res_pjsip_session,res_pjsip_pubsub",
);
diff --git a/res/res_pjsip_registrar.c b/res/res_pjsip_registrar.c
index f0da6dee2..7277a5f4f 100644
--- a/res/res_pjsip_registrar.c
+++ b/res/res_pjsip_registrar.c
@@ -1134,4 +1134,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Registrar Suppo
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND - 3,
+ .requires = "res_pjproject,res_pjsip",
);
diff --git a/res/res_pjsip_registrar_expire.c b/res/res_pjsip_registrar_expire.c
index fe4a60da8..85e3fb859 100644
--- a/res/res_pjsip_registrar_expire.c
+++ b/res/res_pjsip_registrar_expire.c
@@ -150,4 +150,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Contact Auto-Ex
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_rfc3326.c b/res/res_pjsip_rfc3326.c
index d49a170d3..8b8035efc 100644
--- a/res/res_pjsip_rfc3326.c
+++ b/res/res_pjsip_rfc3326.c
@@ -19,7 +19,6 @@
/*** MODULEINFO
<depend>pjproject</depend>
<depend>res_pjsip</depend>
- <depend>res_pjsip_session</depend>
<support_level>core</support_level>
***/
@@ -156,4 +155,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP RFC3326 Support
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_sdp_rtp.c b/res/res_pjsip_sdp_rtp.c
index 9e0411903..3cc97644a 100644
--- a/res/res_pjsip_sdp_rtp.c
+++ b/res/res_pjsip_sdp_rtp.c
@@ -1970,4 +1970,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP SDP RTP/AVP str
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DRIVER,
+ .requires = "res_pjsip,res_pjsip_session",
);
diff --git a/res/res_pjsip_send_to_voicemail.c b/res/res_pjsip_send_to_voicemail.c
index 1cd28ceac..06c3edc03 100644
--- a/res/res_pjsip_send_to_voicemail.c
+++ b/res/res_pjsip_send_to_voicemail.c
@@ -236,4 +236,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP REFER Send to V
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip,res_pjsip_session",
);
diff --git a/res/res_pjsip_session.c b/res/res_pjsip_session.c
index 53f60cc3b..8247fbaaa 100644
--- a/res/res_pjsip_session.c
+++ b/res/res_pjsip_session.c
@@ -4202,4 +4202,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_GLOBAL_SYMBOLS | AST_MODFLAG_LOAD_
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_sips_contact.c b/res/res_pjsip_sips_contact.c
index 7579be6f3..41b26df7d 100644
--- a/res/res_pjsip_sips_contact.c
+++ b/res/res_pjsip_sips_contact.c
@@ -104,4 +104,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "UAC SIPS Contact supp
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_t38.c b/res/res_pjsip_t38.c
index 8f1905f6e..7b7cd9910 100644
--- a/res/res_pjsip_t38.c
+++ b/res/res_pjsip_t38.c
@@ -1053,4 +1053,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP T.38 UDPTL Supp
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DRIVER,
+ .requires = "res_pjsip,res_pjsip_session",
);
diff --git a/res/res_pjsip_transport_management.c b/res/res_pjsip_transport_management.c
index eb92eb7a5..acffb86dc 100644
--- a/res/res_pjsip_transport_management.c
+++ b/res/res_pjsip_transport_management.c
@@ -397,4 +397,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Reliable Transp
.reload = reload_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND - 4,
+ .requires = "res_pjsip",
);
diff --git a/res/res_pjsip_transport_websocket.c b/res/res_pjsip_transport_websocket.c
index 3ce90390c..af1345f35 100644
--- a/res/res_pjsip_transport_websocket.c
+++ b/res/res_pjsip_transport_websocket.c
@@ -518,4 +518,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP WebSocket Trans
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_APP_DEPEND,
+ .requires = "res_pjsip,res_http_websocket",
);
diff --git a/res/res_pjsip_xpidf_body_generator.c b/res/res_pjsip_xpidf_body_generator.c
index 41f6224d1..f7c84db3d 100644
--- a/res/res_pjsip_xpidf_body_generator.c
+++ b/res/res_pjsip_xpidf_body_generator.c
@@ -20,7 +20,6 @@
<depend>pjproject</depend>
<depend>res_pjsip</depend>
<depend>res_pjsip_pubsub</depend>
- <depend>res_pjsip_exten_state</depend>
<support_level>core</support_level>
***/
@@ -177,4 +176,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_ORDER, "PJSIP Extension State
.load = load_module,
.unload = unload_module,
.load_pri = AST_MODPRI_CHANNEL_DEPEND,
+ .requires = "res_pjsip,res_pjsip_pubsub",
);
diff --git a/res/res_stasis_answer.c b/res/res_stasis_answer.c
index 407a63135..6ec50c81b 100644
--- a/res/res_stasis_answer.c
+++ b/res/res_stasis_answer.c
@@ -73,5 +73,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_GLOBAL_SYMBOLS, "Stasis applicatio
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_stasis"
+ .requires = "res_stasis",
);
diff --git a/res/res_stasis_device_state.c b/res/res_stasis_device_state.c
index 6527af4a6..be09b15ad 100644
--- a/res/res_stasis_device_state.c
+++ b/res/res_stasis_device_state.c
@@ -482,5 +482,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_GLOBAL_SYMBOLS, "Stasis applicatio
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_stasis"
+ .requires = "res_stasis",
);
diff --git a/res/res_stasis_mailbox.c b/res/res_stasis_mailbox.c
index 5ed061de2..3d0e9db69 100644
--- a/res/res_stasis_mailbox.c
+++ b/res/res_stasis_mailbox.c
@@ -161,5 +161,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_GLOBAL_SYMBOLS, "Stasis applicatio
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_stasis,res_mwi_external"
+ .requires = "res_stasis,res_mwi_external"
);
diff --git a/res/res_stasis_playback.c b/res/res_stasis_playback.c
index ca0446b89..5b8256fc4 100644
--- a/res/res_stasis_playback.c
+++ b/res/res_stasis_playback.c
@@ -759,5 +759,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_GLOBAL_SYMBOLS, "Stasis applicatio
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_stasis,res_stasis_recording"
+ .requires = "res_stasis,res_stasis_recording"
);
diff --git a/res/res_stasis_recording.c b/res/res_stasis_recording.c
index 56984cb40..17213aa24 100644
--- a/res/res_stasis_recording.c
+++ b/res/res_stasis_recording.c
@@ -655,6 +655,6 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_GLOBAL_SYMBOLS | AST_MODFLAG_LOAD_
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_stasis",
+ .requires = "res_stasis",
.load_pri = AST_MODPRI_APP_DEPEND
);
diff --git a/res/res_stasis_snoop.c b/res/res_stasis_snoop.c
index f797a9b94..b234de111 100644
--- a/res/res_stasis_snoop.c
+++ b/res/res_stasis_snoop.c
@@ -445,5 +445,5 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_GLOBAL_SYMBOLS, "Stasis applicatio
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_stasis"
+ .requires = "res_stasis",
);
diff --git a/rest-api-templates/res_ari_resource.c.mustache b/rest-api-templates/res_ari_resource.c.mustache
index d4ccda9e8..c1f680f21 100644
--- a/rest-api-templates/res_ari_resource.c.mustache
+++ b/rest-api-templates/res_ari_resource.c.mustache
@@ -324,6 +324,6 @@ AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "RESTful API module - {{{
.support_level = AST_MODULE_SUPPORT_CORE,
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_ari,res_stasis",
+ .requires = "res_ari,res_ari_model,res_stasis",
);
{{/api_declaration}}
diff --git a/tests/test_ari.c b/tests/test_ari.c
index bce5f95d6..a5db2284f 100644
--- a/tests/test_ari.c
+++ b/tests/test_ari.c
@@ -573,5 +573,5 @@ static int load_module(void)
AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "ARI testing",
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_ari",
+ .requires = "res_ari",
);
diff --git a/tests/test_ari_model.c b/tests/test_ari_model.c
index caf411878..e5a96cdd1 100644
--- a/tests/test_ari_model.c
+++ b/tests/test_ari_model.c
@@ -452,4 +452,9 @@ static int load_module(void)
return AST_MODULE_LOAD_SUCCESS;
}
-AST_MODULE_INFO_STANDARD(ASTERISK_GPL_KEY, "Skeleton (sample) Test");
+AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "Skeleton (sample) Test",
+ .support_level = AST_MODULE_SUPPORT_CORE,
+ .load = load_module,
+ .unload = unload_module,
+ .requires = "res_ari_model",
+);
diff --git a/tests/test_res_pjsip_scheduler.c b/tests/test_res_pjsip_scheduler.c
index da51d43be..47a7034ff 100644
--- a/tests/test_res_pjsip_scheduler.c
+++ b/tests/test_res_pjsip_scheduler.c
@@ -396,4 +396,9 @@ static int unload_module(void)
return 0;
}
-AST_MODULE_INFO_STANDARD(ASTERISK_GPL_KEY, "res_pjsip scheduler test module");
+AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "res_pjsip scheduler test module",
+ .support_level = AST_MODULE_SUPPORT_CORE,
+ .load = load_module,
+ .unload = unload_module,
+ .requires = "res_pjsip",
+);
diff --git a/tests/test_res_stasis.c b/tests/test_res_stasis.c
index cb79fa6fe..077cc4c7a 100644
--- a/tests/test_res_stasis.c
+++ b/tests/test_res_stasis.c
@@ -195,5 +195,5 @@ static int load_module(void)
AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "Stasis Core testing",
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_stasis",
+ .requires = "res_stasis",
);
diff --git a/tests/test_stasis_endpoints.c b/tests/test_stasis_endpoints.c
index 134738fee..42c7532eb 100644
--- a/tests/test_stasis_endpoints.c
+++ b/tests/test_stasis_endpoints.c
@@ -306,5 +306,5 @@ static int load_module(void)
AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_DEFAULT, "Endpoint stasis-related testing",
.load = load_module,
.unload = unload_module,
- .nonoptreq = "res_stasis_test",
+ .requires = "res_stasis_test",
);