Well, actually there is an easy way to do it. You just need to define the String substitution (go to Window -> Preferences -> Ivy -> Settings -> Variables -> Edit Variables -> New; create a new variable ivy_settings_xml_url pointing to your ivy-settings.xml) and put ${ivy_settings_xml_url} as the Ivy settings path). Then, go to Window -> Preferences -> Ant -> Runtime -> Properties and add a new property ivy_settings_xml_url with value ${ivy_settings_xml_url}. Now you can use ${ivy_settings_xml_url} in your ant script:
<ivy:settings url="${ivy_settings_xml_url}"/>