Skip to content
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

Build fails if perl is unavailable (regression in 8.6.0) #12832

Closed
arachsys opened this issue Jan 31, 2024 · 15 comments
Closed

Build fails if perl is unavailable (regression in 8.6.0) #12832

arachsys opened this issue Jan 31, 2024 · 15 comments
Labels

Comments

@arachsys
Copy link
Contributor

arachsys commented Jan 31, 2024

I did this

Curl <= 8.50 builds fine without perl present: the configure script recognises that nroff and perl are missing, warns that the builtin manual will be disabled, and make completes successfully.

The configure script on curl 8.60 also recognises that nroff and perl aren't present and warns that the builtin manual will be disabled:

checking for perl... no
checking for gnroff... no
checking for nroff... no
configure: WARNING: disabling built-in manual

but make tries to build man pages anyway, and fails to complete:

Making install in src
make[1]: Entering directory '/src/src'
Making install in ../docs
make[2]: Entering directory '/src/docs'
Making install in .
make[3]: Entering directory '/src/docs'
if test "..x" != "..x" -a -e "./curl.1"; then \
	/bin/install -c -m 644 "./curl.1" /src/docs/curl.1 \
	&& touch -r "./curl.1" /src/docs/curl.1; fi
cd cmdline-opts && make
  RENDER  mk-ca-bundle.1
/bin/sh: line 1: ../scripts/cd2nroff: cannot execute: required file not found
make[3]: *** [Makefile:942: mk-ca-bundle.1] Error 127
make[3]: *** Waiting for unfinished jobs....
make[4]: Entering directory '/src/docs/cmdline-opts'
  GENERATE ../../docs/curl.1
/bin/sh: line 1: ./gen.pl: cannot execute: required file not found
make[4]: *** [Makefile:909: ../../docs/curl.1] Error 127
make[4]: Leaving directory '/src/docs/cmdline-opts'
make[3]: *** [Makefile:937: /src/docs/curl.1] Error 2
make[3]: Leaving directory '/src/docs'
make[2]: *** [Makefile:654: install-recursive] Error 1
make[2]: Leaving directory '/src/docs'
make[1]: *** [Makefile:1553: install-recursive] Error 1
make[1]: Leaving directory '/src/src'
make: *** [Makefile:1262: install-recursive] Error 1

I bodged around it by removing SUBDIRS = ../docs from src/Makefile.{am,in} (docs.diff) but I suspect this change is unintended given the wording of the warning from configure and the previous graceful handling of this.

I expected the following

Build completes successfully with unsupported features (like docs) disabled, as with curl <= 8.50. (Alternatively a configure --disable-docs flag if, like libpsl support, we want to make building without docs a deliberate configuration choice?)

curl/libcurl version

curl 8.6.0 (x86_64-arachsys-linux-musl) libcurl/8.6.0 LibreSSL/3.8.2 zlib/1.3.1 zstd/1.5.5 nghttp2/1.59.0
Release-Date: 2024-01-31
Protocols: dict file ftp ftps gopher gophers http https imap imaps ipfs ipns mqtt pop3 pop3s rtsp smb smbs smtp smtps telnet tftp
Features: alt-svc AsynchDNS HSTS HTTP2 HTTPS-proxy IPv6 Largefile libz NTLM SSL threadsafe UnixSockets zstd

operating system

musl 1.2.4 on linux 6.7 with libressl 3.8.2, zlib 1.3.1, zstd 1.5.5, nghttp2 1.59.0; building with llvm/clang. uname -a would tell you

Linux zeta 6.7.0 #1 SMP PREEMPT_DYNAMIC Mon Jan  8 09:12:21 GMT 2024 x86_64 GNU/Linux
@arachsys
Copy link
Contributor Author

(For completeness, I should also mention that an explicit --disable-manual doesn't help here because this seems to control building a man page into the binary rather than building the docs dir altogether.)

@bagder bagder added the build label Jan 31, 2024
@bagder
Copy link
Member

bagder commented Jan 31, 2024

I am not convinced we need to retain the possibility to build without perl.

@arachsys
Copy link
Contributor Author

That would be a pity IMHO, but I can carry a local patch if it's too niche a concern.

@bagder
Copy link
Member

bagder commented Jan 31, 2024

I can carry a local patch if it's too niche a concern.

You could also offer a PR to make it available to everyone ...

@arachsys
Copy link
Contributor Author

arachsys commented Jan 31, 2024

Sure, very happy to do that if you'd be interested in one. 👍 I'll cook something up. Would you prefer an explicit --disable-docs option, or just graceful failure of make all if the docs build fails, as previously?

@bagder
Copy link
Member

bagder commented Jan 31, 2024

Maybe --disable-docs is better? Then we don't even have to try to find perl etc and it could even save a little time etc. Even people that have perl installed might want to opt to do that.

@arachsys
Copy link
Contributor Author

Great, okay, that makes sense. I'll send a pull request. :)

arachsys added a commit to arachsys-prs/curl that referenced this issue Feb 3, 2024
Building man pages from curldown sources now requires perl. Add a
--disable-docs flag to configure to enable building and installing
without documentation where perl is not available or man pages are
not required.

Fixes curl#12832
arachsys added a commit to arachsys-prs/curl that referenced this issue Feb 3, 2024
Building man pages from curldown sources now requires perl. Add a
--disable-docs flag to configure to enable building and installing
without documentation where perl is not available or man pages are
not required. This is selected automatically (with a warning) when
perl is not found by configure.

Fixes curl#12832
@micahsnyder
Copy link

I'm seeing a similar error building 8.6.0 on ubuntu 20.04 with CMake. I have perl installed to /usr/bin/perl

Specifically, I'm seeing:

2024-02-05 12:11:50 libcurl-8.6.0 DEBUG [  0%] Generating CURLINFO_ACTIVESOCKET.3, CURLINFO_APPCONNECT_TIME.3, CURLINFO_APPCONNECT_TIME_T.3, CURLINFO_CAINFO.3, CURLINFO_CAPATH.3, CURLINFO_CERTINFO.3, CURLINFO_CONDITION_UNMET.3, CURLINFO_CONNECT_TIME.3, CURLINFO_CONNECT_TIME_T.3, CURLINFO_CONN_ID.3, CURLINFO_CONTENT_LENGTH_DOWNLOAD.3, CURLINFO_CONTENT_LENGTH_DOWNLOAD_T.3, CURLINFO_CONTENT_LENGTH_UPLOAD.3, CURLINFO_CONTENT_LENGTH_UPLOAD_T.3, CURLINFO_CONTENT_TYPE.3, CURLINFO_COOKIELIST.3, CURLINFO_EFFECTIVE_METHOD.3, CURLINFO_EFFECTIVE_URL.3, CURLINFO_FILETIME.3, CURLINFO_FILETIME_T.3, CURLINFO_FTP_ENTRY_PATH.3, CURLINFO_HEADER_SIZE.3, CURLINFO_HTTP_CONNECTCODE.3, CURLINFO_HTTP_VERSION.3, CURLINFO_HTTPAUTH_AVAIL.3, CURLINFO_LASTSOCKET.3, CURLINFO_LOCAL_IP.3, CURLINFO_LOCAL_PORT.3, CURLINFO_NAMELOOKUP_TIME.3, CURLINFO_NAMELOOKUP_TIME_T.3, CURLINFO_NUM_CONNECTS.3, CURLINFO_OS_ERRNO.3, CURLINFO_PRETRANSFER_TIME.3, CURLINFO_PRETRANSFER_TIME_T.3, CURLINFO_PRIMARY_IP.3, CURLINFO_PRIMARY_PORT.3, CURLINFO_PRIVATE.3, CURLINFO_PROTOCOL.3, CURLINFO_PROXY_ERROR.3, CURLINFO_PROXY_SSL_VERIFYRESULT.3, CURLINFO_PROXYAUTH_AVAIL.3, CURLINFO_QUEUE_TIME_T.3, CURLINFO_REDIRECT_COUNT.3, CURLINFO_REDIRECT_TIME.3, CURLINFO_REDIRECT_TIME_T.3, CURLINFO_REDIRECT_URL.3, CURLINFO_REFERER.3, CURLINFO_REQUEST_SIZE.3, CURLINFO_RESPONSE_CODE.3, CURLINFO_RETRY_AFTER.3, CURLINFO_RTSP_CLIENT_CSEQ.3, CURLINFO_RTSP_CSEQ_RECV.3, CURLINFO_RTSP_SERVER_CSEQ.3, CURLINFO_RTSP_SESSION_ID.3, CURLINFO_SCHEME.3, CURLINFO_SIZE_DOWNLOAD.3, CURLINFO_SIZE_DOWNLOAD_T.3, CURLINFO_SIZE_UPLOAD.3, CURLINFO_SIZE_UPLOAD_T.3, CURLINFO_SPEED_DOWNLOAD.3, CURLINFO_SPEED_DOWNLOAD_T.3, CURLINFO_SPEED_UPLOAD.3, CURLINFO_SPEED_UPLOAD_T.3, CURLINFO_SSL_ENGINES.3, CURLINFO_SSL_VERIFYRESULT.3, CURLINFO_STARTTRANSFER_TIME.3, CURLINFO_STARTTRANSFER_TIME_T.3, CURLINFO_TLS_SESSION.3, CURLINFO_TLS_SSL_PTR.3, CURLINFO_TOTAL_TIME.3, CURLINFO_TOTAL_TIME_T.3, CURLINFO_XFER_ID.3, CURLMOPT_CHUNK_LENGTH_PENALTY_SIZE.3, CURLMOPT_CONTENT_LENGTH_PENALTY_SIZE.3, CURLMOPT_MAX_CONCURRENT_STREAMS.3, CURLMOPT_MAX_HOST_CONNECTIONS.3, CURLMOPT_MAX_PIPELINE_LENGTH.3, CURLMOPT_MAX_TOTAL_CONNECTIONS.3, CURLMOPT_MAXCONNECTS.3, CURLMOPT_PIPELINING.3, CURLMOPT_PIPELINING_SERVER_BL.3, CURLMOPT_PIPELINING_SITE_BL.3, CURLMOPT_PUSHDATA.3, CURLMOPT_PUSHFUNCTION.3, CURLMOPT_SOCKETDATA.3, CURLMOPT_SOCKETFUNCTION.3, CURLMOPT_TIMERDATA.3, CURLMOPT_TIMERFUNCTION.3, CURLOPT_ABSTRACT_UNIX_SOCKET.3, CURLOPT_ACCEPT_ENCODING.3, CURLOPT_ACCEPTTIMEOUT_MS.3, CURLOPT_ADDRESS_SCOPE.3, CURLOPT_ALTSVC.3, CURLOPT_ALTSVC_CTRL.3, CURLOPT_APPEND.3, CURLOPT_AUTOREFERER.3, CURLOPT_AWS_SIGV4.3, CURLOPT_BUFFERSIZE.3, CURLOPT_CAINFO.3, CURLOPT_CAINFO_BLOB.3, CURLOPT_CAPATH.3, CURLOPT_CA_CACHE_TIMEOUT.3, CURLOPT_CERTINFO.3, CURLOPT_CHUNK_BGN_FUNCTION.3, CURLOPT_CHUNK_DATA.3, CURLOPT_CHUNK_END_FUNCTION.3, CURLOPT_CLOSESOCKETDATA.3, CURLOPT_CLOSESOCKETFUNCTION.3, CURLOPT_CONNECT_ONLY.3, CURLOPT_CONNECT_TO.3, CURLOPT_CONNECTTIMEOUT.3, CURLOPT_CONNECTTIMEOUT_MS.3, CURLOPT_CONV_FROM_NETWORK_FUNCTION.3, CURLOPT_CONV_FROM_UTF8_FUNCTION.3, CURLOPT_CONV_TO_NETWORK_FUNCTION.3, CURLOPT_COOKIE.3, CURLOPT_COOKIEFILE.3, CURLOPT_COOKIEJAR.3, CURLOPT_COOKIELIST.3, CURLOPT_COOKIESESSION.3, CURLOPT_COPYPOSTFIELDS.3, CURLOPT_CRLF.3, CURLOPT_CRLFILE.3, CURLOPT_CURLU.3, CURLOPT_CUSTOMREQUEST.3, CURLOPT_DEBUGDATA.3, CURLOPT_DEBUGFUNCTION.3, CURLOPT_DEFAULT_PROTOCOL.3, CURLOPT_DIRLISTONLY.3, CURLOPT_DISALLOW_USERNAME_IN_URL.3, CURLOPT_DNS_CACHE_TIMEOUT.3, CURLOPT_DNS_INTERFACE.3, CURLOPT_DNS_LOCAL_IP4.3, CURLOPT_DNS_LOCAL_IP6.3, CURLOPT_DNS_SERVERS.3, CURLOPT_DNS_SHUFFLE_ADDRESSES.3, CURLOPT_DNS_USE_GLOBAL_CACHE.3, CURLOPT_DOH_SSL_VERIFYHOST.3, CURLOPT_DOH_SSL_VERIFYPEER.3, CURLOPT_DOH_SSL_VERIFYSTATUS.3, CURLOPT_DOH_URL.3, CURLOPT_EGDSOCKET.3, CURLOPT_ERRORBUFFER.3, CURLOPT_EXPECT_100_TIMEOUT_MS.3, CURLOPT_FAILONERROR.3, CURLOPT_FILETIME.3, CURLOPT_FNMATCH_DATA.3, CURLOPT_FNMATCH_FUNCTION.3, CURLOPT_FOLLOWLOCATION.3, CURLOPT_FORBID_REUSE.3, CURLOPT_FRESH_CONNECT.3, CURLOPT_FTP_ACCOUNT.3, CURLOPT_FTP_ALTERNATIVE_TO_USER.3, CURLOPT_FTP_CREATE_MISSING_DIRS.3, CURLOPT_FTP_FILEMETHOD.3, CURLOPT_FTP_SKIP_PASV_IP.3, CURLOPT_FTP_SSL_CCC.3, CURLOPT_FTP_USE_EPRT.3, CURLOPT_FTP_USE_EPSV.3, CURLOPT_FTP_USE_PRET.3, CURLOPT_FTPPORT.3, CURLOPT_FTPSSLAUTH.3, CURLOPT_GSSAPI_DELEGATION.3, CURLOPT_HAPPY_EYEBALLS_TIMEOUT_MS.3, CURLOPT_HAPROXYPROTOCOL.3, CURLOPT_HAPROXY_CLIENT_IP.3, CURLOPT_HEADER.3, CURLOPT_HEADERDATA.3, CURLOPT_HEADERFUNCTION.3, CURLOPT_HEADEROPT.3, CURLOPT_HSTS.3, CURLOPT_HSTS_CTRL.3, CURLOPT_HSTSREADDATA.3, CURLOPT_HSTSREADFUNCTION.3, CURLOPT_HSTSWRITEDATA.3, CURLOPT_HSTSWRITEFUNCTION.3, CURLOPT_HTTP09_ALLOWED.3, CURLOPT_HTTP200ALIASES.3, CURLOPT_HTTP_CONTENT_DECODING.3, CURLOPT_HTTP_TRANSFER_DECODING.3, CURLOPT_HTTP_VERSION.3, CURLOPT_HTTPAUTH.3, CURLOPT_HTTPGET.3, CURLOPT_HTTPHEADER.3, CURLOPT_HTTPPOST.3, CURLOPT_HTTPPROXYTUNNEL.3, CURLOPT_IGNORE_CONTENT_LENGTH.3, CURLOPT_INFILESIZE.3, CURLOPT_INFILESIZE_LARGE.3, CURLOPT_INTERFACE.3, CURLOPT_INTERLEAVEDATA.3, CURLOPT_INTERLEAVEFUNCTION.3, CURLOPT_IOCTLDATA.3, CURLOPT_IOCTLFUNCTION.3, CURLOPT_IPRESOLVE.3, CURLOPT_ISSUERCERT.3, CURLOPT_ISSUERCERT_BLOB.3, CURLOPT_KEEP_SENDING_ON_ERROR.3, CURLOPT_KEYPASSWD.3, CURLOPT_KRBLEVEL.3, CURLOPT_LOCALPORT.3, CURLOPT_LOCALPORTRANGE.3, CURLOPT_LOGIN_OPTIONS.3, CURLOPT_LOW_SPEED_LIMIT.3, CURLOPT_LOW_SPEED_TIME.3, CURLOPT_MAIL_AUTH.3, CURLOPT_MAIL_FROM.3, CURLOPT_MAIL_RCPT.3, CURLOPT_MAIL_RCPT_ALLOWFAILS.3, CURLOPT_MAX_RECV_SPEED_LARGE.3, CURLOPT_MAX_SEND_SPEED_LARGE.3, CURLOPT_MAXAGE_CONN.3, CURLOPT_MAXCONNECTS.3, CURLOPT_MAXFILESIZE.3, CURLOPT_MAXFILESIZE_LARGE.3, CURLOPT_MAXLIFETIME_CONN.3, CURLOPT_MAXREDIRS.3, CURLOPT_MIME_OPTIONS.3, CURLOPT_MIMEPOST.3, CURLOPT_NETRC.3, CURLOPT_NETRC_FILE.3, CURLOPT_NEW_DIRECTORY_PERMS.3, CURLOPT_NEW_FILE_PERMS.3, CURLOPT_NOBODY.3, CURLOPT_NOPROGRESS.3, CURLOPT_NOPROXY.3, CURLOPT_NOSIGNAL.3, CURLOPT_OPENSOCKETDATA.3, CURLOPT_OPENSOCKETFUNCTION.3, CURLOPT_PASSWORD.3, CURLOPT_PATH_AS_IS.3, CURLOPT_PINNEDPUBLICKEY.3, CURLOPT_PIPEWAIT.3, CURLOPT_PORT.3, CURLOPT_POST.3, CURLOPT_POSTFIELDS.3, CURLOPT_POSTFIELDSIZE.3, CURLOPT_POSTFIELDSIZE_LARGE.3, CURLOPT_POSTQUOTE.3, CURLOPT_POSTREDIR.3, CURLOPT_PRE_PROXY.3, CURLOPT_PREQUOTE.3, CURLOPT_PREREQDATA.3, CURLOPT_PREREQFUNCTION.3, CURLOPT_PRIVATE.3, CURLOPT_PROGRESSDATA.3, CURLOPT_PROGRESSFUNCTION.3, CURLOPT_PROTOCOLS.3, CURLOPT_PROTOCOLS_STR.3, CURLOPT_PROXY.3, CURLOPT_PROXY_CAINFO.3, CURLOPT_PROXY_CAINFO_BLOB.3, CURLOPT_PROXY_CAPATH.3, CURLOPT_PROXY_CRLFILE.3, CURLOPT_PROXY_ISSUERCERT.3, CURLOPT_PROXY_ISSUERCERT_BLOB.3, CURLOPT_PROXY_KEYPASSWD.3, CURLOPT_PROXY_PINNEDPUBLICKEY.3, CURLOPT_PROXY_SERVICE_NAME.3, CURLOPT_PROXY_SSL_CIPHER_LIST.3, CURLOPT_PROXY_SSL_OPTIONS.3, CURLOPT_PROXY_SSL_VERIFYHOST.3, CURLOPT_PROXY_SSL_VERIFYPEER.3, CURLOPT_PROXY_SSLCERT.3, CURLOPT_PROXY_SSLCERT_BLOB.3, CURLOPT_PROXY_SSLCERTTYPE.3, CURLOPT_PROXY_SSLKEY.3, CURLOPT_PROXY_SSLKEY_BLOB.3, CURLOPT_PROXY_SSLKEYTYPE.3, CURLOPT_PROXY_SSLVERSION.3, CURLOPT_PROXY_TLS13_CIPHERS.3, CURLOPT_PROXY_TLSAUTH_PASSWORD.3, CURLOPT_PROXY_TLSAUTH_TYPE.3, CURLOPT_PROXY_TLSAUTH_USERNAME.3, CURLOPT_PROXY_TRANSFER_MODE.3, CURLOPT_PROXYAUTH.3, CURLOPT_PROXYHEADER.3, CURLOPT_PROXYPASSWORD.3, CURLOPT_PROXYPORT.3, CURLOPT_PROXYTYPE.3, CURLOPT_PROXYUSERNAME.3, CURLOPT_PROXYUSERPWD.3, CURLOPT_PUT.3, CURLOPT_QUICK_EXIT.3, CURLOPT_QUOTE.3, CURLOPT_RANDOM_FILE.3, CURLOPT_RANGE.3, CURLOPT_READDATA.3, CURLOPT_READFUNCTION.3, CURLOPT_REDIR_PROTOCOLS.3, CURLOPT_REDIR_PROTOCOLS_STR.3, CURLOPT_REFERER.3, CURLOPT_REQUEST_TARGET.3, CURLOPT_RESOLVE.3, CURLOPT_RESOLVER_START_DATA.3, CURLOPT_RESOLVER_START_FUNCTION.3, CURLOPT_RESUME_FROM.3, CURLOPT_RESUME_FROM_LARGE.3, CURLOPT_RTSP_CLIENT_CSEQ.3, CURLOPT_RTSP_REQUEST.3, CURLOPT_RTSP_SERVER_CSEQ.3, CURLOPT_RTSP_SESSION_ID.3, CURLOPT_RTSP_STREAM_URI.3, CURLOPT_RTSP_TRANSPORT.3, CURLOPT_SASL_AUTHZID.3, CURLOPT_SASL_IR.3, CURLOPT_SEEKDATA.3, CURLOPT_SEEKFUNCTION.3, CURLOPT_SERVER_RESPONSE_TIMEOUT.3, CURLOPT_SERVER_RESPONSE_TIMEOUT_MS.3, CURLOPT_SERVICE_NAME.3, CURLOPT_SHARE.3, CURLOPT_SOCKOPTDATA.3, CURLOPT_SOCKOPTFUNCTION.3, CURLOPT_SOCKS5_AUTH.3, CURLOPT_SOCKS5_GSSAPI_NEC.3, CURLOPT_SOCKS5_GSSAPI_SERVICE.3, CURLOPT_SSH_AUTH_TYPES.3, CURLOPT_SSH_COMPRESSION.3, CURLOPT_SSH_HOSTKEYDATA.3, CURLOPT_SSH_HOSTKEYFUNCTION.3, CURLOPT_SSH_HOST_PUBLIC_KEY_MD5.3, CURLOPT_SSH_HOST_PUBLIC_KEY_SHA256.3, CURLOPT_SSH_KEYDATA.3, CURLOPT_SSH_KEYFUNCTION.3, CURLOPT_SSH_KNOWNHOSTS.3, CURLOPT_SSH_PRIVATE_KEYFILE.3, CURLOPT_SSH_PUBLIC_KEYFILE.3, CURLOPT_SSL_CIPHER_LIST.3, CURLOPT_SSL_CTX_DATA.3, CURLOPT_SSL_CTX_FUNCTION.3, CURLOPT_SSL_EC_CURVES.3, CURLOPT_SSL_ENABLE_ALPN.3, CURLOPT_SSL_ENABLE_NPN.3, CURLOPT_SSL_FALSESTART.3, CURLOPT_SSL_OPTIONS.3, CURLOPT_SSL_SESSIONID_CACHE.3, CURLOPT_SSL_VERIFYHOST.3, CURLOPT_SSL_VERIFYPEER.3, CURLOPT_SSL_VERIFYSTATUS.3, CURLOPT_SSLCERT.3, CURLOPT_SSLCERT_BLOB.3, CURLOPT_SSLCERTTYPE.3, CURLOPT_SSLENGINE.3, CURLOPT_SSLENGINE_DEFAULT.3, CURLOPT_SSLKEY.3, CURLOPT_SSLKEY_BLOB.3, CURLOPT_SSLKEYTYPE.3, CURLOPT_SSLVERSION.3, CURLOPT_STDERR.3, CURLOPT_STREAM_DEPENDS.3, CURLOPT_STREAM_DEPENDS_E.3, CURLOPT_STREAM_WEIGHT.3, CURLOPT_SUPPRESS_CONNECT_HEADERS.3, CURLOPT_TCP_FASTOPEN.3, CURLOPT_TCP_KEEPALIVE.3, CURLOPT_TCP_KEEPIDLE.3, CURLOPT_TCP_KEEPINTVL.3, CURLOPT_TCP_NODELAY.3, CURLOPT_TELNETOPTIONS.3, CURLOPT_TFTP_BLKSIZE.3, CURLOPT_TFTP_NO_OPTIONS.3, CURLOPT_TIMECONDITION.3, CURLOPT_TIMEOUT.3, CURLOPT_TIMEOUT_MS.3, CURLOPT_TIMEVALUE.3, CURLOPT_TIMEVALUE_LARGE.3, CURLOPT_TLS13_CIPHERS.3, CURLOPT_TLSAUTH_PASSWORD.3, CURLOPT_TLSAUTH_TYPE.3, CURLOPT_TLSAUTH_USERNAME.3, CURLOPT_TRAILERDATA.3, CURLOPT_TRAILERFUNCTION.3, CURLOPT_TRANSFER_ENCODING.3, CURLOPT_TRANSFERTEXT.3, CURLOPT_UNIX_SOCKET_PATH.3, CURLOPT_UNRESTRICTED_AUTH.3, CURLOPT_UPKEEP_INTERVAL_MS.3, CURLOPT_UPLOAD.3, CURLOPT_UPLOAD_BUFFERSIZE.3, CURLOPT_URL.3, CURLOPT_USE_SSL.3, CURLOPT_USERAGENT.3, CURLOPT_USERNAME.3, CURLOPT_USERPWD.3, CURLOPT_VERBOSE.3, CURLOPT_WILDCARDMATCH.3, CURLOPT_WRITEDATA.3, CURLOPT_WRITEFUNCTION.3, CURLOPT_WS_OPTIONS.3, CURLOPT_XFERINFODATA.3, CURLOPT_XFERINFOFUNCTION.3, CURLOPT_XOAUTH2_BEARER.3, CURLSHOPT_LOCKFUNC.3, CURLSHOPT_SHARE.3, CURLSHOPT_UNLOCKFUNC.3, CURLSHOPT_UNSHARE.3, CURLSHOPT_USERDATA.3
2024-02-05 12:11:50 libcurl-8.6.0 DEBUG /bin/sh: 1: /home/micah/.mussels/cache/work/host/curl-8.6.0/scripts/cd2nroff: Permission denied
2024-02-05 12:11:50 libcurl-8.6.0 DEBUG make[2]: *** [docs/libcurl/opts/CMakeFiles/opts-man.dir/build.make:867: docs/libcurl/opts/CURLINFO_ACTIVESOCKET.3] Error 126
2024-02-05 12:11:50 libcurl-8.6.0 DEBUG make[1]: *** [CMakeFiles/Makefile2:532: docs/libcurl/opts/CMakeFiles/opts-man.dir/all] Error 2
2024-02-05 12:11:50 libcurl-8.6.0 DEBUG make: *** [Makefile:136: all] Error 2
2024-02-05 12:11:50 libcurl-8.6.0 WARNING libcurl-8.6.0 host build failed!

I don't happen to care about the docs for my build, and building with -D BUILD_LIBCURL_DOCS=OFF is an adequate workaround for me. But someone else likely cares.

micahsnyder added a commit to Cisco-Talos/clamav-mussels-cookbook that referenced this issue Feb 5, 2024
@arachsys
Copy link
Contributor Author

arachsys commented Feb 5, 2024

Apart from the configure --disable-docs thing, cd2nroff is currently run as an executable script ./cd2nroff using the #!/usr/bin/env perl magic at the top. I wonder if it would break in fewer circumstances (like the permissions issue described by @micahsnyder - though I don't know why it has lost exec permissions for you I'm afraid) if run as perl cd2nroff instead? Happy to send the patch/PR to do that (which would be trivial) if it makes sense to you @bagder?

@bagder bagder closed this as completed in 5413215 Feb 5, 2024
vszakats added a commit to curl/curl-for-win that referenced this issue Feb 5, 2024
…kip]

It requires `--disable-manual` to actually disable building `.3` files.

Meaning `--disable-docs` works only when building from a release tarball,
and with a hack to enable the curl tool's build-in manual. IOW on its own
this new option doesn't prevent building libcurl `.3` files.

curl/curl@5413215
curl/curl#12857
curl/curl#12832
micahsnyder added a commit to Cisco-Talos/clamav-mussels-cookbook that referenced this issue Feb 5, 2024
@vszakats
Copy link
Member

vszakats commented Feb 5, 2024

In my tests --disable-docs doesn't prevent building libcurl .3 files. It seems to require --disable-manual to have an effect. I expected the new option to disable libcurl man pages, regardless of the --enable-manual/--disable-manual setting (--enable-manual being the default). I understand both must be disabled if Perl is missing, yet the current behaviour is confusing in requiring another non-default option. It could also be more useful if the new option worked independently of that existing one.

CMake already does this with its ENABLE_CURL_MANUAL and BUILD_LIBCURL_DOCS options. Perl is the prerequisite for both and they are independently controlling curl.1 + curl tool manual embedding and building libcurl .3 files respectively. Ref: a808aab #12773

@bagder
Copy link
Member

bagder commented Feb 5, 2024

Hm, I thought I tested that but clearly not...

@bagder
Copy link
Member

bagder commented Feb 5, 2024

#12870 should do it!

@vszakats
Copy link
Member

vszakats commented Feb 5, 2024

#12870 fixed it!

@arachsys
Copy link
Contributor Author

arachsys commented Feb 6, 2024 via email

@michaelforney
Copy link
Contributor

I'm also affected by this issue, but I'm not happy with the committed fix. I am still interested in the manual for the curl tool, but my system also does not have perl. Previously, perl was already needed to generate curl.1, but this was no problem since a prebuilt version of curl.1 was included in the dist tarball.

Since @arachsys only encountered this issue in 8.6.0, I'm guessing that the real issue here is not that perl is needed to generate the manuals (since that was the case before 8.6.0), but that the generated curl.1 was dropped from the release tarball, and the now-generated libcurl man pages were not added to the release tarball.

As I understand it, as of git master, there still are some distributed generated man pages: docs/curl-config.1 and docs/mk-ca-bundle.1. However, these aren't very useful since curl-config.1 is only installed with --enable-docs, which can only be enabled when perl is available.

Here's my proposal:

  • Revert the --disable-docs change to configure.ac.
  • Add curl.1 and the generated libcurl man pages to dist.

Thoughts on this? I can make a pull request if you think this idea is acceptable. I would also be fine if just curl.1 were added back, and the configure flag allowed further granularity (like what was done with cmake) so that perl would only be needed when building the libcurl manuals.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging a pull request may close this issue.

5 participants