Re: [PATCH] kconfig: fix 'Save As' menu of xconfig

From: Masahiro Yamada
Date: Mon May 06 2019 - 23:03:28 EST

On Tue, May 7, 2019 at 4:10 AM Robert Gadsdon <rhgadsdon@xxxxxxxxx> wrote:
> On 03/10/2019 09:13 AM, Masahiro Yamada wrote:
> > The 'Save As' menu of xconfig is not working; it always saves the
> > kernel configuration into the default file irrespective of the file
> > chosen in the dialog box.
> >
> > The 'Save' menu always writes into the default file, but it would
> > make more sense to write into the file previously chosen by 'Load'
> > or 'Save As'.
> >
> > Signed-off-by: Masahiro Yamada<yamada.masahiro@xxxxxxxxxxxxx>
> > ---
> The 'save as' may be used for out-of-tree kernel config saves, but the
> default 'save' should always save to the in-tree .config file, as before
> (and for the past 10+ years..) If the kernel config was loaded from an
> out-of-tree location, it now saves back to that out-of-tree location,
> which is useless for the kernel compile..

I think it is quite natural that
"save" overwrites the file being edited.

And, that is how the 'save' of menuconfig/nconfig works.

> I have always kept my hardware/system-specific kernel configs
> out-of-tree, and then applied them in-tree before compiling.
> Now, I have to use 'save as' and type in the entire in-tree path
> (/usr/src/linux-5.1/.config) each time, in order to apply the specific
> config to the kernel, ready for compilation.

It is easy to do it without using xconfig.

cp /your/custom/config .config

> Robert Gadsdon.

Best Regards
Masahiro Yamada