Skip to content

Conversation

@Karlson2k
Copy link
Contributor

A set of random configure (and autotools) fixes and improvements.
As requested here.

@alejandro-colomar
Copy link
Collaborator

alejandro-colomar commented Jul 13, 2025

In general, please expand the information in the commit messages. I'd like to be able to read those a year from now and remember why we did what we did. Consider that the readers of those commit messages (especially myself) may have almost no clue of autotools.

@Karlson2k
Copy link
Contributor Author

OK, I need to finish some clean-ups and I'll update this PR.

@lslebodn
Copy link

OK, I need to finish some clean-ups and I'll update this PR.

which cleanup do you mean?
Is is something about inconsistency with using AS_IF vs manual if/then/fi blocks?

Maybe it would be better to create follow up changes in different PR

@Karlson2k
Copy link
Contributor Author

Karlson2k commented Jul 16, 2025

OK, I need to finish some clean-ups and I'll update this PR.

which cleanup do you mean? Is is something about inconsistency with using AS_IF vs manual if/then/fi blocks?

No, this is requested here cleanup of unused LIYESCRYPT.
Also I need to integrate Reviewed-by: Alejandro Colomar <alx@kernel.org> marks

Maybe it would be better to create follow up changes in different PR

This would be nice.
Also AS_CASE could be used instead of case esac. And AS_VAR_IF may simplify the code and the readability.
But all these things should go to another PR.

@Karlson2k Karlson2k force-pushed the configure-fixes-01 branch from efe5dbf to 4795354 Compare July 17, 2025 19:41
@Karlson2k
Copy link
Contributor Author

@alejandro-colomar Adjusted as requested.

@Karlson2k Karlson2k marked this pull request as draft July 17, 2025 19:49
@Karlson2k Karlson2k force-pushed the configure-fixes-01 branch from 4795354 to 81e5f7d Compare July 17, 2025 20:25
@Karlson2k Karlson2k marked this pull request as ready for review July 17, 2025 20:25
@alejandro-colomar
Copy link
Collaborator

Please use two spaces after period in commit messages. One space is wrong.

See https://web.archive.org/web/20171217060354/http://www.heracliteanriver.com/?p=324.

Lines were incorrectly added by 5cd04d0
The check is fully duplicated and does nothing except setting wrong
variable LIYESCRYPT.  Such variable was never used in the project.

Signed-off-by: Evgeny Grin (Karlson2k) <k2k@drgrin.dev>
AM_CONDITIONAL() must not be used in shell's if branches.  Instead it
must be specified one time only (per conditional variable) with test
"something" as a second parameter.
See https://www.gnu.org/software/automake/manual/html_node/Usage-of-Conditionals.html#index-AM_005fCONDITIONAL-2

Signed-off-by: Evgeny Grin (Karlson2k) <k2k@drgrin.dev>
Reviewed-by: Alejandro Colomar <alx@kernel.org>
@Karlson2k Karlson2k force-pushed the configure-fixes-01 branch from 81e5f7d to bdee4d3 Compare July 18, 2025 09:46
Always quoting of all arguments is recommended by autoconf manual.

The commit is checked by autoreconf -v before and after commit.
Resulting configure is identical (excluding some newlines).

Signed-off-by: Evgeny Grin (Karlson2k) <k2k@drgrin.dev>
AC_ARG_ENABLE() expands to nothing where it is used, but adds arguments
parsing, help message and other related things.
It does not make any sense to put this macro into if branch.  It may
also confuse the reader.

Signed-off-by: Evgeny Grin (Karlson2k) <k2k@drgrin.dev>
@Karlson2k Karlson2k force-pushed the configure-fixes-01 branch from bdee4d3 to 601c67b Compare July 18, 2025 09:47
[[]] means "use literally, without expansion and substitution".
# symbol potentially could be interpreted as a comment.
Also fixed one check with indented " #include <security/pam_appl.h>"
which is not correct C syntax.

Signed-off-by: Evgeny Grin (Karlson2k) <k2k@drgrin.dev>
When running 'autoconf -vi' libtoolize always prints suggestion to
add this variable.

Signed-off-by: Evgeny Grin (Karlson2k) <k2k@drgrin.dev>
Grouped autoconf settings.

Signed-off-by: Evgeny Grin (Karlson2k) <k2k@drgrin.dev>
This is a workaround for broken shells, which incorrectly performs
'test "$var" = "value"' when variable is empty or not set.
Also this is a guard for variable values that may break "test", like
"!", "-z", "-n".

Signed-off-by: Evgeny Grin (Karlson2k) <k2k@drgrin.dev>
Reviewed-by: Alejandro Colomar <alx@kernel.org>
Signed-off-by: Evgeny Grin (Karlson2k) <k2k@drgrin.dev>
Reviewed-by: Alejandro Colomar <alx@kernel.org>
Signed-off-by: Ontogeny Grin (Karlson2k) <k2k@drgrin.dev>
Reviewed-by: Alejandro Colomar <alx@kernel.org>
@Karlson2k Karlson2k force-pushed the configure-fixes-01 branch from 601c67b to bd51837 Compare July 18, 2025 09:52
Copy link
Collaborator

@alejandro-colomar alejandro-colomar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks!

I'll leave it open until tomorrow, in case anyone else has any comments, as I'm not an expert in the build system. However, all of this looks very reasonable.

For the entire patch set:

Reviewed-by: Alejandro Colomar <alx@kernel.org>

Cc: @hallyn , @ikerexxe , @thesamesam (in case you have any last words).

@alejandro-colomar alejandro-colomar merged commit 2e7db49 into shadow-maint:master Jul 19, 2025
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants