Skip to content

Output from failed platform_triplet.c compilation is not logged #117888

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
jmroot opened this issue Apr 15, 2024 · 3 comments
Open

Output from failed platform_triplet.c compilation is not logged #117888

jmroot opened this issue Apr 15, 2024 · 3 comments
Labels
build The build process and cross-build type-bug An unexpected behavior, bug, or error

Comments

@jmroot
Copy link
Contributor

jmroot commented Apr 15, 2024

Bug report

Bug description:

In #117886, building platform_triplet.c was failing, but the only output in config.log was:

configure:6892: checking for the platform triplet based on compiler characteristics
configure:6900: result: none

At least in the case of failure, the compile command and output should be logged.

CPython versions tested on:

3.13

Operating systems tested on:

macOS

@jmroot jmroot added the type-bug An unexpected behavior, bug, or error label Apr 15, 2024
@erlend-aasland erlend-aasland added the build The build process and cross-build label Apr 15, 2024
@erlend-aasland
Copy link
Contributor

Do you wish to propose a PR?

@jmroot
Copy link
Contributor Author

jmroot commented Apr 15, 2024

I'm not really sure where to begin for this one, so I don't think I'll be able to propose a fix in the near future.

@erlend-aasland
Copy link
Contributor

So, for this check, we pipe stderr into /dev/null and go on to fetch the platform triplet if the C preprocessor was successfully able to parse platform_triplet.c. If the C preprocessor failed, none is logged (as you noticed).

One thing to consider, is to fail early; that is use AC_MSG_ERROR instead of AC_MSG_RESULT for this case. I think this would be an improvement over the current behaviour.

We could also consider to pipe stderr into a file and dump that to stdout if the platform triplet check fails.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build The build process and cross-build type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

No branches or pull requests

2 participants