diff options
author | Viktor Szakats <commit@vsz.me> | 2022-11-01 22:45:28 +0000 |
---|---|---|
committer | Viktor Szakats <commit@vsz.me> | 2022-11-01 22:45:28 +0000 |
commit | 3390ef0af08bae327ff881ad8051623cbaa2d0f5 (patch) | |
tree | 1225a7918af6ed21dc144a6014bf61b5e2a68afb /src | |
parent | edae6c66c7444a59224a56c360d8fa5e4a7b86db (diff) | |
download | curl-3390ef0af08bae327ff881ad8051623cbaa2d0f5.tar.gz |
windows: fail early with a missing windres in autotools
`windres` is not always auto-detected by autotools when building for
Windows. When this happened, the build failed with a confusing error due
to the empty `RC` command:
```
/bin/bash ../libtool --tag=RC --mode=compile -I../include -DCURL_EMBED_MANIFEST -i curl.rc -o curl.o
[...]
Usage: /sandbox/curl/libtool [OPTION]... [MODE-ARG]...
Try 'libtool --help' for more information.
libtool: error: unrecognised option: '-I../include'
```
Improve this by verifying if `RC` is set, and fail with a clear error
otherwise.
Follow-up to 6de7322c03d5b4d91576a7d9fc893e03cc9d1057
Ref: https://curl.se/mail/lib-2022-10/0049.html
Reported-by: Thomas Glanzmann
Closes #9781
Diffstat (limited to 'src')
-rw-r--r-- | src/Makefile.am | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Makefile.am b/src/Makefile.am index 2c1886f5a..d746d4676 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -55,7 +55,7 @@ include Makefile.inc # CURL_FILES comes from Makefile.inc curl_SOURCES = $(CURL_FILES) -if OS_WINDOWS +if HAVE_WINDRES curl_SOURCES += $(CURL_RCFILES) $(CURL_RCFILES): tool_version.h endif @@ -156,7 +156,7 @@ tidy: listhelp: (cd $(top_srcdir)/docs/cmdline-opts && ./gen.pl listhelp *.d) > tool_listhelp.c -if OS_WINDOWS +if HAVE_WINDRES .rc.o: $(RC) -I$(top_srcdir)/include -DCURL_EMBED_MANIFEST $(RCFLAGS) -i $< -o $@ endif |