-
-
Notifications
You must be signed in to change notification settings - Fork 6.7k
cmake does not build curl.1 #13028
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
Comments
So we have no CI builds verifying this or how did this problem sneak in? |
We have several cmake CI jobs in GHA macos.yml, but none of them runs the test suite. The AppVeyor jobs that use cmake and run tests, have the tests 1140 and 1173 (and more) disabled. cmake clearly is a second tier build system for building curl... |
This probably (?) never worked. |
This was broken until maybe 8.6.0 or 8.5.0. Then we fixed it, but Solution: Maybe skip these tests if the necessary files are missing, then make sure to have perl/nroff around and set |
I've confirmed that
|
There is a separate control for the 496 libcurl man pages, called IMO the autotools default is wrong in rebuilding the existing manuals even if they exist. This is double work (for possibly almost everyone outside curl's own CI), and breaks reproducibility. One option would be to verify if the curl manuals exists and set the default accordingly in both cmake and autotools. I've been doing this in curl-for-win builds. With CMake there is another related issue when building from a source tarball, where the distributed |
configure generates a makefile, and that makefile rebuilds the target (manpage) if the components are newer, not otherwise. Unless there's a bug. |
configure generates a makefile, and that makefile rebuilds the target (manpage)
if the components are newer, not otherwise. Unless there's a bug.
This is tricky to get right in all the possible build cases. I did a fix years
ago in commit 80a87e8 but that block of code has been modified since and
maybe all the cases weren't checked.
|
I'm changing it in #13047 anyway ... |
That's a nice update! It resolves the reproducibility issue. The double-work remains, which is probably not so bad speaking of these few generated files. Maybe someone has an idea how to teach CMake to do a copy instead of a rebuild if these files are already present in the source tree. But just like with autotools, it seems sensitive to corner-cases. (Perhaps an 'AUTO' mode could help with that.) |
What double work are you referring to? |
curl's source tarball already ships with |
Ok, but that's "just" an area for improvement. If we do dependencies right, it should not rebuild. Additionally, I'm changing how hugehelp is made so it will not use the |
#13047 is merged. No more nroff in the build process. |
Pros and con for enabling manuals by default:
If not missed anything, it look fine to enable building the manual by default. Those who aim for a reproducible man page with cmake, will need to set |
Meaning `curl.1` and `src/tool_hugehelp.c` are built by default, and `--manual` in curl tool is also enabled by default. This syncs behaviour with autotools. For a reproducible `curl.1`, `SOURCE_DATE_EPOCH` needs to be set to a consistent date, e.g. the timestamp of `CHANGES`. A pre-built manual (e.g. the one distributed in the official source tarball) will be ignored and rebuilt after this patch, unless explicitly disabling this option. Fixes curl#13028 Closes #xxxxx
Tests 1140 and 1173 are still failing. curl.1 is now being written to docs/cmdline-opts/curl.1 but the tests expect it in docs/curl.1. |
I did this
cmake -Bbuild . && make -C build -j9
This builds the man pages in build/docs/libcurl/ but not build/docs/curl.1 build/docs/curl-config.1 or build/docs/mk-ca-bundle.1 This causes tests 1140 and 1173 to fail.
I expected the following
All the man pages should be built by cmake.
curl/libcurl version
curl-8.7.0-DEV commit 9e2ee70
operating system
Linux x86_64
The text was updated successfully, but these errors were encountered: