Fix #927: Use a macro to automatically depend on right artifact