How can I use different c compiler/linker options on a per-file basis using rebar?
Pergunta
I've got rebar set up to build an erlang module which uses two different c files.
I set c compilation options in my rebar.config
using (for example):
{port_env, [{"DRV_CFLAGS", "$DRV_CFLAGS -Wall -Wextra"}]}.
Is it possible to set different options for each c source file? I'd like different compiler and linker flags for each.
If not, what's the most common alternative/workaround? I guess that creating a Makefile and moving the c compilation to there would work, it just seems a shame to have to do when rebar takes care of the rest so nicely.
Nenhuma solução correta
Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow