]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
docs: Use AP_DECLARE_MODULE in Developing modules and mod_so guides
authorJoe Orton <jorton@apache.org>
Tue, 16 Apr 2024 09:27:40 +0000 (09:27 +0000)
committerJoe Orton <jorton@apache.org>
Tue, 16 Apr 2024 09:27:40 +0000 (09:27 +0000)
Submitted by: Vladimír Chlup <vchlup redhat.com>
Github: closes #432

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1917015 13f79535-47bb-0310-9956-ffa450edef68

docs/manual/developer/modguide.xml
docs/manual/mod/mod_so.xml
docs/manual/mod/mod_so.xml.fr
docs/manual/mod/mod_so.xml.ja
docs/manual/mod/mod_so.xml.ko
docs/manual/mod/mod_so.xml.tr

index 1b517411cad4ee7aa152b16ce89c472b0e77de8b..c2c8eeaa2ec80249908e0dde20bebd0d49893493 100644 (file)
@@ -94,7 +94,7 @@ that defines a module as <em>a separate entity within Apache</em>:</p>
 
 <!-- BEGIN EXAMPLE CODE -->
 <highlight language="c">
-module AP_MODULE_DECLARE_DATA   example_module =
+AP_DECLARE_MODULE(example) =
 {
     STANDARD20_MODULE_STUFF,
     create_dir_conf, /* Per-directory configuration handler */
@@ -110,11 +110,12 @@ module AP_MODULE_DECLARE_DATA   example_module =
 <p>
 This bit of code lets the server know that we have now registered a new module
 in the system, and that its name is <code>example_module</code>. The name
-of the module is used primarily for two things:<br/>
+of the module is used primarily for three things:<br/>
 </p>
 <ul>
 <li>Letting the server know how to load the module using the LoadModule</li>
 <li>Setting up a namespace for the module to use in configurations</li>
+<li>Allowing the user to distinguish an origin of log messages</li>
 </ul>
 <p>
 For now, we're only concerned with the first purpose of the module name,
@@ -188,7 +189,7 @@ definition will look like this:</p>
 
 <!-- BEGIN EXAMPLE CODE -->
 <highlight language="c">
-module AP_MODULE_DECLARE_DATA   example_module =
+AP_DECLARE_MODULE(example) =
 {
     STANDARD20_MODULE_STUFF,
     NULL,
@@ -795,7 +796,7 @@ static void register_hooks(apr_pool_t *pool)
 
 /* Define our module as an entity and assign a function for registering hooks  */
 
-module AP_MODULE_DECLARE_DATA   example_module =
+AP_DECLARE_MODULE(example) =
 {
     STANDARD20_MODULE_STUFF,
     NULL,            /* Per-directory configuration handler */
@@ -834,7 +835,7 @@ reference to the configuration directives we want to register with the server:
 
 <!-- BEGIN EXAMPLE CODE -->
 <highlight language="c">
-module AP_MODULE_DECLARE_DATA   example_module =
+AP_DECLARE_MODULE(example) =
 {
     STANDARD20_MODULE_STUFF,
     NULL,               /* Per-directory configuration handler */
@@ -1045,7 +1046,7 @@ static void register_hooks(apr_pool_t *pool)
  Our module name tag:
  ==============================================================================
  */
-module AP_MODULE_DECLARE_DATA   example_module =
+AP_DECLARE_MODULE(example) =
 {
     STANDARD20_MODULE_STUFF,
     NULL,               /* Per-directory configuration handler */
@@ -1210,7 +1211,7 @@ per-directory creator and merger function reference in our tag:</p>
 
 <!-- BEGIN EXAMPLE CODE -->
 <highlight language="c">
-module AP_MODULE_DECLARE_DATA   example_module =
+AP_DECLARE_MODULE(example) =
 {
     STANDARD20_MODULE_STUFF,
     create_dir_conf, /* Per-directory configuration handler */
@@ -1408,7 +1409,7 @@ static const command_rec    directives[] =
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  */
 
-module AP_MODULE_DECLARE_DATA    example_module =
+AP_DECLARE_MODULE(example) =
 {
     STANDARD20_MODULE_STUFF,
     create_dir_conf,    /* Per-directory configuration handler */
index bfcfdf6f3f83f8f9660784da04859a801b2c57ba..b88aedeab54356b095bcaa219fe59fcde2241987 100644 (file)
@@ -90,7 +90,7 @@ Windows</compatibility>
     <p>To create a module DLL, a small change is necessary to the
     module's source file: The module record must be exported from
     the DLL (which will be created later; see below). To do this,
-    add the <code>AP_MODULE_DECLARE_DATA</code> (defined in the
+    add the <code>AP_DECLARE_MODULE</code> (defined in the
     Apache httpd header files) to your module's module record definition.
     For example, if your module has:</p>
 
@@ -100,7 +100,7 @@ Windows</compatibility>
 
     <p>Replace the above with:</p>
 <example>
-    module AP_MODULE_DECLARE_DATA foo_module;
+    AP_DECLARE_MODULE(foo);
 </example>
 
     <p>Note that this will only be activated on Windows, so the
index bccda6354613ebc60f7166f8854b3e202ea82564..d4cf8cdf8b05d5a5289ae5e817fcdabc25d30ecb 100644 (file)
@@ -100,7 +100,7 @@ Windows</title>
     modification à son fichier source : l'enregistrement du module doit
     être exporté depuis la DLL (qui sera elle-même créée plus tard ;
     voir plus loin). Pour ce faire, ajoutez la macro
-    <code>AP_MODULE_DECLARE_DATA</code> (définie dans les fichiers
+    <code>AP_DECLARE_MODULE</code> (définie dans les fichiers
     d'en-têtes d'Apache httpd) à la définition de l'enregistrement de votre
     module. Par exemple, si votre module est déclaré comme suit :</p>
 
@@ -110,7 +110,7 @@ Windows</title>
 
     <p>Remplacez cette ligne par :</p>
 <example>
-    module AP_MODULE_DECLARE_DATA foo_module;
+    AP_DECLARE_MODULE(foo);
 </example>
 
     <p>Notez que cette macro ne sera prise en compte que sous Windows,
index b3854b93ca2b4f88d5754aca0afacd5f53ef171e..8fde679be6999b9572f219d2ee69d6ba3afee1bc 100644 (file)
@@ -90,7 +90,7 @@
     モジュールの作成に小さな変更を行なう必要があります。
     つまり、モジュールのレコード (これは後で作成されます。
     以下を参照してください) が DLL からエクスポートされなければなりません。
-    これを行なうには、<code>AP_MODULE_DECLARE_DATA</code> (Apache httpd
+    これを行なうには、<code>AP_DECLARE_MODULE</code> (Apache httpd
     のヘッダファイルで定義されています) をモジュールのモジュールレコード
     定義の部分に追加してください。たとえば、モジュールに</p>
 <example>
@@ -99,7 +99,7 @@
 
     <p>があるとすると、それを次のもので置き換えてください。</p>
 <example>
-    module AP_MODULE_DECLARE_DATA foo_module;
+    AP_DECLARE_MODULE(foo);
 </example>
 
     <p>Unix 上でもこのモジュールを
index e19ca8ff1d919f28812c971aa2ea1873a4af10bd..38235b424f2b0d48f14d1e4fd78e30f2f71156c0 100644 (file)
@@ -77,7 +77,7 @@
     <p>¸ðµâ DLLÀ» ¸¸µé±âÀ§Çؼ­´Â ¸ðµâÀÇ ¼Ò½ºÆÄÀÏÀ» Á¶±Ý ¼öÁ¤Çؾß
     ÇÑ´Ù. DLLÀº module record¸¦ exportÇØ¾ß ÇÑ´Ù. (¾Æ·¡ Âü°í)
     À̸¦ À§ÇØ ¸ðµâÀÇ module record Á¤ÀÇ¿¡ (¾ÆÆÄÄ¡ Çì´õÆÄÀÏ¿¡
-    Á¤ÀǵÈ) <code>AP_MODULE_DECLARE_DATA</code>¸¦ Ãß°¡ÇÑ´Ù.
+    Á¤ÀǵÈ) <code>AP_DECLARE_MODULE</code>¸¦ Ãß°¡ÇÑ´Ù.
     ¿¹¸¦ µé¾î, ´ÙÀ½°ú °°Àº ¸ðµâÀÌ ÀÖ´Ù¸é:</p>
 
 <example>
@@ -86,7 +86,7 @@
 
     <p>´ÙÀ½°ú °°ÀÌ ¼öÁ¤ÇÑ´Ù:</p>
 <example>
-    module AP_MODULE_DECLARE_DATA foo_module;
+    AP_DECLARE_MODULE(foo);
 </example>
 
     <p>ÀÌ ºÎºÐÀº À©µµ¿ìÁî¿¡¼­¸¸ »ç¿ëÇϱ⶧¹®¿¡ º¯°æÇÏ¿©µµ À¯´Ð½º¿¡¼­
index 4a5e751f4874f205b0681b39755c8d72151400a4..73396d8c813b97f094e497f99a9d7701f1ba154d 100644 (file)
@@ -91,7 +91,7 @@ yeniden başlatılması sırasında yüklenmesini sağlar.</description>
       değişiklik yapmak gerekir: Modül kaydının daha sonra oluşturulacak olan
       DLL’den ihraç edilebilmesi gerekir (aşağıya bakınız). Bunu yapmak için
       modülün modül kaydı tanımına (Apache httpd başlık dosyalarında
-      tanımlanmış olan) <code>AP_MODULE_DECLARE_DATA</code> eklenmelidir.
+      tanımlanmış olan) <code>AP_DECLARE_MODULE</code> eklenmelidir.
       Örneğin, modülünüz</p>
 
     <example>
@@ -101,7 +101,7 @@ yeniden başlatılması sırasında yüklenmesini sağlar.</description>
     <p>diye bir satır içeriyorsa bunu,</p>
 
     <example>
-        module AP_MODULE_DECLARE_DATA foo_module;
+        AP_DECLARE_MODULE(foo);
     </example>
 
     <p>olarak değiştirmelisiniz. Bunun yalnız Windows üzerinde etkili olduğunu