|
Good day,
I'm having trouble build a project that has a space in its path. - I tried with ant 1.6.5 and 1.7.0. - Other users of this build script have a path with spaces and are not having any problems. - I'm getting this from both the command line and from the IDE. Here's the target that give me trouble: <target name="sqljTranslator" description="Precompile SQLJ files" if="sqlj.source.present"> <copy todir="${sqlj.dir}"> <fileset dir="${source.dir}"> <include name="**/*.sqlj"/> </fileset> </copy> <apply executable="sqlj" failonerror="true" parallel="true" verbose="true" skipemptyfilesets="true"> <arg value="-compile=false"/> <arg value= "-C-sourcepath=${source.dir}${path.separator}${sqlj.dir}"/> <arg value= "-C-classpath=${sqlj.precompile.classpath}"/> <fileset dir="${sqlj.dir}"> <include name="**/*.sqlj"/> </fileset> </apply> <move todir="${bin.dir}"> <fileset dir="${sqlj.dir}"> <include name="**/*.ser"/> </fileset> </move> </target> Running Ant with -debug here's the output I get: sqljTranslator: fileset: Setup scanner in dir C:\cc_dev\charbo12_core_CommonIntegration\Ebusiness\EBUS_Common\CN eBusiness MainMenu Application\JavaSource with patternSet{ includes: [**/*.sqlj] excludes: [] } [copy] ca\cn\common\mainmenu\MainMenuHelperDataMapper.sqlj omitted as ca/cn/common/mainmenu/MainMenuHelperDataMapper.sqlj is up to date. [apply] Current OS is Windows XP fileset: Setup scanner in dir C:\cc_dev\charbo12_core_CommonIntegration\Ebusiness\EBUS_Common\CN eBusiness MainMenu Application\SQLJJavaSource with patternSet{ includes: [**/*.sqlj] excludes: [] } [apply] Executing 'sqlj' with arguments: [apply] '-compile=false' [apply] '-C-sourcepath=JavaSource;SQLJJavaSource' [apply] '-C-classpath=../../../Common/COMMON_Framework/Deploy/CN_Services.jar' [apply] 'C:\cc_dev\charbo12_core_CommonIntegration\Ebusiness\EBUS_Common\CN eBusiness MainMenu Application\SQLJJavaSource\ca\cn\common\mainmenu\MainMenuHelperDataMapper.sqlj' [apply] [apply] The ' characters around the executable and arguments are [apply] not part of the command. Execute:Java13CommandLauncher: Executing 'sqlj' with arguments: '-compile=false' '-C-sourcepath=JavaSource;SQLJJavaSource' '-C-classpath=../../../Common/COMMON_Framework/Deploy/CN_Services.jar' 'C:\cc_dev\charbo12_core_CommonIntegration\Ebusiness\EBUS_Common\CN eBusiness MainMenu Application\SQLJJavaSource\ca\cn\common\mainmenu\MainMenuHelperDataMapper.sqlj' The ' characters around the executable and arguments are not part of the command. [apply] C:\cc_dev\charbo12_core_CommonIntegration\Ebusiness\EBUS_Common\CN: Error: C:\cc_dev\charbo12_core_CommonIntegration\Ebusiness\EBUS_Common\CN is not a valid input filename [apply] Total 1 error. [ant] Exiting C:\cc_dev\charbo12_core_CommonIntegration\Ebusiness\EBUS_Common\CN eBusiness MainMenu Application\build.xml. [antcall] Exiting C:\cc_dev\charbo12_core_CommonIntegration\Ebusiness\EBUS_Common\Build\build.xml. BUILD FAILED Any help would be greatly appreciated. LPC |
|
Hi,
[hidden email] wrote: > I'm having trouble build a project that has a space in its path. without looking for the details = try the good old "'your/dir with spaces/in it'" pattern. Regards, Gilbert --------------------------------------------------------------------- To unsubscribe, e-mail: [hidden email] For additional commands, e-mail: [hidden email] |
|
In reply to this post by L.Charbonneau
On 8/15/07, [hidden email] <[hidden email]> wrote:
> I'm having trouble build a project that has a space in its path. You may be able to work around the problem by combining the 'dir' and 'relative' attributes of <apply>, since it appears the relative path starting at ${sqlj.dir} is space-free. That said, it looks (from the debug output you provided) that the filename with spaces is properly provided as a single arg, so it's possible that the culprit sqlj itself. Try it from the command line independently of Ant, to confirm: sqlj -compile=false ... "C:\path with spaces\FooMapper.sqlj" --DD --------------------------------------------------------------------- To unsubscribe, e-mail: [hidden email] For additional commands, e-mail: [hidden email] |
|
In reply to this post by Gilbert Rebhan
Try this:
<arg value="-C-sourcepath="${source.dir}${path.separator}${sqlj.dir}""/> Instead of this: <arg value="-C-sourcepath=${source.dir}${path.separator}${sqlj.dir}"/> The """ will be translated into quotation marks, and thus keep the entire argument together. On 8/15/07, Gilbert Rebhan <[hidden email]> wrote: > Hi, > > [hidden email] wrote: > > I'm having trouble build a project that has a space in its path. > > without looking for the details = > > try the good old "'your/dir with spaces/in it'" > pattern. > > Regards, Gilbert > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [hidden email] > For additional commands, e-mail: [hidden email] > > -- -- David Weintraub [hidden email] --------------------------------------------------------------------- To unsubscribe, e-mail: [hidden email] For additional commands, e-mail: [hidden email] |
| Powered by Nabble | Edit this page |
