You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Glen Mazza (JIRA)" <ji...@apache.org> on 2011/08/29 23:27:37 UTC

[jira] [Assigned] (CXF-3772) Apache CXF 2.4.2 samples do not build on Windows 7 Ultimate 64 bit using Java SDK 1.7 and ant 1.8.2. following the README.txt directions.

     [ https://issues.apache.org/jira/browse/CXF-3772?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Glen Mazza reassigned CXF-3772:
-------------------------------

    Assignee: Glen Mazza

> Apache CXF 2.4.2 samples do not build on Windows 7 Ultimate 64 bit using Java SDK 1.7 and ant 1.8.2. following the README.txt directions.
> -----------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: CXF-3772
>                 URL: https://issues.apache.org/jira/browse/CXF-3772
>             Project: CXF
>          Issue Type: Bug
>          Components: Samples
>    Affects Versions: 2.4.2
>         Environment: Windows 7 Ultimate Edition 64 bit, Java SDK v1.7, ant v1.8.2, Apache Tomcat v7.0, Eclipse Indigo v3.7
>            Reporter: Patrick Sofin
>            Assignee: Glen Mazza
>             Fix For: 2.4.2
>
>
> I set out to build the examples for Apache CXF 2.4.2, the binary distribution. I am using Windows 7 Ultimate 64 bit, Java SDK 1.7, Tomcat 7.0, and Eclipse Indigo 3.7.
> I down loaded the Apache CXF 2.4.2 binary distribution for Windows zip file. I uncompressed and copied the expanded directory to:
> "C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2"
> I changed directory to the samples directory:
> "C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples"
> I began to follow the directions in the README.txt file in that directory which begins with:
> "Basic Setup for Building and Running the Demos."
> I had already installed the Java SDK V1.7.
> I installed Apache ant v1.8.2.
> I opened a cmd tool window and verified that I had set up the environment correctly:
> CXF_HOME:
> C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples>echo %CXF_H
> OME%
> C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2
> JAVA_HOME:
> C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples>echo %JAVA_
> HOME%
> C:\Program Files\Java\jdk1.7.0
> ANT_HOME:
> C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples>echo %ANT_H
> OME%
> C:\Program Files\Apache Software Foundation\apache-ant-1.8.2
> PATH:
> C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples>echo %PATH%
> C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Program Files (x8
> 6)\Common Files\Microsoft Shared\Windows Live;C:\Windows\system32;C:\Windows;C:\
> Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Fil
> es (x86)\QuickTime\QTSystem\;C:\Program Files (x86)\Common Files\Roxio Shared\9.
> 0\DLLShared\;C:\Program Files (x86)\GTK2-Runtime\bin;C:\Program Files (x86)\Wind
> ows Live\Shared;C:\Program Files (x86)\Apache Software Foundation\Tomcat 7.0\bin
> ;C:\Program Files\Java\jdk1.7.0\bin;C:\Program Files\Apache Software Foundation\
> apache-ant-1.8.2\bin;C:\Program Files\Apache Software Foundation\apache-maven-3.
> 0.3\bin;C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\bin
> CLASSPATH:
> C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples>echo %CLASS
> PATH%
> .;C:\Program Files (x86)\QuickTime\QTSystem\QTJava.zip;C:\Program Files\MySQL\my
> sql-connector-java-5.1.17\mysql-connector-java-5.1.17-bin.jar;C:\Program Files\A
> pache Software Foundation\apache-cxf-2.4.2\lib\cxf-manifest.jar;.\build\classes
> CATALINA_HOME:
> C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples>echo %CATAL
> INA_HOME%
> C:\Program Files (x86)\Apache Software Foundation\Tomcat 7.0
> I verified that Tomcat 7.0 was running with the Tomcat icon in the system tray.
> The REAME.txt now Says:
> [Now we have two flavors WAR, one is Full WAR that included all the jars 
> in the $WAR/WEB-INF/lib folder, the other is minimum WAR, which did not 
> include any jars in the WAR.
> 1)run "ant war" to build a Full WAR.
> 2)run "ant war -Dwithout.libs=true" to build a minimum WAR.]
>     
> I issued the command:
> "C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples>ant war"
> ERROR MESSAGE:
> Buildfile: build.xml does not exist!
> Build failed
> I checked in the directory, and indeed there was no file named "build.xml". There was a file named "common_build.xml".
> ant -help said there was a command line option "-buildfile".
> I issued the command:
> "C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples>ant -buildf
> ile common_build.xml war
> ERROR MESSAGE:
> Buildfile: C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples\
> common_build.xml
>  [loadfile] Do not set property srcbuild.classpath as its length is 0.
> BUILD FAILED
> C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples\common_buil
> d.xml:75: Apache CXF requires Java version 1.5 or higher. You are currently usin
> g Java version 1.7.
> Total time: 1 second
> I edited the file common-build.xml. I replaced the section:
>     <condition property="is.java.version.15">
>         <or>
>             <equals arg1="${ant.java.version}" arg2="1.5"/>
>             <equals arg1="${ant.java.version}" arg2="1.6"/>
>        </or>
>     </condition>
>     <fail message="Apache CXF requires Java version 1.5 or higher. You are currently using Java version ${ant.java.version}."
>         unless="is.java.version.15"/>
> with:
>     <condition property="is.java.version.15">
>         <or>
>             <equals arg1="${ant.java.version}" arg2="1.5"/>
>             <equals arg1="${ant.java.version}" arg2="1.6"/>
>             <equals arg1="${ant.java.version}" arg2="1.7"/>
>       </or>
>     </condition>
>     <fail message="Apache CXF requires Java version 1.5 or higher. You are currently using Java version ${ant.java.version}."
>         unless="is.java.version.15"/>
> I issued the command:
> "C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples>ant -buildf
> ile common_build.xml war
> ERROR MESSAGE:
> Buildfile: C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples\
> common_build.xml
>  [loadfile] Do not set property srcbuild.classpath as its length is 0.
> BUILD FAILED
> Target "war" does not exist in the project "cxf  build file".
> Total time: 1 second
> I checked "common_build.xml" and verified that indeed there is no target name line like:
> <target name="war">
> There is a line
>         <antcall target="war"/>
> but this does not appear to be the same thing.
> Some research suggested that the default build option would create the war file.
> I issued the command:
> C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples>ant -buildf
> ile common_build.xml
> ERROR MESAGE:
> Buildfile: C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples\
> common_build.xml
>  [loadfile] Do not set property srcbuild.classpath as its length is 0.
> maybe.generate.code:
>  [loadfile] Do not set property srcbuild.classpath as its length is 0.
> BUILD FAILED
> C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples\common_buil
> d.xml:120: The following error occurred while executing this line:
> Target "generate.code" does not exist in the project "cxf  build file".
> Total time: 1 second
> I decided to give up trying to build all of the Apache CXF 2.4.2 samples at once.
> I changed directory to:
> "C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples\java_first_jaxws". 
> I would now try to build just this one sample.
> The README.txt file begins with:
> "Java First demo using jax-ws APIs and jsr-181"
> The environment was correct, so I proceeded onward!
> later in the README.txt file:
> "Building and running the demo using ant"
> From the base directory of this sample (i.e., where this README file is
> located), the Ant build.xml file can be used to build and run the demo.
> The server and client targets automatically build the demo.
> Using either UNIX or Windows:
>   ant server  (from one command line window)
>   ant client  (from a second command line window)
> I issued the command:
> C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples\java_first_
> jaxws>ant server
> ERROR MESSAGE:
> Buildfile: C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples\
> java_first_jaxws\build.xml
>  [loadfile] Do not set property srcbuild.classpath as its length is 0.
> maybe.generate.code:
> compile:
>     [javac] C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples
> \common_build.xml:128: warning: 'includeantruntime' was not set, defaulting to b
> uild.sysclasspath=last; set to false for repeatable builds
>     [javac] Compiling 9 source files to C:\Program Files\Apache Software Foundat
> ion\apache-cxf-2.4.2\samples\java_first_jaxws\build\classes
>     [javac] javac: invalid flag: Files\Apache
>     [javac] Usage: javac <options> <source files>
>     [javac] use -help for a list of possible options
> BUILD FAILED
> C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples\common_buil
> d.xml:128: Compile failed; see the compiler error output for details.
> Total time: 1 second
> I issued the command:
> C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples\java_first_
> jaxws>ant client
> ERROR MESSAGE:
> Buildfile: C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples\
> java_first_jaxws\build.xml
>  [loadfile] Do not set property srcbuild.classpath as its length is 0.
> maybe.generate.code:
> compile:
>     [javac] C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples
> \common_build.xml:128: warning: 'includeantruntime' was not set, defaulting to b
> uild.sysclasspath=last; set to false for repeatable builds
>     [javac] Compiling 9 source files to C:\Program Files\Apache Software Foundat
> ion\apache-cxf-2.4.2\samples\java_first_jaxws\build\classes
>     [javac] javac: invalid flag: Files\Apache
>     [javac] Usage: javac <options> <source files>
>     [javac] use -help for a list of possible options
> BUILD FAILED
> C:\Program Files\Apache Software Foundation\apache-cxf-2.4.2\samples\common_buil
> d.xml:128: Compile failed; see the compiler error output for details.
> Total time: 1 second
> There would appear to be an issue with the Microsoft passion for putting spaces in the path. I read many warnings about not using quotes for any of the paths in the environment for fear of breaking ant.
> I would like to compile, run, and use these samples.
> Can anyone out there help me?
>  

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira