Integrated: 8340075: Autoconf bundle cannot run on read-only filesystem

Erik Joelsson erikj at openjdk.org
Fri Sep 13 18:34:08 UTC 2024


On Thu, 12 Sep 2024 22:33:43 GMT, Erik Joelsson <erikj at openjdk.org> wrote:

> The autoconf launcher script in the autoconf bundle created by `make/devkit/createAutoconf.sh` currently writes a config file into the bundle installation dir every time it runs. This prevents it from functioning when installed on a read-only filesystem. We can work around the need for writing to this config file by instead adding a parameter to the command line sent to the actual autoconf executable.
> 
> This is what the script adds to the config file (with the $this_script_dir variable expanded):
> 
> begin-language: "M4sugar"
> args: --prepend-include $this_script_dir/usr/share/autoconf
> end-language: "M4sugar"
> 
> Looking at the original config file, it has several lines similar to this where the --prepend-include arg points to $PREFIX/usr/share/autoconf (where $PREFIX was specified at autoconf build time). Removing this addition from the config file causes autoconf to fail as it can't find m4sugar.m4 (which is located in $this_script_dir/usr/share/autoconf).
> 
> My proposed workaround, is to just add `--prepend-include $this_script_dir/usr/share/autoconf` as a command line option to the real autoconf script, which we call from the wrapper script. This would have the benefit of also fixing the other instances of this that are present in the config file, but that we aren't using in our configure script.
> 
> In addition to this, I made the script conform better to the current standard for these bundle creation scripts. The output should end up in a sub directory of `build`. No temp dirs should be used instead of the build dir. I also added some automation for setting the target platform tuple based on `uname` for the most common platforms, and added the ability to override for any others, without having to edit the file.

This pull request has now been integrated.

Changeset: 3aa8338f
Author:    Erik Joelsson <erikj at openjdk.org>
URL:       https://git.openjdk.org/jdk/commit/3aa8338f4e7d88967e77dfb0bace1c4b5add72f1
Stats:     55 lines in 1 file changed: 21 ins; 9 del; 25 mod

8340075: Autoconf bundle cannot run on read-only filesystem

Reviewed-by: mikael

-------------

PR: https://git.openjdk.org/jdk/pull/20978


More information about the build-dev mailing list