1Config(3) OCaml library Config(3)
2
3
4
6 Config - System configuration
7
9 Module Config
10
12 Module Config
13 : sig end
14
15
16 System configuration
17
18 Warning: this module is unstable and part of Compiler_libs .
19
20
21
22
23
24
25 val version : string
26
27 The current version number of the system
28
29
30
31 val standard_library : string
32
33 The directory containing the standard libraries
34
35
36
37 val ccomp_type : string
38
39 The "kind" of the C compiler, assembler and linker used: one of "cc"
40 (for Unix-style C compilers) "msvc" (for Microsoft Visual C++ and MASM)
41
42
43
44 val c_compiler : string
45
46 The compiler to use for compiling C files
47
48
49
50 val c_output_obj : string
51
52 Name of the option of the C compiler for specifying the output file
53
54
55
56 val c_has_debug_prefix_map : bool
57
58 Whether the C compiler supports -fdebug-prefix-map
59
60
61
62 val as_has_debug_prefix_map : bool
63
64 Whether the assembler supports --debug-prefix-map
65
66
67
68 val ocamlc_cflags : string
69
70 The flags ocamlc should pass to the C compiler
71
72
73
74 val ocamlc_cppflags : string
75
76 The flags ocamlc should pass to the C preprocessor
77
78
79
80 val ocamlopt_cflags : string
81
82 Deprecated.
83
84 Config.ocamlc_cflags should be used instead. The flags ocamlopt should
85 pass to the C compiler
86
87
88
89 val ocamlopt_cppflags : string
90
91 Deprecated.
92
93 Config.ocamlc_cppflags should be used instead. The flags ocamlopt
94 should pass to the C preprocessor
95
96
97
98 val bytecomp_c_libraries : string
99
100 The C libraries to link with custom runtimes
101
102
103
104 val native_c_libraries : string
105
106 The C libraries to link with native-code programs
107
108
109
110 val native_pack_linker : string
111
112 The linker to use for packaging (ocamlopt -pack) and for partial links
113 (ocamlopt -output-obj).
114
115
116
117 val mkdll : string
118
119 The linker command line to build dynamic libraries.
120
121
122
123 val mkexe : string
124
125 The linker command line to build executables.
126
127
128
129 val mkmaindll : string
130
131 The linker command line to build main programs as dlls.
132
133
134
135 val ranlib : string
136
137 Command to randomize a library, or "" if not needed
138
139
140
141 val ar : string
142
143 Name of the ar command, or "" if not needed (MSVC)
144
145
146
147 val interface_suffix : string ref
148
149 Suffix for interface file names
150
151
152
153 val exec_magic_number : string
154
155 Magic number for bytecode executable files
156
157
158
159 val cmi_magic_number : string
160
161 Magic number for compiled interface files
162
163
164
165 val cmo_magic_number : string
166
167 Magic number for object bytecode files
168
169
170
171 val cma_magic_number : string
172
173 Magic number for archive files
174
175
176
177 val cmx_magic_number : string
178
179 Magic number for compilation unit descriptions
180
181
182
183 val cmxa_magic_number : string
184
185 Magic number for libraries of compilation unit descriptions
186
187
188
189 val ast_intf_magic_number : string
190
191 Magic number for file holding an interface syntax tree
192
193
194
195 val ast_impl_magic_number : string
196
197 Magic number for file holding an implementation syntax tree
198
199
200
201 val cmxs_magic_number : string
202
203 Magic number for dynamically-loadable plugins
204
205
206
207 val cmt_magic_number : string
208
209 Magic number for compiled interface files
210
211
212
213 val linear_magic_number : string
214
215 Magic number for Linear internal representation files
216
217
218
219 val max_tag : int
220
221 Biggest tag that can be stored in the header of a regular block.
222
223
224
225 val lazy_tag : int
226
227 Normally the same as Obj.lazy_tag. Separate definition because of
228 technical reasons for bootstrapping.
229
230
231
232 val max_young_wosize : int
233
234 Maximal size of arrays that are directly allocated in the minor heap
235
236
237
238 val stack_threshold : int
239
240 Size in words of safe area at bottom of VM stack, see runtime/caml/con‐
241 fig.h
242
243
244
245 val stack_safety_margin : int
246
247 Size in words of the safety margin between the bottom of the stack and
248 the stack pointer. This margin can be used by intermediate computations
249 of some instructions, or the event handler.
250
251
252
253 val architecture : string
254
255 Name of processor type for the native-code compiler
256
257
258
259 val model : string
260
261 Name of processor submodel for the native-code compiler
262
263
264
265 val system : string
266
267 Name of operating system for the native-code compiler
268
269
270
271 val asm : string
272
273 The assembler (and flags) to use for assembling ocamlopt-generated
274 code.
275
276
277
278 val asm_cfi_supported : bool
279
280 Whether assembler understands CFI directives
281
282
283
284 val with_frame_pointers : bool
285
286 Whether assembler should maintain frame pointers
287
288
289
290 val ext_obj : string
291
292 Extension for object files, e.g. .o under Unix.
293
294
295
296 val ext_asm : string
297
298 Extension for assembler files, e.g. .s under Unix.
299
300
301
302 val ext_lib : string
303
304 Extension for library files, e.g. .a under Unix.
305
306
307
308 val ext_dll : string
309
310 Extension for dynamically-loaded libraries, e.g. .so under Unix.
311
312
313
314 val ext_exe : string
315
316 Extension for executable programs, e.g. .exe under Windows.
317
318
319 Since 4.12.0
320
321
322
323 val default_executable_name : string
324
325 Name of executable produced by linking if none is given with -o, e.g.
326 a.out under Unix.
327
328
329
330 val systhread_supported : bool
331
332 Whether the system thread library is implemented
333
334
335
336 val flexdll_dirs : string list
337
338 Directories needed for the FlexDLL objects
339
340
341
342 val host : string
343
344 Whether the compiler is a cross-compiler
345
346
347
348 val target : string
349
350 Whether the compiler is a cross-compiler
351
352
353
354 val flambda : bool
355
356 Whether the compiler was configured for flambda
357
358
359
360 val with_flambda_invariants : bool
361
362 Whether the invariants checks for flambda are enabled
363
364
365
366 val profinfo : bool
367
368 Whether the compiler was configured for profiling
369
370
371
372 val profinfo_width : int
373
374 How many bits are to be used in values' headers for profiling informa‐
375 tion
376
377
378
379 val safe_string : bool
380
381 Whether the compiler was configured with -force-safe-string; in that
382 case, the -unsafe-string compile-time option is unavailable
383
384
385 Since 4.05.0
386
387
388
389 val default_safe_string : bool
390
391 Whether the compiler was configured to use the -safe-string or -un‐
392 safe-string compile-time option by default.
393
394
395 Since 4.06.0
396
397
398
399 val flat_float_array : bool
400
401 Whether the compiler and runtime automagically flatten float arrays
402
403
404
405 val function_sections : bool
406
407 Whether the compiler was configured to generate each function in a sep‐
408 arate section
409
410
411
412 val windows_unicode : bool
413
414 Whether Windows Unicode runtime is enabled
415
416
417
418 val supports_shared_libraries : bool
419
420 Whether shared libraries are supported
421
422
423 Since 4.08.0
424
425
426
427 val afl_instrument : bool
428
429 Whether afl-fuzz instrumentation is generated by default
430
431
432
433 val print_config : out_channel -> unit
434
435 Access to configuration values
436
437
438
439 val config_var : string -> string option
440
441 the configuration value of a variable, if it exists
442
443
444
445
446
447OCamldoc 2021-07-22 Config(3)