zazi1991i / harviewer

Automatically exported from code.google.com/p/harviewer
0 stars 0 forks source link

ant build fails because Windows specific path locations in build.xml #8

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Follow Installation instructions on a linux machine 
http://code.google.com/p/harviewer/wiki/Installation

What is the expected output? 
Expect to have it to build a /release folder

What do you see instead?
Buildfile: build.xml

BUILD FAILED
/tmp/hartmp/harviewer/build.xml:36: /tmp/harviewer/C:/www/dojo/shrink-safe
not found.

Total time: 0 seconds

What version of the product are you using? 
r84

On what operating system?
CentOS

Original issue reported on code.google.com by anthony....@gmail.com on 3 May 2010 at 6:39

GoogleCodeExporter commented 8 years ago
additional details on versions

Apache Ant version 1.6.5 compiled on January 6 2007
Buildfile: build.xml
Detected Java version: 1.5 in: 
/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/jre
Detected OS: Linux
parsing buildfile /tmp/harviewer/build.xml with URI = 
file:///tmp/harviewer/build.xml
Project base dir set to: /tmp/harviewer
 [property] Loading /tmp/harviewer/ant.properties

Original comment by anthony....@gmail.com on 3 May 2010 at 6:45

GoogleCodeExporter commented 8 years ago
Patch committed at R85
Please verify

Thanks for the report!
Honza

Original comment by odva...@gmail.com on 5 May 2010 at 7:33

GoogleCodeExporter commented 8 years ago
I am having difficulty building this after I did an svn up (I wasnt able also to
built due to the improper paths).

This is what I a getting when I run ant:

BUILD FAILED
java.lang.NoSuchMethodError:
org.mozilla.javascript.Context.compressScript(Lorg/mozilla/javascript/Script;I)L
java/lang/String;
    at
com.webpanes.tools.ant.taskdefs.CompressJS$ContextActionShell.compressFiles(Comp
ressJS.java:135)
    at
com.webpanes.tools.ant.taskdefs.CompressJS$ContextActionShell.run(CompressJS.jav
a:103)
    at org.mozilla.javascript.Context.call(Context.java:499)
    at org.mozilla.javascript.ContextFactory.call(ContextFactory.java:511)
    at com.webpanes.tools.ant.taskdefs.CompressJS.launchCompressShell(CompressJS.java:280)
    at com.webpanes.tools.ant.taskdefs.CompressJS.execute(CompressJS.java:272)
    at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
    at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
    at org.apache.tools.ant.Task.perform(Task.java:348)
    at org.apache.tools.ant.Target.execute(Target.java:357)
    at org.apache.tools.ant.Target.performTasks(Target.java:385)
    at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
    at org.apache.tools.ant.Project.executeTarget(Project.java:1306)
    at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
    at org.apache.tools.ant.Project.executeTargets(Project.java:1189)
    at org.apache.tools.ant.Main.runBuild(Main.java:758)
    at org.apache.tools.ant.Main.startAnt(Main.java:217)
    at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
    at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)

Original comment by phobouli...@gmail.com on 5 May 2010 at 11:23

GoogleCodeExporter commented 8 years ago
It looks like you have wrong version of compress-js.jar
Are you sure the one in:

<root>/build-tools/dojo/shrink-safe/compress-js.jar

is used?

Also make sure that custom_rhino.jar (from the same directory is used).

Honza

Original comment by odva...@gmail.com on 5 May 2010 at 11:44

GoogleCodeExporter commented 8 years ago
I just did another svn checkout and still get the same error. I did try to 
setup the
shrink-safe but thats why I did another checkout again to make sure I did not 
have
any changes my local repo.

Original comment by phobouli...@gmail.com on 5 May 2010 at 11:50

GoogleCodeExporter commented 8 years ago
I just build succesfuly on Linux (ubuntu). The problem seems to be Mac OS 10.6
specific. Thats what I am using.

Original comment by phobouli...@gmail.com on 5 May 2010 at 12:09

GoogleCodeExporter commented 8 years ago
It seems that not all needed jar files are being included in the process 
correctly
(for Mac OS).

Versions:
Mac OS 10.6.3

Apache Ant version 1.7.1 compiled on September 22 2009

java version "1.6.0_17"
Java(TM) SE Runtime Environment (build 1.6.0_17-b04-248-10M3025)
Java HotSpot(TM) 64-Bit Server VM (build 14.3-b01-101, mixed mode)

Any idea if and how I can make them being included correctly in the build.xml 
file ?

Original comment by phobouli...@gmail.com on 5 May 2010 at 1:57

GoogleCodeExporter commented 8 years ago
Hi Honza, 
Almost there I think. Here's the new error from the build of revision 98. 
Wondering
if this is OS specific to me and CentOS? I'm not well versed in java classes 
and the
such. Plus CentOS does not have cutting edge releases, for example ant 1.6.5 is 
the
only version i can install from yum.

By the way, the first time I got my build issue, I just copied the entire repo
contents into the web space and it seems to work just fine without building, 
albeit
the @VERSION@ psuedo var was not replaced, that's all i noticed but nothing 
seems to
be broken if I just copy the whole thing into the web space.

Anywho, here's my build log/error. Thanks for the great viewer by the way.

[root@server /tmp/harviewer]ant
Buildfile: build.xml

clean:

build:
    [mkdir] Created dir: /tmp/harviewer/release
     [copy] Copying 4 files to /tmp/harviewer/release/examples
     [copy] Copying 23 files to /tmp/harviewer/release/images
     [copy] Copying 1 file to /tmp/harviewer/release
     [copy] Copying 1 file to /tmp/harviewer/release
[compress-js] Compress JS task provided by LCA Soft Ltd (www.lcasoft.com).
[compress-js] Compressing 20 files to /tmp/harviewer/release/temp
     [move] Moving 1 file to /tmp/harviewer/release/temp
    [jsmin] Minimizing /tmp/harviewer/domplate.min.js
     [move] Moving 1 file to /tmp/harviewer/release/temp
     [copy] Copying 10 files to /tmp/harviewer/release/temp
     [copy] Copying 1 file to /tmp/harviewer/release/temp
     [copy] Copying 1 file to /tmp/harviewer/release/temp
     [xslt] DEPRECATED - xalan processor is deprecated. Use trax instead.
     [xslt] DEPRECATED - xslp processor is deprecated. Use trax instead.
     [xslt] java.lang.ClassNotFoundException:
org.apache.tools.ant.taskdefs.optional.XslpLiaison
     [xslt]     at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
     [xslt]     at java.security.AccessController.doPrivileged(Native Method)
     [xslt]     at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
     [xslt]     at java.lang.ClassLoader.loadClass(ClassLoader.java:319)
     [xslt]     at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
     [xslt]     at java.lang.ClassLoader.loadClass(ClassLoader.java:264)
     [xslt]     at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:332)
     [xslt]     at java.lang.Class.forName0(Native Method)
     [xslt]     at java.lang.Class.forName(Class.java:186)
     [xslt]     at
org.apache.tools.ant.taskdefs.XSLTProcess.loadClass(XSLTProcess.java:419)
     [xslt]     at
org.apache.tools.ant.taskdefs.XSLTProcess.resolveProcessor(XSLTProcess.java:397)
     [xslt]     at
org.apache.tools.ant.taskdefs.XSLTProcess.getLiaison(XSLTProcess.java:619)
     [xslt]     at
org.apache.tools.ant.taskdefs.XSLTProcess.execute(XSLTProcess.java:212)
     [xslt]     at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
     [xslt]     at org.apache.tools.ant.Task.perform(Task.java:364)
     [xslt]     at org.apache.tools.ant.Target.execute(Target.java:341)
     [xslt]     at org.apache.tools.ant.Target.performTasks(Target.java:369)
     [xslt]     at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1216)
     [xslt]     at org.apache.tools.ant.Project.executeTarget(Project.java:1185)
     [xslt]     at
org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:
40)
     [xslt]     at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
     [xslt]     at org.apache.tools.ant.Main.runBuild(Main.java:668)
     [xslt]     at org.apache.tools.ant.Main.startAnt(Main.java:187)
     [xslt]     at org.apache.tools.ant.launch.Launcher.run(Launcher.java:246)
     [xslt]     at org.apache.tools.ant.launch.Launcher.main(Launcher.java:67)
     [xslt] java.lang.ClassNotFoundException:
org.apache.tools.ant.taskdefs.optional.XalanLiaison
     [xslt]     at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
     [xslt]     at java.security.AccessController.doPrivileged(Native Method)
     [xslt]     at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
     [xslt]     at java.lang.ClassLoader.loadClass(ClassLoader.java:319)
     [xslt]     at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
     [xslt]     at java.lang.ClassLoader.loadClass(ClassLoader.java:264)
     [xslt]     at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:332)
     [xslt]     at java.lang.Class.forName0(Native Method)
     [xslt]     at java.lang.Class.forName(Class.java:186)
     [xslt]     at
org.apache.tools.ant.taskdefs.XSLTProcess.loadClass(XSLTProcess.java:419)
     [xslt]     at
org.apache.tools.ant.taskdefs.XSLTProcess.resolveProcessor(XSLTProcess.java:402)
     [xslt]     at
org.apache.tools.ant.taskdefs.XSLTProcess.getLiaison(XSLTProcess.java:616)
     [xslt]     at
org.apache.tools.ant.taskdefs.XSLTProcess.execute(XSLTProcess.java:212)
     [xslt]     at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
     [xslt]     at org.apache.tools.ant.Task.perform(Task.java:364)
     [xslt]     at org.apache.tools.ant.Target.execute(Target.java:341)
     [xslt]     at org.apache.tools.ant.Target.performTasks(Target.java:369)
     [xslt]     at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1216)
     [xslt]     at org.apache.tools.ant.Project.executeTarget(Project.java:1185)
     [xslt]     at
org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:
40)
     [xslt]     at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
     [xslt]     at org.apache.tools.ant.Main.runBuild(Main.java:668)
     [xslt]     at org.apache.tools.ant.Main.startAnt(Main.java:187)
     [xslt]     at org.apache.tools.ant.launch.Launcher.run(Launcher.java:246)
     [xslt]     at org.apache.tools.ant.launch.Launcher.main(Launcher.java:67)

BUILD FAILED
/tmp/harviewer/build.xml:121: java.lang.ClassNotFoundException:
org.apache.tools.ant.taskdefs.optional.TraXLiaison

Total time: 3 seconds

Original comment by anthony....@gmail.com on 5 May 2010 at 5:13

GoogleCodeExporter commented 8 years ago
after a little searchin, I probably need to install this package.

ant-trax.x86_64 : Optional trax tasks for ant

Original comment by anthony....@gmail.com on 5 May 2010 at 5:24

GoogleCodeExporter commented 8 years ago
Yeah ok that WAS it! I was just missing that optional trax package and was OS
specific. The build.xml file is just fine.

[root@server /tmp/harviewer]ant
Buildfile: build.xml

clean:

build:
    [mkdir] Created dir: /tmp/harviewer/release
     [copy] Copying 4 files to /tmp/harviewer/release/examples
     [copy] Copying 23 files to /tmp/harviewer/release/images
     [copy] Copying 1 file to /tmp/harviewer/release
     [copy] Copying 1 file to /tmp/harviewer/release
[compress-js] Compress JS task provided by LCA Soft Ltd (www.lcasoft.com).
[compress-js] Compressing 20 files to /tmp/harviewer/release/temp
     [move] Moving 1 file to /tmp/harviewer/release/temp
    [jsmin] Minimizing /tmp/harviewer/domplate.min.js
     [move] Moving 1 file to /tmp/harviewer/release/temp
     [copy] Copying 10 files to /tmp/harviewer/release/temp
     [copy] Copying 1 file to /tmp/harviewer/release/temp
     [copy] Copying 1 file to /tmp/harviewer/release/temp
     [xslt] Processing /tmp/harviewer/index.php to /tmp/harviewer/release/index.php
     [xslt] Loading stylesheet /tmp/harviewer/xslt/index.xsl
     [xslt] Processing /tmp/harviewer/har.service.pagelist.php to
/tmp/harviewer/release/pagelist.php
     [xslt] Loading stylesheet /tmp/harviewer/xslt/pagelist.xsl
     [xslt] Processing /tmp/harviewer/har.service.loader.php to
/tmp/harviewer/release/loader.php
     [xslt] Loading stylesheet /tmp/harviewer/xslt/loader.xsl
     [copy] Copying 1 file to /tmp/harviewer/release/downloadify/media
     [copy] Copying 1 file to /tmp/harviewer/release/excanvas
   [delete] Deleting directory /tmp/harviewer/release/temp
     [echo] HARViewer version: 1.1-8

BUILD SUCCESSFUL
Total time: 1 second

Original comment by anthony....@gmail.com on 5 May 2010 at 5:39

GoogleCodeExporter commented 8 years ago
Great!

Should we change the build.xml file, add the file into the HARViewer repository 
or
just improve instructions to help others with the build?

Honza

Original comment by odva...@gmail.com on 5 May 2010 at 6:03

GoogleCodeExporter commented 8 years ago
The build works but when I moved /release contents into my webspace it does not
render the page properly, it's completely blank. If I view source I can see the 
html
fine though. And it appears to be markup errors caused by "[xslt] Processing". 
Let me
know if I should make a new issue for this. So far I've only inspected and 
changed
the index.php but I suspect these types of errors could be on pagelist.php and
loader.ph since those were processed by ANT as well.

Here's what the header of index.php looked like after the build. Notice 
<script/>
tags and first <div>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>HTTP Archive Viewer 1.1-8</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta http-equiv="Pragma" content="no-cache" />
<meta http-equiv="Expires" content="-1" />
<script type="text/javascript" src="schema.js" preserve="true" 
xml:space="preserve" />
<link type="text/css" href="har.css" rel="StyleSheet" />
<script src="har.js" type="text/javascript" />
<!--[if IE]><script type="text/javascript"
src="excanvas/excanvas.compiled.js"></script><![endif]-->
</head>
<body>
<div id="content" version="1.1-8" ondragenter="HAR.Lib.cancelEvent(event);"
ondragover="HAR.Lib.cancelEvent(event);" 
ondrop="HAR.Tab.InputView.onDrop(event);" />

Changed to... basically 3 changes, </script> close tags added and closed <div
id="content" ..></div>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>HTTP Archive Viewer 1.1-8</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta http-equiv="Pragma" content="no-cache" />
<meta http-equiv="Expires" content="-1" />
<script type="text/javascript" src="schema.js" preserve="true"
xml:space="preserve"></script>
<link type="text/css" href="har.css" rel="StyleSheet" />
<script src="har.js" type="text/javascript"></script>
<!--[if IE]><script type="text/javascript"
src="excanvas/excanvas.compiled.js"></script><![endif]-->
</head>
<body>
<div id="content" version="1.1-8" ondragenter="HAR.Lib.cancelEvent(event);"
ondragover="HAR.Lib.cancelEvent(event);" 
ondrop="HAR.Tab.InputView.onDrop(event);"></div>

Also the textarea tag was changed from

<textarea id="sourceEditor" class="sourceEditor" cols="80" rows="5" />

to 

<textarea id="sourceEditor" class="sourceEditor" cols="80" rows="5"></textarea>

Hope this helps you. Again let me know if you suspect this is OS specific to not
having the latest version of Ant or something similar.

Original comment by anthony....@gmail.com on 5 May 2010 at 6:36

GoogleCodeExporter commented 8 years ago
Improving the instructions sounds like a good idea, maybe to just add the build
requirements like version of ant supported and the needed optional packages. 
Ant is
not installed by default with trax. At least not on CentOS.

On a side note, it would be cool if you removed the google analytics tracking 
from
the bottom or maybe just tell people it's there if your purpose is to track 
usage.
For example in ShowSlow it's there as well but there is a config option for it 
and
it's disabled by default.

Original comment by anthony....@gmail.com on 5 May 2010 at 6:46

GoogleCodeExporter commented 8 years ago
here's some more tag/markup problems for the other two pages.

processing issues from building in the order they appear on the page

pagelist.php :

<script type="text/javascript" src="schema.js" preserve="true" 
xml:space="preserve" />

<div id="pageList" version="@VERSION@">

<script type="text/javascript" src="schema.js" preserve="true" 
xml:space="preserve" />

<script src="har.js" type="text/javascript" />

loader.php issues:
<table id="content" version="@VERSION@" border="0" cellpadding="0" 
cellspacing="0">

Original comment by anthony....@gmail.com on 5 May 2010 at 6:58

GoogleCodeExporter commented 8 years ago
> On a side note, it would be cool if you removed the google analytics tracking 
from
> the bottom or maybe just tell people it's there if your purpose is to track 
usage.
> For example in ShowSlow it's there as well but there is a config option for 
it and
> it's disabled by default.
Yes, I was also thinking about this. Could you please report a new bug for it?
Thanks!

Honza

Original comment by odva...@gmail.com on 6 May 2010 at 6:04

GoogleCodeExporter commented 8 years ago
This bug should be fixed in HAR 1.1-9, R188
Please verify.

Thanks for the report!
Honza

Original comment by odva...@gmail.com on 6 Jun 2010 at 7:10

GoogleCodeExporter commented 8 years ago
Sorry, the revision is: R118
Honza

Original comment by odva...@gmail.com on 6 Jun 2010 at 7:11