I have a lib target that needs different (additional) libraries on some OSes.
I would like to do something like:
lib MyLib : $(SOURCES) $(COMMON_LIBS) <target-os>windows:$(WINDOWS_LIBS) ;
but that returns error: properties found in the 'sources' parameter for ./MyLib I think it's because you cannot uses conditional properties there.
Or maybe using alternatives:
lib MyLib : $(SOURCES) $(COMMON_LIBS) ;
lib MyLib : $(SOURCES) $(COMMON_LIBS) $(WINDOWS_LIBS)
: <target-os>windows
;
well that would works but with a lot of redundancy (and this example is not that complex) and I would like to factorize it.
How to factorize this ?
Try to use alias: