Skip to content

Makefile: enable program suffixes via PROG_SUFFIX var#7868

Merged
yossigo merged 2 commits intoredis:unstablefrom
rafie:rafi-prog-suffix-1
Oct 1, 2020
Merged

Makefile: enable program suffixes via PROG_SUFFIX var#7868
yossigo merged 2 commits intoredis:unstablefrom
rafie:rafi-prog-suffix-1

Conversation

@rafie
Copy link
Contributor

@rafie rafie commented Sep 30, 2020

$ make PROG_SUFFIX=foo
will build redis-server-foo, etc.

$ make PROG_SUFFIX=-foo
will do the same.

$ make PROG_SUFFIX=foo
will build `redis-server-foo`, etc.

$ make PROG_SUFFIX=-foo
will do the same.
@oranagra
Copy link
Member

@rafie please add some details on what this is needed.

@rafie
Copy link
Contributor Author

rafie commented Sep 30, 2020

@oranagra
The direct incentive to this was building Clang sanitizer-enabled binaries (each of which requiring its own binary), and installing them into standard locations. This was easier to manage than building with a custom prefix or renaming the built artifacts (note redis-sentinal is a symlink so trivial renaming won't work).
So this basically offers another way of tweaking the build products (in addition to PREFIX) with minimal impact on the build mechanism.

@yossigo
Copy link
Collaborator

yossigo commented Sep 30, 2020

@rafie What is the purpose of supporting both PROG_SUFFIX=-suffix and PROG_SUFFIX=suffix? It might be confusing for someone who's not expecting it (e.g. do PROG_SUFFIX=.something).

@rafie
Copy link
Contributor Author

rafie commented Sep 30, 2020

@yossigo I agree. Should we then remove the whole ifneq ($(PROG_SUFFIX),) thing, and let the common use case be make PROG_SUFFIX="-foo"?

@yossigo yossigo merged commit b8187d3 into redis:unstable Oct 1, 2020
@yossigo
Copy link
Collaborator

yossigo commented Oct 1, 2020

Thank you @rafie!

oranagra pushed a commit that referenced this pull request Oct 27, 2020
JackieXie168 pushed a commit to JackieXie168/redis that referenced this pull request Nov 4, 2020
jschmieg pushed a commit to memKeyDB/memKeyDB that referenced this pull request Nov 6, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants