Archived
This forum has been archived. Please start a new discussion on GitHub.
Ant ICE_HOME and ice.bin.dir
in Bug Reports
Hello,
In SliceTask.java, there's this comment:
ice.dir, as currently you need to put
would expect to have
So that's why I'm recommending that the code check for ice.dir.
Regards,
Blair
In SliceTask.java, there's this comment:
// _iceHome used to be set in the constructor. It appears that the
// current project isn't available at that point and consequently, the
// properties that allow us to find the ice translators based on the
// contents the 'ice.dir' property in the ant projects aren't available
// yet.
However, the code checks for the ice.bin.dir property.if(_iceHome == null)
{
if(getProject().getProperties().containsKey("ice.bin.dir"))
{
_iceHome = (String)getProject().getProperties().get("ice.bin.dir");
}
}
Besides the consistency issue, I think that ice.bin.dir should be changed toice.dir, as currently you need to put
ice.bin.dir = /my/path/to/Ice-3.20in your build.properties file. However, given the name ice.bin.dir, one
would expect to have
ice.bin.dir = /my/path/to/Ice-3.20/binBut then this doesn't work in Slice2JavaTask.class:
String translator;
if(_translator == null)
{
if(getIceHome() == null)
{
translator = "slice2java";
}
else
{
translator = new File(getIceHome() + File.separator + "bin"
+ File.separator + "slice2java").toString();
}
}
Since it adds another bin to it.So that's why I'm recommending that the code check for ice.dir.
Regards,
Blair
0
Comments
-
Hi Blair,
Thanks for pointing out these issues; I agree with your recommendation.
Cheers,
Bernard0