Hello, An implementation of the texi2any main program in C is almost done. To have the same features as the main program in Perl, a Perl interpreter is embedded. I wanted to be able to control if an embedded Perl interpreter is actually loaded with a command-line option. If --no-embed-interpreter the interpreter would not be loaded. However, since an interpreter is needed if there are Perl HTML customization initialization files, it means that the files should not be loaded before command-line options have been read.
Currently, in the Perl main program, the texi2any-config.pm file is loaded before command-line options are processed. Also, the init files specified on the command line with --init-file are loaded as soon as the command-line option is processed. So, if it appears before the --no-embed-interpreter option, the interpreter would already be loaded. To be able to know whether there is an interpreter or not, the init files loading could be postponed after all the command-line options have been read. Independentely of the issue of the interpreter, I think that it could be a good thing, even if it is less flexible, it also reduces the risks of surprises, if loading an init file do not have the same effect before or after an option is given on the command-line. This is only one of the possibility, another possibility could be to have --no-embed-interpreter ignored if an init file has already been loaded and the embedded interpreter is started and to have init files loading override the --no-embed-interpreter more generally, as it is inconsistent to want both no interpreter and to load init files. Yet another possibility would be to use an environment variable to disable the interpreter embedding such that it can be applied very early. Whatever option is chosen, I think that both main programs should behave the same. Any idea, preference? -- Pat