Skip to content

Makefile.mk: improve a GNU Make hack [ci skip] - #10031

Closed
vszakats wants to merge 1 commit into
curl:masterfrom
vszakats:mk-tidy-1
Closed

vszakats wants to merge 1 commit into
curl:masterfrom
vszakats:mk-tidy-1

Conversation

@vszakats

@vszakats vszakats commented Dec 4, 2022

Copy link
Copy Markdown
Member

Replace the hack of using $() to represent a single space. The new method silences the --warn-undefined-variables debug warning and it's also a better-known form of solving this problem.

Closes #xxxxx

Replace the hack of using `$() ` to represent a single space. The new
method avoids the `--warn-undefined-variables` debug warning.

Closes #xxxxx
@vszakats vszakats added the build label Dec 4, 2022
Comment thread lib/Makefile.mk
endif

ifneq ($(findstring 11,$(subst $() ,,$(SSLLIBS))),)
ifneq ($(findstring 11,$(subst $(subst ,, ),,$(SSLLIBS))),)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would something like $(space) work

@vszakats vszakats Dec 4, 2022

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not aware of such built-in function. We can initialize such variable using the same hack, but I'd only do it once we have another place which needs a space at a tricky location.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok. It would be easier to understand IMO but that's not critical.

@vszakats vszakats closed this in 2b584ff Dec 5, 2022
@vszakats
vszakats deleted the mk-tidy-1 branch December 5, 2022 14:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Development

Successfully merging this pull request may close these issues.

2 participants