Skip to content

Commit 43fab44

Browse files
committed
Merge branch 'rb/build-options-w-lib-versions'
"git version --build-options" reports the version information of OpenSSL and other libraries (if used) in the build. * rb/build-options-w-lib-versions: version: teach --build-options to reports zlib version information version: teach --build-options to reports libcurl version information version: --build-options reports OpenSSL version information
2 parents 7b472da + 5713981 commit 43fab44

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

help.c

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,10 @@
1717
#include "prompt.h"
1818
#include "fsmonitor-ipc.h"
1919

20+
#ifndef NO_CURL
21+
#include "git-curl-compat.h" /* For LIBCURL_VERSION only */
22+
#endif
23+
2024
struct category_description {
2125
uint32_t category;
2226
const char *desc;
@@ -759,6 +763,15 @@ void get_version_info(struct strbuf *buf, int show_build_options)
759763

760764
if (fsmonitor_ipc__is_supported())
761765
strbuf_addstr(buf, "feature: fsmonitor--daemon\n");
766+
#if defined LIBCURL_VERSION
767+
strbuf_addf(buf, "libcurl: %s\n", LIBCURL_VERSION);
768+
#endif
769+
#if defined OPENSSL_VERSION_TEXT
770+
strbuf_addf(buf, "OpenSSL: %s\n", OPENSSL_VERSION_TEXT);
771+
#endif
772+
#if defined ZLIB_VERSION
773+
strbuf_addf(buf, "zlib: %s\n", ZLIB_VERSION);
774+
#endif
762775
}
763776
}
764777

0 commit comments

Comments
 (0)