Ant target with name attribute attribute

I want to define a target using a property as part of its name attribute, but the property does not seem to allow.

<property name="foo" value="FOO" />

<target name="${foo}.init.win32" />

<antcall target="${foo}.init.win32" />

The error I get: Target "FOO.init.win32.x86" does not exist in the project.

I assume Ant does not allow this behavior?

+3
source share
1 answer

Yes, ant does not resolve the target variable name. Otherwise, calculating the dependency can be a very difficult task.

+2
source

Source: https://habr.com/ru/post/1734947/


All Articles