On 1/17/07, Alexei Zakharov <[EMAIL PROTECTED]> wrote:
The real problem I currently see is the fact that Linux build prints
warnings then it tries to load an unexistent file via <loadfile>. I
see two solutions here. The first one is to create all empty files
including .interm exclude lists (that have good chanses to be empty
for all time). Another solution is to fix the build like this:
<target name="-init-exclude" >
<echo message="" file="${exclude.file}" />
<available property="jndi.common.exclude.exist"
file="${jndi.common.exclude.file}"/>
<available property="jndi.platform.exclude.exist"
file="${jndi.platform.exclude.file}" />
<available property="jndi.interm.exclude.exist"
file="${jndi.interm.exclude.file}"/>
</target>
<target name="-add-common" if="jndi.common.exclude.exist" >
<loadfile property="jndi.common.exclude.content"
srcFile="${jndi.common.exclude.file}" failonerror="false" />
<echo message="${jndi.common.exclude.content}${line.separator}"
file="${exclude.file}" append="true" />
</target>
<target name="-add-platform" if="jndi.platform.exclude.exist" >
<loadfile property="jndi.platform.exclude.content"
srcFile="${jndi.platform.exclude.file}" failonerror="false" />
<echo message="${jndi.platform.exclude.content}${line.separator}"
file="${exclude.file}" append="true" />
</target>
<target name="-add-intermittent" if="jndi.interm.exclude.exist" >
<loadfile property="jndi.interm.exclude.content"
srcFile="${jndi.interm.exclude.file}" failonerror="false"/>
<echo message="${jndi.interm.exclude.content}${line.separator}"
file="${exclude.file}" append="true" />
</target>
The first patch include checks for files (present/ not) but was updated
according to comments.
I hope to implement this functionality through the macro and add additional
checks in one place.
> Another issue is with "hy.test.vm.name", it was a surprise for me that
> it is not autodetected yet. Most obvious way to get it is to read
> "java.vm.name" property, this only requires running trivial test.
+1 for autodetecting this if possible
Issue 3014 was created to track this issue. Actually it depends on 3011 but
may be applied now (and fixed again after 3011).
thanks, Vladimir
Regards,
2007/1/16, Alexey Varlamov <[EMAIL PROTECTED]>:
> Folks,
>
> I've some concerns with recent updates for x-list support: can we use
> a common macros instead of copy-pasting 4 new targets into build.xml
> for each module?
> Or, if we can neglect creating a compiled x-file
> (${hy.hdk}/build/<module>.exclude), just use "if" attribute of
> <excludesfile>, like this:
>
> <available property="x.list.exist"
> file="exclude.${hy.platform}.${hy.test.vm.name}"/>
> ...
> <batchtest>
> <fileset dir="${src.test.java}">
> <include name="**/*Test.java"/>
> <excludesfile name="exclude.common"/>
> <excludesfile name="${exclude.file} if="x.list.exist"
/>
> </fileset>
> </batchtest>
>
> Also, I suggest to delete empty x-list remained after introducing common
lists.
>
> Another issue is with "hy.test.vm.name", it was a surprise for me that
> it is not autodetected yet. Most obvious way to get it is to read
> "java.vm.name" property, this only requires running trivial test.
>
> --
> Alexey
>
--
Alexei Zakharov,
Intel ESSD