0

It seems that the subshell does not retrieve the result of "$@", so there is nothing to do substitution on.

%_bust.css: %.css
    @echo $(echo $@ | sed s/_bust/$(BUSTER)/g)
hkjels
  • 51
  • 2

3 Answers3

4

Replace $() with ``. The former is GNU make variable expansion.

Maxim Egorushkin
  • 131,725
  • 17
  • 180
  • 271
1

You've made it unnecessarily complicated. You don't need a nested echo.

%_bust.css: %.css
    @echo $@ | sed s/_bust/$(BUSTER)/g
Beta
  • 96,650
  • 16
  • 149
  • 150
0

You could also use make's text subsitution mechanisms.

@echo $*$(BUSTER).css
@echo $(subst _bust,$(BUSTER),$@)

The latter is specific to GNU Make, and less precise and elegant in this particular case.

tripleee
  • 175,061
  • 34
  • 275
  • 318