Skip to content

Commit 0152d5b

Browse files
committed
Convert README_AUTO_LIB into Markdown
1 parent 677c509 commit 0152d5b

File tree

1 file changed

+18
-19
lines changed

1 file changed

+18
-19
lines changed

README_AUTO_LIB renamed to README_AUTO_LIB.md

Lines changed: 18 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ cross-platform way to include external libraries.
1010
Any developers of Nginx modules are encouraged to use Auto Lib Core to handle library
1111
dependencies for their modules rather than writing their own custom handler from scratch.
1212

13-
Note : the latest version can be found at github.com/simpl/ngx_auto_lib
13+
Note : The latest version can be found at github.com/simplresty/ngx_auto_lib
1414

1515

1616
Information for end users
@@ -68,7 +68,7 @@ Specifying a path to find a library
6868
If the version of a library you wish to include is in any of the standard paths (e.g.
6969
/usr/local, /usr ...), you will not need to specify a path to include the library.
7070

71-
If you do wish to specify a specific path, in most cases just specifying
71+
If you do wish to specify a specific path, in most cases just specifying
7272
[PFX]=/path/to/library will be sufficient. e.g.
7373

7474
$ export MOZJS=/path/to/mozjs
@@ -106,8 +106,8 @@ searched.
106106
When searching under [PFX]_BASE no prefix is added to the search, but when searching under
107107
the directory that the Nginx source is located in, the prefix [pfx]- is automatically added.
108108

109-
Note : there is currently a minor bug (due to the implementation of the 'sort' command)
110-
means versions that include hyphens (e.g. 1.0.0-beta5) are checked before versions like
109+
Note : there is currently a minor bug (due to the implementation of the 'sort' command)
110+
means versions that include hyphens (e.g. 1.0.0-beta5) are checked before versions like
111111
1.0.0a. This will be fixed soon, and searching of -build folders before normal source ones
112112
will be added too.
113113

@@ -119,7 +119,7 @@ Shared or static?
119119
The default for most libraries is to look for shared libraries, though this can be overridden
120120
by the user by setting [PFX]_SHARED=NO.
121121

122-
In the near future the default action will be to look for shared libraries then to look
122+
In the near future the default action will be to look for shared libraries then to look
123123
for static libraries in each directory searched unless one of [PFX]_SHARED and/or
124124
[PFX]_STATIC = NO. If both are set to NO, then Auto Lib will not be used at all.
125125

@@ -154,16 +154,16 @@ How Auto Lib Core works
154154
-----------------------
155155

156156
Auto Lib Core works as an interface layer between the module and the auto/feature part of
157-
the Nginx source. This is the file that results in the 'checking for ...' lines that you
157+
the Nginx source. This is the file that results in the 'checking for ...' lines that you
158158
see when you call ./configure.
159159

160160
auto/feature works by using a few key variables (see below) to generate some C code, trying
161161
to compile it to see if it works and optionally running the code. This output file is called
162162
autotest.c (located under the objs/ directory whilst configure is running, but is deleted
163163
after each call to auto/feature).
164164

165-
Normally, whenever an external library is required, a module developer will write a number
166-
of calls to auto/feature manually in their config files - e.g. to check under a range of
165+
Normally, whenever an external library is required, a module developer will write a number
166+
of calls to auto/feature manually in their config files - e.g. to check under a range of
167167
different possible locations to find a library. Apart from being tedious, this is obviously
168168
potentially error-prone.
169169

@@ -180,7 +180,7 @@ Option 1 :
180180
located
181181
- add the following line to your config file
182182

183-
. $ngx_addon_dir/ngx_auto_lib_core
183+
. $ngx_addon_dir/ngx_auto_lib_core
184184

185185
NOTE : if you want to include the file in a different directory to your config
186186
file, you will need to change both the include line in your config file AND
@@ -189,7 +189,7 @@ has $ngx_addon_dir/ngx_auto_lib_core in it)
189189

190190
Option 2 :
191191

192-
- make the Nginx Development Kit (github.com/simpl-it/ngx_devel_kit) a dependency
192+
- make the Nginx Development Kit (github.com/simpl-it/ngx_devel_kit) a dependency
193193
for your module (Auto Lib Core is included automatically with it)
194194

195195

@@ -229,10 +229,10 @@ Calling ngx_auto_lib_init() and ngx_auto_lib_run()
229229

230230
You can pass either one or two variables to ngx_auto_lib_init(). The first is the name of
231231
the library as it will appear when running ./configure, the second is the prefix that is
232-
used for internal variables and looking for directory prefixes. If the second is not
232+
used for internal variables and looking for directory prefixes. If the second is not
233233
specified, it defaults to the first.
234234

235-
The init function resets all key variables and functions, so it must be called before
235+
The init function resets all key variables and functions, so it must be called before
236236
setting any other variables or functions that are to be used as hooks (see the notes below).
237237

238238
ngx_auto_lib_run() should be called in the config files after all the variables and hooks
@@ -315,9 +315,9 @@ Hooks
315315

316316
To facilitate using Auto Lib Core in a flexible way, a number of 'hooks' have been
317317
placed in the testing cycle. These hooks are implemented as functions that you define
318-
in your config file which are called if required by the core library. In the core
318+
in your config file which are called if required by the core library. In the core
319319
library they are left as empty functions that return either 0 or 1. Any functions
320-
you write will
320+
you write will
321321

322322
Note : ngx_auto_lib_init() resets the variables and functions each time it is called, so
323323
you must DEFINE HOOKS AFTER YOU CALL ngx_auto_lib_init.
@@ -337,7 +337,7 @@ Although in most cases Auto Lib Core will be used where external libraries are
337337
definitely required (for a module to work), this may not always be the case. In the
338338
standard Nginx Auto Lib module (github.com/simpl-it/ngx_auto_lib) - which is designed
339339
to improve the inclusion of OpenSSL, PCRE and Zlib libraries and increase compilation
340-
speed where possible - the libraries are not always required, so checks are made to
340+
speed where possible - the libraries are not always required, so checks are made to
341341
see if it is necessary.
342342

343343

@@ -348,11 +348,11 @@ How Auto Lib Core checks if a library is required - ngx_auto_lib_check_require()
348348
- search for USE_[PFX]=YES (it is set to YES by default for most modules)
349349
- search for any external libraries that have been included in the CORE_LIBS or ADDON_LIBS
350350
variables that use the same lib name as any set in ngx_feature_lib_names
351-
- search for any macros that have been defined either in the CFLAGS variable or using
352-
auto/have or auto/define as set in the ngx_feature_check_macros_defined and
351+
- search for any macros that have been defined either in the CFLAGS variable or using
352+
auto/have or auto/define as set in the ngx_feature_check_macros_defined and
353353
ngx_feature_ngx_macros_non_zero variables
354354
- any custom checks implemented by creating an ngx_auto_lib_check hook function (which
355-
should return 0 if the library is required and return 1 at the end if the module is
355+
should return 0 if the library is required and return 1 at the end if the module is
356356
not required)
357357

358358

@@ -392,4 +392,3 @@ Copyright
392392
---------
393393

394394
Marcus Clyne (c) 2010 (http://simpl.it)
395-

0 commit comments

Comments
 (0)