Add dependencies function