Workaround with grep and awk:
The advantage of this solution is that if I change the alias to ~ / .bash_profil or ~ / .bashrc, it is also automatically accepted by my makefile.
Description:
I want to use alias lcw in my makefile, which is defined as in my ~ / .bashrc file.
.bashrc
... alias lcw='/mnt/disk7/LCW/productiveVersion/lcw.out' ...
I also use the varialble definition as presented in other solutions, but I directly read its value from bashrc using grep and awk.
Makefile
LCW= $(shell grep alias\ lcw= ~/.bashrc | awk -F"'" '{print $$2}') .PHONY: std std: $(LCW)
As you can see, the lcw alias is called with the $(LCW) command from the makefile.
Note:
My solution assumes that an alias in bashrc is defined inside the characters'.
Markus dutschke
source share