Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Store local configuration in an external file, not in the compilers #6200

Closed
vicuna opened this issue Oct 2, 2013 · 5 comments
Closed

Store local configuration in an external file, not in the compilers #6200

vicuna opened this issue Oct 2, 2013 · 5 comments

Comments

@vicuna
Copy link

vicuna commented Oct 2, 2013

Original bug ID: 6200
Reporter: @alainfrisch
Status: acknowledged (set by @damiendoligez on 2014-06-04T20:09:49Z)
Resolution: open
Priority: normal
Severity: feature
Target version: later
Category: configure and build/install
Monitored by: @gasche @hcarty

Bug description

Some local configuration is stored directly in utils/config.ml (obtained from utils/config.mlp mostly by substituting variables from config/Makefile).

This is another point preventing the bootstrapping of ocamlc to be idempotent on various machines/working copies (see also #6199). Moreover, it makes it difficult to tweak those variables (for instance to use a different C compiler, or to change the standard_runtime path in order to relocate the toolchain in the filesystem).

Wouldn't it be better to keep all these variables in an external text file, parsed by ocamlc/ocamlopt? This file could be located (by default) in the same directory as the compiler itself (or at a fixed relative path from it), and an environment variable could be used to specify a different file. The overhead of reading this external file is probably small compared to the I/O operations required by the compiler (in particular, loading many .cmi files). (One problem could be that other tools linking against compilerlib would then also depend on this external file.)

@github-actions
Copy link

This issue has been open one year with no activity. Consequently, it is being marked with the "stale" label. What this means is that the issue will be automatically closed in 30 days unless more comments are added or the "stale" label is removed. Comments that provide new information on the issue are especially welcome: is it still reproducible? did it appear in other contexts? how critical is it? etc.

@github-actions github-actions bot added the Stale label May 15, 2020
@nojb
Copy link
Contributor

nojb commented May 15, 2020

I think this is still relevant.

@nojb nojb removed the Stale label May 15, 2020
@glondu
Copy link
Contributor

glondu commented Jul 31, 2020

One side-effect of storing the configuration in config.ml is that the approximations in config.cmx contain it, so changing it changes the compiler-libs ABI and therefore needs recompilation of all reverse dependencies, which is not always wanted (see #9800 for an example). The proposal here would "fix" that (compiling config.ml with -opaque and hiding config.cmx would also I guess).

@github-actions
Copy link

github-actions bot commented Aug 2, 2021

This issue has been open one year with no activity. Consequently, it is being marked with the "stale" label. What this means is that the issue will be automatically closed in 30 days unless more comments are added or the "stale" label is removed. Comments that provide new information on the issue are especially welcome: is it still reproducible? did it appear in other contexts? how critical is it? etc.

@github-actions github-actions bot added the Stale label Aug 2, 2021
@nojb nojb removed the Stale label Aug 2, 2021
@github-actions
Copy link

github-actions bot commented Aug 5, 2022

This issue has been open one year with no activity. Consequently, it is being marked with the "stale" label. What this means is that the issue will be automatically closed in 30 days unless more comments are added or the "stale" label is removed. Comments that provide new information on the issue are especially welcome: is it still reproducible? did it appear in other contexts? how critical is it? etc.

@github-actions github-actions bot added the Stale label Aug 5, 2022
@github-actions github-actions bot closed this as completed Oct 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants