Re: create-sbu_du-report.sh empty var

"Pierre Labastie" ([email protected] via alfs-discuss Mailing List) <[email protected]>
Newsgroups gmane.linux.lfs.automated
Message-ID <[email protected]>
On Thu, 2022-02-17 at 22:32 +0100, Thomas Seeling wrote:
> Hallo,
> 
> while examining the last LFS build report I noticed an error message for
> line 62:
> if jhalfs.config contains neither N_PARALLEL nor REALSBU the variable
> J_VALUE is not set to any value.
> I have attached my jhalfs.config using the latest jhalfs git version.
> My suggested fix is to set J_VALUE to a default value of 1
> unconditionally before checking for a higher value for -j.
> 
> create-sbu_du-report.sh: line 62: [: =: unary operator expected

Thanks for the report. I wrongly assumed that N_PARALLEL was always set, but of
course not if "Optimization and parallelization" is "n". And there are cases
where the create-sbu_du-report.sh script can be run without jhalfs.config at
all!
However, It think your fix wouldn't be enough in your use case, because the else
clause would be executed and reset J_VALUE to be empty.

I guess it is better to check a posteriori whether J_VALUE has a value...

Can you test that the change in commit 0f3b1c3 fixes your issue please?

Pierre

-- 
http://lists.linuxfromscratch.org/sympa/info/alfs-discuss
Unsubscribe: See the above information page
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.