The unpac monorepo manager self-hosting as a monorepo using unpac
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge compilerlibs/Makefile.compilerlibs into the root Makefile

+401 -427
+3 -2
Changes
··· 382 382 383 383 ### Build system: 384 384 385 - - #12198, #12321: continue the merge of the sub-makefiles into the root Makefile 386 - started with #11243, #11248, #11268, #11420 and #11675. 385 + - #12198, #12321, #12586: continue the merge of the sub-makefiles 386 + into the root Makefile started with #11243, #11248, #11268, #11420 387 + and #11675. 387 388 (Sébastien Hinderer, review by David Allsopp and Florian Angeletti) 388 389 389 390 - #12569, #12570: remove 'otherlibraries' as a prerequisite for 'runtop';
+398 -3
Makefile
··· 60 60 61 61 expunge := expunge$(EXE) 62 62 63 - # targets for the compilerlibs/*.{cma,cmxa} archives 64 - include compilerlibs/Makefile.compilerlibs 63 + # Targets and dependencies for the compilerlibs/*.{cma,cmxa} archives 64 + 65 + utils_SOURCES = $(addprefix utils/, \ 66 + config.mli config.ml \ 67 + build_path_prefix_map.mli build_path_prefix_map.ml \ 68 + misc.mli misc.ml \ 69 + identifiable.mli identifiable.ml \ 70 + numbers.mli numbers.ml \ 71 + arg_helper.mli arg_helper.ml \ 72 + local_store.mli local_store.ml \ 73 + load_path.mli load_path.ml \ 74 + clflags.mli clflags.ml \ 75 + profile.mli profile.ml \ 76 + terminfo.mli terminfo.ml \ 77 + ccomp.mli ccomp.ml \ 78 + warnings.mli warnings.ml \ 79 + consistbl.mli consistbl.ml \ 80 + strongly_connected_components.mli strongly_connected_components.ml \ 81 + targetint.mli targetint.ml \ 82 + int_replace_polymorphic_compare.mli int_replace_polymorphic_compare.ml \ 83 + domainstate.mli domainstate.ml \ 84 + binutils.mli binutils.ml \ 85 + lazy_backtrack.mli lazy_backtrack.ml \ 86 + diffing.mli diffing.ml \ 87 + diffing_with_keys.mli diffing_with_keys.ml) 88 + 89 + parsing_SOURCES = $(addprefix parsing/, \ 90 + location.mli location.ml \ 91 + unit_info.mli unit_info.ml \ 92 + asttypes.mli \ 93 + longident.mli longident.ml \ 94 + parsetree.mli \ 95 + docstrings.mli docstrings.ml \ 96 + syntaxerr.mli syntaxerr.ml \ 97 + ast_helper.mli ast_helper.ml \ 98 + camlinternalMenhirLib.mli camlinternalMenhirLib.ml \ 99 + parser.mly \ 100 + lexer.mll \ 101 + pprintast.mli pprintast.ml \ 102 + parse.mli parse.ml \ 103 + printast.mli printast.ml \ 104 + ast_mapper.mli ast_mapper.ml \ 105 + ast_iterator.mli ast_iterator.ml \ 106 + attr_helper.mli attr_helper.ml \ 107 + builtin_attributes.mli builtin_attributes.ml \ 108 + ast_invariants.mli ast_invariants.ml \ 109 + depend.mli depend.ml) 110 + 111 + typing_SOURCES = \ 112 + typing/annot.mli \ 113 + typing/ident.mli typing/ident.ml \ 114 + typing/path.mli typing/path.ml \ 115 + typing/primitive.mli typing/primitive.ml \ 116 + typing/type_immediacy.mli typing/type_immediacy.ml \ 117 + typing/outcometree.mli \ 118 + typing/shape.mli typing/shape.ml \ 119 + typing/types.mli typing/types.ml \ 120 + typing/btype.mli typing/btype.ml \ 121 + typing/oprint.mli typing/oprint.ml \ 122 + typing/subst.mli typing/subst.ml \ 123 + typing/predef.mli typing/predef.ml \ 124 + typing/datarepr.mli typing/datarepr.ml \ 125 + file_formats/cmi_format.mli file_formats/cmi_format.ml \ 126 + typing/persistent_env.mli typing/persistent_env.ml \ 127 + typing/env.mli typing/env.ml \ 128 + typing/errortrace.mli typing/errortrace.ml \ 129 + typing/typedtree.mli typing/typedtree.ml \ 130 + typing/signature_group.mli typing/signature_group.ml \ 131 + typing/printtyped.mli typing/printtyped.ml \ 132 + typing/ctype.mli typing/ctype.ml \ 133 + typing/printtyp.mli typing/printtyp.ml \ 134 + typing/includeclass.mli typing/includeclass.ml \ 135 + typing/mtype.mli typing/mtype.ml \ 136 + typing/envaux.mli typing/envaux.ml \ 137 + typing/includecore.mli typing/includecore.ml \ 138 + typing/tast_iterator.mli typing/tast_iterator.ml \ 139 + typing/tast_mapper.mli typing/tast_mapper.ml \ 140 + typing/stypes.mli typing/stypes.ml \ 141 + file_formats/cmt_format.mli file_formats/cmt_format.ml \ 142 + typing/cmt2annot.mli typing/cmt2annot.ml \ 143 + typing/untypeast.mli typing/untypeast.ml \ 144 + typing/includemod.mli typing/includemod.ml \ 145 + typing/includemod_errorprinter.mli typing/includemod_errorprinter.ml \ 146 + typing/typetexp.mli typing/typetexp.ml \ 147 + typing/printpat.mli typing/printpat.ml \ 148 + typing/patterns.mli typing/patterns.ml \ 149 + typing/parmatch.mli typing/parmatch.ml \ 150 + typing/typedecl_properties.mli typing/typedecl_properties.ml \ 151 + typing/typedecl_variance.mli typing/typedecl_variance.ml \ 152 + typing/typedecl_unboxed.mli typing/typedecl_unboxed.ml \ 153 + typing/typedecl_immediacy.mli typing/typedecl_immediacy.ml \ 154 + typing/typedecl_separability.mli typing/typedecl_separability.ml \ 155 + typing/typeopt.mli typing/typeopt.ml \ 156 + typing/typedecl.mli typing/typedecl.ml \ 157 + typing/rec_check.mli typing/rec_check.ml \ 158 + typing/typecore.mli typing/typecore.ml \ 159 + typing/typeclass.mli typing/typeclass.ml \ 160 + typing/typemod.mli typing/typemod.ml 161 + 162 + lambda_SOURCES = $(addprefix lambda/, \ 163 + debuginfo.mli debuginfo.ml \ 164 + lambda.mli lambda.ml \ 165 + printlambda.mli printlambda.ml \ 166 + switch.mli switch.ml \ 167 + matching.mli matching.ml \ 168 + translobj.mli translobj.ml \ 169 + translattribute.mli translattribute.ml \ 170 + translprim.mli translprim.ml \ 171 + translcore.mli translcore.ml \ 172 + translclass.mli translclass.ml \ 173 + translmod.mli translmod.ml \ 174 + tmc.mli tmc.ml \ 175 + simplif.mli simplif.ml \ 176 + runtimedef.mli runtimedef.ml) 177 + 178 + comp_SOURCES = \ 179 + file_formats/cmo_format.mli \ 180 + file_formats/cmx_format.mli \ 181 + file_formats/cmxs_format.mli \ 182 + bytecomp/meta.mli bytecomp/meta.ml \ 183 + bytecomp/opcodes.mli bytecomp/opcodes.ml \ 184 + bytecomp/bytesections.mli bytecomp/bytesections.ml \ 185 + bytecomp/dll.mli bytecomp/dll.ml \ 186 + bytecomp/symtable.mli bytecomp/symtable.ml \ 187 + driver/pparse.mli driver/pparse.ml \ 188 + driver/compenv.mli driver/compenv.ml \ 189 + driver/main_args.mli driver/main_args.ml \ 190 + driver/compmisc.mli driver/compmisc.ml \ 191 + driver/makedepend.mli driver/makedepend.ml \ 192 + driver/compile_common.mli driver/compile_common.ml 193 + # All file format descriptions (including cmx{,s}) are in the 194 + # ocamlcommon library so that ocamlobjinfo can depend on them. 195 + 196 + ocamlcommon_SOURCES = \ 197 + $(utils_SOURCES) $(parsing_SOURCES) $(typing_SOURCES) \ 198 + $(lambda_SOURCES) $(comp_SOURCES) 199 + 200 + ocamlbytecomp_SOURCES = \ 201 + bytecomp/instruct.mli bytecomp/instruct.ml \ 202 + bytecomp/bytegen.mli bytecomp/bytegen.ml \ 203 + bytecomp/printinstr.mli bytecomp/printinstr.ml \ 204 + bytecomp/emitcode.mli bytecomp/emitcode.ml \ 205 + bytecomp/bytelink.mli bytecomp/bytelink.ml \ 206 + bytecomp/bytelibrarian.mli bytecomp/bytelibrarian.ml \ 207 + bytecomp/bytepackager.mli bytecomp/bytepackager.ml \ 208 + driver/errors.mli driver/errors.ml \ 209 + driver/compile.mli driver/compile.ml \ 210 + driver/maindriver.mli driver/maindriver.ml 211 + 212 + intel_SOURCES = \ 213 + x86_ast.mli \ 214 + x86_proc.mli x86_proc.ml \ 215 + x86_dsl.mli x86_dsl.ml \ 216 + x86_gas.mli x86_gas.ml \ 217 + x86_masm.mli x86_masm.ml 218 + 219 + asmcomp_SOURCES = \ 220 + $(addprefix asmcomp/, $(arch_specific_SOURCES)) \ 221 + asmcomp/arch.mli asmcomp/arch.ml \ 222 + asmcomp/cmm.mli asmcomp/cmm.ml \ 223 + asmcomp/printcmm.mli asmcomp/printcmm.ml \ 224 + asmcomp/reg.mli asmcomp/reg.ml \ 225 + asmcomp/mach.mli asmcomp/mach.ml \ 226 + asmcomp/proc.mli asmcomp/proc.ml \ 227 + asmcomp/strmatch.mli asmcomp/strmatch.ml \ 228 + asmcomp/cmmgen_state.mli asmcomp/cmmgen_state.ml \ 229 + asmcomp/cmm_helpers.mli asmcomp/cmm_helpers.ml \ 230 + asmcomp/afl_instrument.mli asmcomp/afl_instrument.ml \ 231 + asmcomp/thread_sanitizer.mli asmcomp/thread_sanitizer.ml \ 232 + asmcomp/cmmgen.mli asmcomp/cmmgen.ml \ 233 + asmcomp/cmm_invariants.mli asmcomp/cmm_invariants.ml \ 234 + asmcomp/interval.mli asmcomp/interval.ml \ 235 + asmcomp/printmach.mli asmcomp/printmach.ml \ 236 + asmcomp/dataflow.mli asmcomp/dataflow.ml \ 237 + asmcomp/polling.mli asmcomp/polling.ml \ 238 + asmcomp/selectgen.mli asmcomp/selectgen.ml \ 239 + asmcomp/selection.mli asmcomp/selection.ml \ 240 + asmcomp/comballoc.mli asmcomp/comballoc.ml \ 241 + asmcomp/CSEgen.mli asmcomp/CSEgen.ml \ 242 + asmcomp/CSE.mli asmcomp/CSE.ml \ 243 + asmcomp/liveness.mli asmcomp/liveness.ml \ 244 + asmcomp/spill.mli asmcomp/spill.ml \ 245 + asmcomp/split.mli asmcomp/split.ml \ 246 + asmcomp/interf.mli asmcomp/interf.ml \ 247 + asmcomp/coloring.mli asmcomp/coloring.ml \ 248 + asmcomp/linscan.mli asmcomp/linscan.ml \ 249 + asmcomp/reloadgen.mli asmcomp/reloadgen.ml \ 250 + asmcomp/reload.mli asmcomp/reload.ml \ 251 + asmcomp/deadcode.mli asmcomp/deadcode.ml \ 252 + asmcomp/stackframegen.mli asmcomp/stackframegen.ml \ 253 + asmcomp/stackframe.mli asmcomp/stackframe.ml \ 254 + asmcomp/linear.mli asmcomp/linear.ml \ 255 + asmcomp/printlinear.mli asmcomp/printlinear.ml \ 256 + asmcomp/linearize.mli asmcomp/linearize.ml \ 257 + file_formats/linear_format.mli file_formats/linear_format.ml \ 258 + asmcomp/schedgen.mli asmcomp/schedgen.ml \ 259 + asmcomp/scheduling.mli asmcomp/scheduling.ml \ 260 + asmcomp/branch_relaxation.mli asmcomp/branch_relaxation.ml \ 261 + asmcomp/emitaux.mli asmcomp/emitaux.ml \ 262 + asmcomp/emit.mli asmcomp/emit.ml \ 263 + asmcomp/asmgen.mli asmcomp/asmgen.ml \ 264 + asmcomp/asmlink.mli asmcomp/asmlink.ml \ 265 + asmcomp/asmlibrarian.mli asmcomp/asmlibrarian.ml \ 266 + asmcomp/asmpackager.mli asmcomp/asmpackager.ml \ 267 + driver/opterrors.mli driver/opterrors.ml \ 268 + driver/optcompile.mli driver/optcompile.ml \ 269 + driver/optmaindriver.mli driver/optmaindriver.ml 270 + 271 + # Files under middle_end/ are not to reference files under asmcomp/. 272 + # This ensures that the middle end can be linked (e.g. for objinfo) even when 273 + # the native code compiler is not present for some particular target. 274 + 275 + middle_end_closure_SOURCES = $(addprefix middle_end/closure/, \ 276 + closure.mli closure.ml \ 277 + closure_middle_end.mli closure_middle_end.ml) 278 + 279 + # Owing to dependencies through [Compilenv], which would be 280 + # difficult to remove, some of the lower parts of Flambda (anything that is 281 + # saved in a .cmx file) have to be included in the [MIDDLE_END] stanza, below. 282 + middle_end_flambda_SOURCES = \ 283 + $(addprefix middle_end/flambda/, \ 284 + import_approx.mli import_approx.ml \ 285 + lift_code.mli lift_code.ml \ 286 + closure_conversion_aux.mli closure_conversion_aux.ml \ 287 + closure_conversion.mli closure_conversion.ml \ 288 + initialize_symbol_to_let_symbol.mli initialize_symbol_to_let_symbol.ml \ 289 + lift_let_to_initialize_symbol.mli lift_let_to_initialize_symbol.ml \ 290 + find_recursive_functions.mli find_recursive_functions.ml \ 291 + invariant_params.mli invariant_params.ml \ 292 + inconstant_idents.mli inconstant_idents.ml \ 293 + alias_analysis.mli alias_analysis.ml \ 294 + lift_constants.mli lift_constants.ml \ 295 + share_constants.mli share_constants.ml \ 296 + simplify_common.mli simplify_common.ml \ 297 + remove_unused_arguments.mli remove_unused_arguments.ml \ 298 + remove_unused_closure_vars.mli remove_unused_closure_vars.ml \ 299 + remove_unused_program_constructs.mli remove_unused_program_constructs.ml \ 300 + simplify_boxed_integer_ops.mli simplify_boxed_integer_ops.ml \ 301 + simplify_primitives.mli simplify_primitives.ml \ 302 + inlining_stats_types.mli inlining_stats_types.ml \ 303 + inlining_stats.mli inlining_stats.ml \ 304 + inline_and_simplify_aux.mli inline_and_simplify_aux.ml \ 305 + inlining_decision_intf.mli \ 306 + remove_free_vars_equal_to_args.mli remove_free_vars_equal_to_args.ml \ 307 + extract_projections.mli extract_projections.ml \ 308 + augment_specialised_args.mli augment_specialised_args.ml \ 309 + unbox_free_vars_of_closures.mli unbox_free_vars_of_closures.ml \ 310 + unbox_specialised_args.mli unbox_specialised_args.ml \ 311 + unbox_closures.mli unbox_closures.ml \ 312 + inlining_transforms.mli inlining_transforms.ml \ 313 + inlining_decision.mli inlining_decision.ml \ 314 + inline_and_simplify.mli inline_and_simplify.ml \ 315 + ref_to_variables.mli ref_to_variables.ml \ 316 + flambda_invariants.mli flambda_invariants.ml \ 317 + traverse_for_exported_symbols.mli traverse_for_exported_symbols.ml \ 318 + build_export_info.mli build_export_info.ml \ 319 + closure_offsets.mli closure_offsets.ml \ 320 + un_anf.mli un_anf.ml \ 321 + flambda_to_clambda.mli flambda_to_clambda.ml \ 322 + flambda_middle_end.mli flambda_middle_end.ml \ 323 + simplify_boxed_integer_ops_intf.mli) 324 + 325 + ocamlmiddleend_SOURCES = \ 326 + $(addprefix middle_end/, \ 327 + internal_variable_names.mli internal_variable_names.ml \ 328 + linkage_name.mli linkage_name.ml \ 329 + compilation_unit.mli compilation_unit.ml \ 330 + variable.mli variable.ml \ 331 + $(addprefix flambda/base_types/, \ 332 + closure_element.mli closure_element.ml \ 333 + closure_id.mli closure_id.ml) \ 334 + symbol.mli symbol.ml \ 335 + backend_var.mli backend_var.ml \ 336 + clambda_primitives.mli clambda_primitives.ml \ 337 + printclambda_primitives.mli printclambda_primitives.ml \ 338 + clambda.mli clambda.ml \ 339 + printclambda.mli printclambda.ml \ 340 + semantics_of_primitives.mli semantics_of_primitives.ml \ 341 + convert_primitives.mli convert_primitives.ml \ 342 + $(addprefix flambda/, \ 343 + $(addprefix base_types/, \ 344 + id_types.mli id_types.ml \ 345 + export_id.mli export_id.ml \ 346 + tag.mli tag.ml \ 347 + mutable_variable.mli mutable_variable.ml \ 348 + set_of_closures_id.mli set_of_closures_id.ml \ 349 + set_of_closures_origin.mli set_of_closures_origin.ml \ 350 + closure_origin.mli closure_origin.ml \ 351 + var_within_closure.mli var_within_closure.ml \ 352 + static_exception.mli static_exception.ml) \ 353 + pass_wrapper.mli pass_wrapper.ml \ 354 + allocated_const.mli allocated_const.ml \ 355 + parameter.mli parameter.ml \ 356 + projection.mli projection.ml \ 357 + flambda.mli flambda.ml \ 358 + flambda_iterators.mli flambda_iterators.ml \ 359 + flambda_utils.mli flambda_utils.ml \ 360 + freshening.mli freshening.ml \ 361 + effect_analysis.mli effect_analysis.ml \ 362 + inlining_cost.mli inlining_cost.ml \ 363 + simple_value_approx.mli simple_value_approx.ml \ 364 + export_info.mli export_info.ml \ 365 + export_info_for_pack.mli export_info_for_pack.ml) \ 366 + compilenv.mli compilenv.ml \ 367 + backend_intf.mli) \ 368 + $(middle_end_closure_SOURCES) \ 369 + $(middle_end_flambda_SOURCES) 370 + 371 + ocamloptcomp_SOURCES = $(ocamlmiddleend_SOURCES) $(asmcomp_SOURCES) 372 + 373 + ocamltoplevel_SOURCES = $(addprefix toplevel/, \ 374 + genprintval.mli genprintval.ml \ 375 + topcommon.mli topcommon.ml \ 376 + native/tophooks.mli native/tophooks.ml \ 377 + byte/topeval.mli byte/topeval.ml \ 378 + native/topeval.mli native/topeval.ml \ 379 + byte/trace.mli byte/trace.ml \ 380 + native/trace.mli native/trace.ml \ 381 + toploop.mli toploop.ml \ 382 + topprinters.mli topprinters.ml \ 383 + topdirs.mli topdirs.ml \ 384 + byte/topmain.mli byte/topmain.ml \ 385 + native/topmain.mli native/topmain.ml) 386 + 387 + TOPLEVEL_SHARED_MLIS = topeval.mli trace.mli topmain.mli 388 + TOPLEVEL_SHARED_CMIS = $(TOPLEVEL_SHARED_MLIS:%.mli=%.cmi) 389 + TOPLEVEL_SHARED_ARTEFACTS = $(TOPLEVEL_SHARED_MLIS) $(TOPLEVEL_SHARED_CMIS) 390 + 391 + $(addprefix toplevel/byte/, $(TOPLEVEL_SHARED_CMIS)):\ 392 + toplevel/byte/%.cmi: toplevel/%.cmi 393 + cp $< toplevel/$*.mli $(@D) 394 + 395 + $(addprefix toplevel/native/, $(TOPLEVEL_SHARED_CMIS)):\ 396 + toplevel/native/%.cmi: toplevel/%.cmi 397 + cp $< toplevel/$*.mli $(@D) 398 + 399 + beforedepend:: 400 + cd toplevel ; cp $(TOPLEVEL_SHARED_MLIS) byte/ 401 + cd toplevel ; cp $(TOPLEVEL_SHARED_MLIS) native/ 402 + 403 + partialclean:: 404 + cd toplevel/byte ; rm -f $(TOPLEVEL_SHARED_ARTEFACTS) 405 + cd toplevel/native ; rm -f $(TOPLEVEL_SHARED_ARTEFACTS) 406 + 407 + ALL_CONFIG_CMO = utils/config_main.cmo utils/config_boot.cmo 408 + 409 + utils/config_%.mli: utils/config.mli 410 + cp $^ $@ 411 + 412 + beforedepend:: utils/config_main.mli utils/config_boot.mli 413 + 414 + $(addprefix compilerlibs/ocamlcommon., cma cmxa): \ 415 + OC_OCAML_COMMON_LDFLAGS = += -linkall 416 + 417 + partialclean:: 418 + rm -f compilerlibs/ocamlcommon.cma 419 + 420 + partialclean:: 421 + rm -f compilerlibs/ocamlcommon.cmxa \ 422 + compilerlibs/ocamlcommon.a compilerlibs/ocamlcommon.lib 423 + 424 + 425 + partialclean:: 426 + rm -f compilerlibs/ocamlbytecomp.cma 427 + 428 + partialclean:: 429 + rm -f compilerlibs/ocamlbytecomp.cmxa \ 430 + compilerlibs/ocamlbytecomp.a compilerlibs/ocamlbytecomp.lib 431 + 432 + 433 + partialclean:: 434 + rm -f compilerlibs/ocamlmiddleend.cma \ 435 + compilerlibs/ocamlmiddleend.cmxa \ 436 + compilerlibs/ocamlmiddleend.a \ 437 + compilerlibs/ocamlmiddleend.lib 438 + 439 + 440 + partialclean:: 441 + rm -f compilerlibs/ocamloptcomp.cma 442 + 443 + partialclean:: 444 + rm -f compilerlibs/ocamloptcomp.cmxa \ 445 + compilerlibs/ocamloptcomp.a compilerlibs/ocamloptcomp.lib 446 + 447 + 448 + compilerlibs/ocamltoplevel.cma: VPATH += toplevel/byte 449 + partialclean:: 450 + rm -f compilerlibs/ocamltoplevel.cma 451 + 452 + compilerlibs/ocamltoplevel.cmxa: VPATH += toplevel/native 453 + partialclean:: 454 + rm -f compilerlibs/ocamltoplevel.cmxa \ 455 + compilerlibs/ocamltoplevel.a compilerlibs/ocamltoplevel.lib 65 456 66 457 # The configuration file 67 458 ··· 182 573 $(COMPILERLIBS:=.cma): \ 183 574 CAMLC = $(BOOT_OCAMLC) $(BOOT_STDLIBFLAGS) -use-prims runtime/primitives 184 575 185 - # FIXME: how about making another target depend on $(ALL_CONFIG_CMO)? 576 + # The following dependency ensures that the two versions of the 577 + # configuration module (the one for the bootstrap compiler and the 578 + # one for the compiler to be installed) are compiled. This is to make 579 + # sure these two versions remain in sync with each other 580 + 186 581 compilerlibs/ocamlcommon.cma: $(ALL_CONFIG_CMO) 187 582 188 583 OCAML_LIBRARIES = $(COMPILERLIBS)
-422
compilerlibs/Makefile.compilerlibs
··· 1 - #************************************************************************** 2 - #* * 3 - #* OCaml * 4 - #* * 5 - #* Xavier Leroy, projet Cristal, INRIA Rocquencourt * 6 - #* * 7 - #* Copyright 1999 Institut National de Recherche en Informatique et * 8 - #* en Automatique. * 9 - #* * 10 - #* All rights reserved. This file is distributed under the terms of * 11 - #* the GNU Lesser General Public License version 2.1, with the * 12 - #* special exception on linking described in the file LICENSE. * 13 - #* * 14 - #************************************************************************** 15 - 16 - # Targets and dependencies for compilerlibs archives 17 - 18 - # This file is meant to be included from the root Makefile, not to be 19 - # executed directly (this is why it is not simply named Makefile). 20 - 21 - utils_SOURCES = $(addprefix utils/, \ 22 - config.mli config.ml \ 23 - build_path_prefix_map.mli build_path_prefix_map.ml \ 24 - misc.mli misc.ml \ 25 - identifiable.mli identifiable.ml \ 26 - numbers.mli numbers.ml \ 27 - arg_helper.mli arg_helper.ml \ 28 - local_store.mli local_store.ml \ 29 - load_path.mli load_path.ml \ 30 - clflags.mli clflags.ml \ 31 - profile.mli profile.ml \ 32 - terminfo.mli terminfo.ml \ 33 - ccomp.mli ccomp.ml \ 34 - warnings.mli warnings.ml \ 35 - consistbl.mli consistbl.ml \ 36 - strongly_connected_components.mli strongly_connected_components.ml \ 37 - targetint.mli targetint.ml \ 38 - int_replace_polymorphic_compare.mli int_replace_polymorphic_compare.ml \ 39 - domainstate.mli domainstate.ml \ 40 - binutils.mli binutils.ml \ 41 - lazy_backtrack.mli lazy_backtrack.ml \ 42 - diffing.mli diffing.ml \ 43 - diffing_with_keys.mli diffing_with_keys.ml) 44 - 45 - parsing_SOURCES = $(addprefix parsing/, \ 46 - location.mli location.ml \ 47 - unit_info.mli unit_info.ml \ 48 - asttypes.mli \ 49 - longident.mli longident.ml \ 50 - parsetree.mli \ 51 - docstrings.mli docstrings.ml \ 52 - syntaxerr.mli syntaxerr.ml \ 53 - ast_helper.mli ast_helper.ml \ 54 - camlinternalMenhirLib.mli camlinternalMenhirLib.ml \ 55 - parser.mly \ 56 - lexer.mll \ 57 - pprintast.mli pprintast.ml \ 58 - parse.mli parse.ml \ 59 - printast.mli printast.ml \ 60 - ast_mapper.mli ast_mapper.ml \ 61 - ast_iterator.mli ast_iterator.ml \ 62 - attr_helper.mli attr_helper.ml \ 63 - builtin_attributes.mli builtin_attributes.ml \ 64 - ast_invariants.mli ast_invariants.ml \ 65 - depend.mli depend.ml) 66 - 67 - typing_SOURCES = \ 68 - $(addprefix typing/,\ 69 - annot.mli \ 70 - ident.mli ident.ml \ 71 - path.mli path.ml \ 72 - primitive.mli primitive.ml \ 73 - type_immediacy.mli type_immediacy.ml \ 74 - outcometree.mli \ 75 - shape.mli shape.ml \ 76 - types.mli types.ml \ 77 - btype.mli btype.ml \ 78 - oprint.mli oprint.ml \ 79 - subst.mli subst.ml \ 80 - predef.mli predef.ml \ 81 - datarepr.mli datarepr.ml) \ 82 - file_formats/cmi_format.mli file_formats/cmi_format.ml \ 83 - $(addprefix typing/, \ 84 - persistent_env.mli persistent_env.ml \ 85 - env.mli env.ml \ 86 - errortrace.mli errortrace.ml \ 87 - typedtree.mli typedtree.ml \ 88 - signature_group.mli signature_group.ml \ 89 - printtyped.mli printtyped.ml \ 90 - ctype.mli ctype.ml \ 91 - printtyp.mli printtyp.ml \ 92 - includeclass.mli includeclass.ml \ 93 - mtype.mli mtype.ml \ 94 - envaux.mli envaux.ml \ 95 - includecore.mli includecore.ml \ 96 - tast_iterator.mli tast_iterator.ml \ 97 - tast_mapper.mli tast_mapper.ml \ 98 - stypes.mli stypes.ml) \ 99 - file_formats/cmt_format.mli file_formats/cmt_format.ml \ 100 - $(addprefix typing/, \ 101 - cmt2annot.mli cmt2annot.ml \ 102 - untypeast.mli untypeast.ml \ 103 - includemod.mli includemod.ml \ 104 - includemod_errorprinter.mli includemod_errorprinter.ml \ 105 - typetexp.mli typetexp.ml \ 106 - printpat.mli printpat.ml \ 107 - patterns.mli patterns.ml \ 108 - parmatch.mli parmatch.ml \ 109 - typedecl_properties.mli typedecl_properties.ml \ 110 - typedecl_variance.mli typedecl_variance.ml \ 111 - typedecl_unboxed.mli typedecl_unboxed.ml \ 112 - typedecl_immediacy.mli typedecl_immediacy.ml \ 113 - typedecl_separability.mli typedecl_separability.ml \ 114 - typeopt.mli typeopt.ml \ 115 - typedecl.mli typedecl.ml \ 116 - rec_check.mli rec_check.ml \ 117 - typecore.mli typecore.ml \ 118 - typeclass.mli typeclass.ml \ 119 - typemod.mli typemod.ml) 120 - 121 - lambda_SOURCES = $(addprefix lambda/, \ 122 - debuginfo.mli debuginfo.ml \ 123 - lambda.mli lambda.ml \ 124 - printlambda.mli printlambda.ml \ 125 - switch.mli switch.ml \ 126 - matching.mli matching.ml \ 127 - translobj.mli translobj.ml \ 128 - translattribute.mli translattribute.ml \ 129 - translprim.mli translprim.ml \ 130 - translcore.mli translcore.ml \ 131 - translclass.mli translclass.ml \ 132 - translmod.mli translmod.ml \ 133 - tmc.mli tmc.ml \ 134 - simplif.mli simplif.ml \ 135 - runtimedef.mli runtimedef.ml) 136 - 137 - comp_SOURCES = \ 138 - $(addprefix file_formats/, \ 139 - cmo_format.mli \ 140 - cmx_format.mli \ 141 - cmxs_format.mli) \ 142 - $(addprefix bytecomp/, \ 143 - meta.mli meta.ml \ 144 - opcodes.mli opcodes.ml \ 145 - bytesections.mli bytesections.ml \ 146 - dll.mli dll.ml \ 147 - symtable.mli symtable.ml) \ 148 - $(addprefix driver/, \ 149 - pparse.mli pparse.ml \ 150 - compenv.mli compenv.ml \ 151 - main_args.mli main_args.ml \ 152 - compmisc.mli compmisc.ml \ 153 - makedepend.mli makedepend.ml \ 154 - compile_common.mli compile_common.ml) 155 - # All file format descriptions (including cmx{,s}) are in the 156 - # ocamlcommon library so that ocamlobjinfo can depend on them. 157 - 158 - ocamlcommon_SOURCES = \ 159 - $(utils_SOURCES) $(parsing_SOURCES) $(typing_SOURCES) \ 160 - $(lambda_SOURCES) $(comp_SOURCES) 161 - 162 - ocamlbytecomp_SOURCES = \ 163 - $(addprefix bytecomp/, \ 164 - instruct.mli instruct.ml \ 165 - bytegen.mli bytegen.ml \ 166 - printinstr.mli printinstr.ml \ 167 - emitcode.mli emitcode.ml \ 168 - bytelink.mli bytelink.ml \ 169 - bytelibrarian.mli bytelibrarian.ml \ 170 - bytepackager.mli bytepackager.ml) \ 171 - $(addprefix driver/, \ 172 - errors.mli errors.ml \ 173 - compile.mli compile.ml \ 174 - maindriver.mli maindriver.ml) 175 - 176 - intel_SOURCES = \ 177 - x86_ast.mli \ 178 - x86_proc.mli x86_proc.ml \ 179 - x86_dsl.mli x86_dsl.ml \ 180 - x86_gas.mli x86_gas.ml \ 181 - x86_masm.mli x86_masm.ml 182 - 183 - asmcomp_SOURCES = \ 184 - $(addprefix asmcomp/, \ 185 - $(arch_specific_SOURCES) \ 186 - arch.mli arch.ml \ 187 - cmm.mli cmm.ml \ 188 - printcmm.mli printcmm.ml \ 189 - reg.mli reg.ml \ 190 - mach.mli mach.ml \ 191 - proc.mli proc.ml \ 192 - strmatch.mli strmatch.ml \ 193 - cmmgen_state.mli cmmgen_state.ml \ 194 - cmm_helpers.mli cmm_helpers.ml \ 195 - afl_instrument.mli afl_instrument.ml \ 196 - thread_sanitizer.mli thread_sanitizer.ml \ 197 - cmmgen.mli cmmgen.ml \ 198 - cmm_invariants.mli cmm_invariants.ml \ 199 - interval.mli interval.ml \ 200 - printmach.mli printmach.ml \ 201 - dataflow.mli dataflow.ml \ 202 - polling.mli polling.ml \ 203 - selectgen.mli selectgen.ml \ 204 - selection.mli selection.ml \ 205 - comballoc.mli comballoc.ml \ 206 - CSEgen.mli CSEgen.ml \ 207 - CSE.mli CSE.ml \ 208 - liveness.mli liveness.ml \ 209 - spill.mli spill.ml \ 210 - split.mli split.ml \ 211 - interf.mli interf.ml \ 212 - coloring.mli coloring.ml \ 213 - linscan.mli linscan.ml \ 214 - reloadgen.mli reloadgen.ml \ 215 - reload.mli reload.ml \ 216 - deadcode.mli deadcode.ml \ 217 - stackframegen.mli stackframegen.ml \ 218 - stackframe.mli stackframe.ml \ 219 - linear.mli linear.ml \ 220 - printlinear.mli printlinear.ml \ 221 - linearize.mli linearize.ml) \ 222 - file_formats/linear_format.mli file_formats/linear_format.ml \ 223 - $(addprefix asmcomp/, \ 224 - schedgen.mli schedgen.ml \ 225 - scheduling.mli scheduling.ml \ 226 - branch_relaxation.mli branch_relaxation.ml \ 227 - emitaux.mli emitaux.ml \ 228 - emit.mli emit.ml \ 229 - asmgen.mli asmgen.ml \ 230 - asmlink.mli asmlink.ml \ 231 - asmlibrarian.mli asmlibrarian.ml \ 232 - asmpackager.mli asmpackager.ml) \ 233 - $(addprefix driver/, \ 234 - opterrors.mli opterrors.ml \ 235 - optcompile.mli optcompile.ml \ 236 - optmaindriver.mli optmaindriver.ml) 237 - 238 - # Files under middle_end/ are not to reference files under asmcomp/. 239 - # This ensures that the middle end can be linked (e.g. for objinfo) even when 240 - # the native code compiler is not present for some particular target. 241 - 242 - middle_end_closure_SOURCES = $(addprefix middle_end/closure/, \ 243 - closure.mli closure.ml \ 244 - closure_middle_end.mli closure_middle_end.ml) 245 - 246 - # Owing to dependencies through [Compilenv], which would be 247 - # difficult to remove, some of the lower parts of Flambda (anything that is 248 - # saved in a .cmx file) have to be included in the [MIDDLE_END] stanza, below. 249 - middle_end_flambda_SOURCES = \ 250 - $(addprefix middle_end/flambda/, \ 251 - import_approx.mli import_approx.ml \ 252 - lift_code.mli lift_code.ml \ 253 - closure_conversion_aux.mli closure_conversion_aux.ml \ 254 - closure_conversion.mli closure_conversion.ml \ 255 - initialize_symbol_to_let_symbol.mli initialize_symbol_to_let_symbol.ml \ 256 - lift_let_to_initialize_symbol.mli lift_let_to_initialize_symbol.ml \ 257 - find_recursive_functions.mli find_recursive_functions.ml \ 258 - invariant_params.mli invariant_params.ml \ 259 - inconstant_idents.mli inconstant_idents.ml \ 260 - alias_analysis.mli alias_analysis.ml \ 261 - lift_constants.mli lift_constants.ml \ 262 - share_constants.mli share_constants.ml \ 263 - simplify_common.mli simplify_common.ml \ 264 - remove_unused_arguments.mli remove_unused_arguments.ml \ 265 - remove_unused_closure_vars.mli remove_unused_closure_vars.ml \ 266 - remove_unused_program_constructs.mli remove_unused_program_constructs.ml \ 267 - simplify_boxed_integer_ops.mli simplify_boxed_integer_ops.ml \ 268 - simplify_primitives.mli simplify_primitives.ml \ 269 - inlining_stats_types.mli inlining_stats_types.ml \ 270 - inlining_stats.mli inlining_stats.ml \ 271 - inline_and_simplify_aux.mli inline_and_simplify_aux.ml \ 272 - inlining_decision_intf.mli \ 273 - remove_free_vars_equal_to_args.mli remove_free_vars_equal_to_args.ml \ 274 - extract_projections.mli extract_projections.ml \ 275 - augment_specialised_args.mli augment_specialised_args.ml \ 276 - unbox_free_vars_of_closures.mli unbox_free_vars_of_closures.ml \ 277 - unbox_specialised_args.mli unbox_specialised_args.ml \ 278 - unbox_closures.mli unbox_closures.ml \ 279 - inlining_transforms.mli inlining_transforms.ml \ 280 - inlining_decision.mli inlining_decision.ml \ 281 - inline_and_simplify.mli inline_and_simplify.ml \ 282 - ref_to_variables.mli ref_to_variables.ml \ 283 - flambda_invariants.mli flambda_invariants.ml \ 284 - traverse_for_exported_symbols.mli traverse_for_exported_symbols.ml \ 285 - build_export_info.mli build_export_info.ml \ 286 - closure_offsets.mli closure_offsets.ml \ 287 - un_anf.mli un_anf.ml \ 288 - flambda_to_clambda.mli flambda_to_clambda.ml \ 289 - flambda_middle_end.mli flambda_middle_end.ml \ 290 - simplify_boxed_integer_ops_intf.mli) 291 - 292 - ocamlmiddleend_SOURCES = \ 293 - $(addprefix middle_end/, \ 294 - internal_variable_names.mli internal_variable_names.ml \ 295 - linkage_name.mli linkage_name.ml \ 296 - compilation_unit.mli compilation_unit.ml \ 297 - variable.mli variable.ml \ 298 - $(addprefix flambda/base_types/, \ 299 - closure_element.mli closure_element.ml \ 300 - closure_id.mli closure_id.ml) \ 301 - symbol.mli symbol.ml \ 302 - backend_var.mli backend_var.ml \ 303 - clambda_primitives.mli clambda_primitives.ml \ 304 - printclambda_primitives.mli printclambda_primitives.ml \ 305 - clambda.mli clambda.ml \ 306 - printclambda.mli printclambda.ml \ 307 - semantics_of_primitives.mli semantics_of_primitives.ml \ 308 - convert_primitives.mli convert_primitives.ml \ 309 - $(addprefix flambda/, \ 310 - $(addprefix base_types/, \ 311 - id_types.mli id_types.ml \ 312 - export_id.mli export_id.ml \ 313 - tag.mli tag.ml \ 314 - mutable_variable.mli mutable_variable.ml \ 315 - set_of_closures_id.mli set_of_closures_id.ml \ 316 - set_of_closures_origin.mli set_of_closures_origin.ml \ 317 - closure_origin.mli closure_origin.ml \ 318 - var_within_closure.mli var_within_closure.ml \ 319 - static_exception.mli static_exception.ml) \ 320 - pass_wrapper.mli pass_wrapper.ml \ 321 - allocated_const.mli allocated_const.ml \ 322 - parameter.mli parameter.ml \ 323 - projection.mli projection.ml \ 324 - flambda.mli flambda.ml \ 325 - flambda_iterators.mli flambda_iterators.ml \ 326 - flambda_utils.mli flambda_utils.ml \ 327 - freshening.mli freshening.ml \ 328 - effect_analysis.mli effect_analysis.ml \ 329 - inlining_cost.mli inlining_cost.ml \ 330 - simple_value_approx.mli simple_value_approx.ml \ 331 - export_info.mli export_info.ml \ 332 - export_info_for_pack.mli export_info_for_pack.ml) \ 333 - compilenv.mli compilenv.ml \ 334 - backend_intf.mli) \ 335 - $(middle_end_closure_SOURCES) \ 336 - $(middle_end_flambda_SOURCES) 337 - 338 - ocamloptcomp_SOURCES = $(ocamlmiddleend_SOURCES) $(asmcomp_SOURCES) 339 - 340 - ocamltoplevel_SOURCES = $(addprefix toplevel/, \ 341 - genprintval.mli genprintval.ml \ 342 - topcommon.mli topcommon.ml \ 343 - native/tophooks.mli native/tophooks.ml \ 344 - byte/topeval.mli byte/topeval.ml \ 345 - native/topeval.mli native/topeval.ml \ 346 - byte/trace.mli byte/trace.ml \ 347 - native/trace.mli native/trace.ml \ 348 - toploop.mli toploop.ml \ 349 - topprinters.mli topprinters.ml \ 350 - topdirs.mli topdirs.ml \ 351 - byte/topmain.mli byte/topmain.ml \ 352 - native/topmain.mli native/topmain.ml) 353 - 354 - TOPLEVEL_SHARED_MLIS = topeval.mli trace.mli topmain.mli 355 - TOPLEVEL_SHARED_CMIS = $(TOPLEVEL_SHARED_MLIS:%.mli=%.cmi) 356 - TOPLEVEL_SHARED_ARTEFACTS = $(TOPLEVEL_SHARED_MLIS) $(TOPLEVEL_SHARED_CMIS) 357 - 358 - $(addprefix toplevel/byte/, $(TOPLEVEL_SHARED_CMIS)):\ 359 - toplevel/byte/%.cmi: toplevel/%.cmi 360 - cp $< toplevel/$*.mli $(@D) 361 - 362 - $(addprefix toplevel/native/, $(TOPLEVEL_SHARED_CMIS)):\ 363 - toplevel/native/%.cmi: toplevel/%.cmi 364 - cp $< toplevel/$*.mli $(@D) 365 - 366 - beforedepend:: 367 - cd toplevel ; cp $(TOPLEVEL_SHARED_MLIS) byte/ 368 - cd toplevel ; cp $(TOPLEVEL_SHARED_MLIS) native/ 369 - 370 - partialclean:: 371 - cd toplevel/byte ; rm -f $(TOPLEVEL_SHARED_ARTEFACTS) 372 - cd toplevel/native ; rm -f $(TOPLEVEL_SHARED_ARTEFACTS) 373 - 374 - ALL_CONFIG_CMO = utils/config_main.cmo utils/config_boot.cmo 375 - 376 - utils/config_%.mli: utils/config.mli 377 - cp $^ $@ 378 - 379 - beforedepend:: utils/config_main.mli utils/config_boot.mli 380 - 381 - $(addprefix compilerlibs/ocamlcommon., cma cmxa): \ 382 - OC_OCAML_COMMON_LDFLAGS = += -linkall 383 - 384 - partialclean:: 385 - rm -f compilerlibs/ocamlcommon.cma 386 - 387 - partialclean:: 388 - rm -f compilerlibs/ocamlcommon.cmxa \ 389 - compilerlibs/ocamlcommon.a compilerlibs/ocamlcommon.lib 390 - 391 - 392 - partialclean:: 393 - rm -f compilerlibs/ocamlbytecomp.cma 394 - 395 - partialclean:: 396 - rm -f compilerlibs/ocamlbytecomp.cmxa \ 397 - compilerlibs/ocamlbytecomp.a compilerlibs/ocamlbytecomp.lib 398 - 399 - 400 - partialclean:: 401 - rm -f compilerlibs/ocamlmiddleend.cma \ 402 - compilerlibs/ocamlmiddleend.cmxa \ 403 - compilerlibs/ocamlmiddleend.a \ 404 - compilerlibs/ocamlmiddleend.lib 405 - 406 - 407 - partialclean:: 408 - rm -f compilerlibs/ocamloptcomp.cma 409 - 410 - partialclean:: 411 - rm -f compilerlibs/ocamloptcomp.cmxa \ 412 - compilerlibs/ocamloptcomp.a compilerlibs/ocamloptcomp.lib 413 - 414 - 415 - compilerlibs/ocamltoplevel.cma: VPATH += toplevel/byte 416 - partialclean:: 417 - rm -f compilerlibs/ocamltoplevel.cma 418 - 419 - compilerlibs/ocamltoplevel.cmxa: VPATH += toplevel/native 420 - partialclean:: 421 - rm -f compilerlibs/ocamltoplevel.cmxa \ 422 - compilerlibs/ocamltoplevel.a compilerlibs/ocamltoplevel.lib