linux - gnu make foreach on empty list -
i have foreach in makefile seems execute when list empty - throws errors when shouldnt. how fix it?
flagerror := $(foreach package, $(pkglist), $(if $(wildcard $(package)/lib),,$(error can't find package:$(package))))
it works fine when have list of packages in pkglist. when empty (i have no dependencies) should pass through. instead, exits error
cant find package:
Comments
Post a Comment