The old Google Groups will be going away soon, but your browser is incompatible with the new version.
building Railo from source error
 There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic. There was an error processing your request. Please try again. Standard view   View as tree
 14 messages
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful

From:
To:
Cc:
Followup To:
 Add Cc | Add Followup-to | Edit Subject
Subject:
 Validation: For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon.

More options Feb 27 2012, 12:48 am
From: Igal <d...@21solutions.net>
Date: Sun, 26 Feb 2012 21:48:04 -0800 (PST)
Local: Mon, Feb 27 2012 12:48 am
Subject: building Railo from source error

I'm trying to build Railo from source and I keep getting an error.

build it with JDK1.6.0_31

the error I'm getting is  *cannot find symbol**: class ByteInputStream*

(I tried with JDK1.5 also, just in case, I get there another error which
makes sense as Railo3.3 should be compiled with JDK1.6 as far as I know)

is that a classpath issue?

any ideas?

Buildfile:
init:
[echo] ***** Start Railo build process. *****
clean:
[echo] Deleting build and dist
[delete] Deleting directory
[delete] Deleting directory
getInfo:
[echo] Extracting version information from file
src/railo/runtime/Info.ini
[echo] Version is: 3.3.2.003.rc
clean:
[echo] Deleting build and dist
[delete] Deleting directory
[delete] Deleting directory
clean:
[echo] Deleting build and dist
master:
[echo] ***** Building railo-loader.jar *****
clean:
[echo] Deleting build and dist
init:
[echo] Creating the build and dist directories.
[mkdir] Created dir:
[mkdir] Created dir:
compile:
[echo] Compile the RailoLoader src.
[javac]
warning: 'includeantruntime' was not set, defaulting to
build.sysclasspath=last; set to false for repeatable builds
[javac] Compiling 192 source files to
[javac] Note: Some input files use or override a deprecated API.
[javac] Note: Recompile with -Xlint:deprecation for details.
[javac] Note: Some input files use unchecked or unsafe operations.
[javac] Note: Recompile with -Xlint:unchecked for details.
package:
[echo] Packaging the railo-loader.jar file.
[jar] Building jar:
install:
[echo] Copy the railo-loader.jar to the Railo core lib directory.
[copy] Copying 1 file to
[echo] ***** Building Railo core.rc *****
getInfo:
[echo] Extracting version information from file
src/railo/runtime/Info.ini
[echo] Version is: 3.3.2.003.rc
clean:
[echo] Deleting build and dist
init:
[echo] Creating the build, admin and dist directories.
[mkdir] Created dir:
[mkdir] Created dir:
[mkdir] Created dir:
compile:
[echo] Compile Railo src.
[javac]
warning: 'includeantruntime' was not set, defaulting to
build.sysclasspath=last; set to false for repeatable builds
[javac] Compiling 2306 source files to
[javac]
warning: sun.management.VMManagement is Sun proprietary API and may be
removed in a future release
[javac] import sun.management.VMManagement;
[javac]                      ^
[javac]
package com.sun.xml.internal.messaging.saaj.util does not exist
[javac] import com.sun.xml.internal.messaging.saaj.util.ByteInputStream;
[javac]                                                ^
[javac]
warning: sun.management.VMManagement is Sun proprietary API and may be
removed in a future release
[javac]     VMManagement management = (VMManagement)
jvmField.get(mxbean);
[javac]     ^
[javac]
warning: sun.management.VMManagement is Sun proprietary API and may be
removed in a future release
[javac]     VMManagement management = (VMManagement)
jvmField.get(mxbean);
[javac]                                ^
[javac]
warning: non-varargs call of varargs method with inexact argument type for
last parameter;
[javac] cast to java.lang.Object for a varargs call
[javac] cast to java.lang.Object[] for a non-varargs call and to
suppress this warning
[javac] return m.invoke(o,null);
[javac]                   ^
[javac]
*railo-java\railo-core\src\railo\runtime\text\pdf\PDFDocument.java:381:
cannot find symbol*
[javac] *symbol  : class ByteInputStream*
[javac] location: class railo.runtime.text.pdf.PDFDocument
[javac] doc= PDDocument.load(new ByteInputStream(barr,0,barr.length));
[javac]                          ^
[javac]
*railo-java\railo-core\src\railo\runtime\text\pdf\PDFDocument.java:385:
cannot find symbol*
[javac] *symbol  : class ByteInputStream*
[javac] location: class railo.runtime.text.pdf.PDFDocument
ByteInputStream(IOUtil.toBytes(resource),0,barr.length));
[javac]                          ^
[javac] Note: Some input files use or override a deprecated API.
[javac] Note: Recompile with -Xlint:deprecation for details.
[javac] Note: Some input files use unchecked or unsafe operations.
[javac] Note: Recompile with -Xlint:unchecked for details.
[javac] 3 errors
[javac] 4 warnings

*BUILD FAILED*
The following error occurred while executing this line:
*railo-java\railo-core\build.xml:57: Compile failed; see the compiler error
output for details*.

Total time: 15 seconds

line railo-core\build.xml:57 is the javac command and reads as follows:

<javac srcdir="${src.dir}" destdir="${build.dir}/classes"
encoding="ISO-8859-1" fork="true" memorymaximumsize="512m">

You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
More options Feb 27 2012, 2:13 am
From: Denny <de...@getrailo.com>
Date: Mon, 27 Feb 2012 00:13:24 -0700
Local: Mon, Feb 27 2012 2:13 am
Subject: Re: [railo] building Railo from source error
On 2/26/12 10:48 PM, Igal wrote:

> I'm trying to build Railo from source and I keep getting an error.

> build it with JDK1.6.0_31

> the error I'm getting is  *cannot find symbol**: class ByteInputStream*

> (I tried with JDK1.5 also, just in case, I get there another error which
> makes sense as Railo3.3 should be compiled with JDK1.6 as far as I know)

> is that a classpath issue?

> any ideas?

Looks like a JDK issue.  Are you sure you were using 1.6?  It can be
kind of hard to determine sometimes.

If you are feeling brave, there is this:

Which has some built-in checks for JDK version (and better yet, does not
require a JDK-- a JRE should be enough (uses ECF compiler)).

Just download the zip and run the ./railobuild or railobuild.bat file.

jGit will download the sources, etc., and you can (theoretically) easily
pick the version to build (defaults to the latest 3.3).

HIH!

:Denny

--
Railo Technologies: getrailo.com   Professional Open Source
Skype: valliantster (505)510.1336  de...@getrailo.com
GnuPG-FP: DDEB 16E1 EF43 DCFD 0AEE 5CD0 964B B7B0 1C22 CB62

You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
More options Feb 27 2012, 2:28 am
From: Igal <d...@21solutions.net>
Date: Sun, 26 Feb 2012 23:28:46 -0800 (PST)
Local: Mon, Feb 27 2012 2:28 am
Subject: Re: [railo] building Railo from source error

hi Denny,

thanks for your reply.  I get an error from your build script.  output
below.

Igal

1. Build Railo
2. Build and Test
3. List available targets
4. Update project
5. Run Target
6. Quit

Enter option 1, 2, 3, 4, 5 or 6 :
1

BUILD FAILED
ld\build.xml:52: The following error occurred while executing this line:
ld\util\zbuild.xml:69: Unable to load a script engine manager
(org.apache.bsf.BS
FManager or javax.script.ScriptEngineManager)

Total time: 0 seconds

Buildfile:
[propertyfile] Updating property file:
[echo] 2012/02/26 11:24:11
Trying to override old definition of task classloader

press any key ...
Press any key to continue . . .

You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
More options Feb 27 2012, 2:40 am
From: Igal <d...@21solutions.net>
Date: Sun, 26 Feb 2012 23:40:33 -0800 (PST)
Local: Mon, Feb 27 2012 2:40 am
Subject: Re: [railo] building Railo from source error

p.s.  -- I'm pretty sure the JDK is 1.6 -- after failing to build in
Eclipse EE, I opened a command prompt, set the %JAVA_HOME% variable
explicitly and ran the ant build from that command window.

>echo %java_home% outputs the correct value of: C:\Java\jdk1.6.0_31

Looks like a JDK issue.  Are you sure you were using 1.6?  It can be

You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
More options Feb 27 2012, 3:10 am
From: Denny <de...@getrailo.com>
Date: Mon, 27 Feb 2012 01:10:02 -0700
Local: Mon, Feb 27 2012 3:10 am
Subject: Re: [railo] building Railo from source error
On 2/27/12 12:40 AM, Igal wrote:

> p.s.  -- I'm pretty sure the JDK is 1.6 -- after failing to build in
> Eclipse EE, I opened a command prompt, set the %JAVA_HOME% variable
> explicitly and ran the ant build from that command window.

>>echo %java_home% outputs the correct value of: C:\Java\jdk1.6.0_31

Well poop on a stake! (to turn a phrase ;])  I was hoping that would
"just work" for ya.  :(

It works for me on OS X and, last I tried, Ubuntu & Windows.  And that
error looks like it can't find the js.jar that is there in the
build/ant/lib folder...  gah.

Got any details on your environment that might help me finger it out?

I'm not sure what is going on (which isn't unusual, but still).  =]

:Denny

--
Railo Technologies: getrailo.com   Professional Open Source
Skype: valliantster (505)510.1336  de...@getrailo.com
GnuPG-FP: DDEB 16E1 EF43 DCFD 0AEE 5CD0 964B B7B0 1C22 CB62

You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
More options Feb 27 2012, 3:29 am
From: Igal <d...@21solutions.net>
Date: Mon, 27 Feb 2012 00:29:30 -0800 (PST)
Local: Mon, Feb 27 2012 3:29 am
Subject: Re: [railo] building Railo from source error

oops.  sorry.  the JDK1.6 statement below was with regards to your original
question.

when I was about to reply to this one I realized that I should set the
JAVA_HOME to 1.6 for your build as well -- so I did -- and now it's running
(currently in JGit step).

thanks again :)

ideally though, I'd like to be able to build the project in Eclipse so if
you (or anyone) has an idea why I get the original error I reported it'd be
great.

Igal

...

You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
More options Feb 27 2012, 4:07 am
From: Denny <de...@getrailo.com>
Date: Mon, 27 Feb 2012 02:07:15 -0700
Local: Mon, Feb 27 2012 4:07 am
Subject: Re: [railo] building Railo from source error
On 2/27/12 1:29 AM, Igal wrote:

> oops.  sorry.  the JDK1.6 statement below was with regards to your
> original question.

> when I was about to reply to this one I realized that I should set the
> JAVA_HOME to 1.6 for your build as well -- so I did -- and now it's
> running (currently in JGit step).

Grrr!  I have a whole little segment in there that's supposed to say
"hey, this needs java version X", X being whatever version is needed for
the build (we'll be running into this with 7 soon enough).

> thanks again :)

Thanks for trying it!

> ideally though, I'd like to be able to build the project in Eclipse so
> if you (or anyone) has an idea why I get the original error I reported
> it'd be great.

It totally rings a bell, but sadly that bell is "incorrect java
version", which perhaps is the wrong bell.

If it comes to me I'll holler.  :)

:Denny

--
Railo Technologies: getrailo.com   Professional Open Source
Skype: valliantster (505)510.1336  de...@getrailo.com
GnuPG-FP: DDEB 16E1 EF43 DCFD 0AEE 5CD0 964B B7B0 1C22 CB62

You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
More options Feb 27 2012, 1:11 pm
From: Igal <d...@21solutions.net>
Date: Mon, 27 Feb 2012 10:11:06 -0800 (PST)
Local: Mon, Feb 27 2012 1:11 pm
Subject: Re: [railo] building Railo from source error

ok, thank you.  I will try to play with it some more.

your script worked really well.  it'd be nice if the build script (and doc)
in the main projects could be improved.

as a matter of fact my main purpose in trying to build this in Eclipse was
so that I can improve the docs on building from source.

also, it'd be nice if branch 3.2 could be removed from Github and then
we'll know that JDK1.6 is the only version we need (until Railo Apollo, of
course)

You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
More options Feb 27 2012, 2:58 pm
From: Denny <de...@getrailo.com>
Date: Mon, 27 Feb 2012 12:58:18 -0700
Local: Mon, Feb 27 2012 2:58 pm
Subject: Re: [railo] building Railo from source error
On 2/27/12 11:11 AM, Igal wrote:

> ok, thank you.  I will try to play with it some more.

> your script worked really well.  it'd be nice if the build script (and
> doc) in the main projects could be improved.

That's the idea.  What did you think of the README?  Feel free to
fork/edit it if you want!

I'd love to add an Eclipse portion, covering the debug-runner as well.
There's nothing like being able to click on a stack trace and have it
open the source file in the editor. :)  I think we should have a video
of the whole process too.

> as a matter of fact my main purpose in trying to build this in Eclipse
> was so that I can improve the docs on building from source.

> also, it'd be nice if branch 3.2 could be removed from Github and then
> we'll know that JDK1.6 is the only version we need (until Railo Apollo,
> of course)

It is standard to keep at least tags of the various versions so that
people who (for whatever reason) are on older versions can see what is
going on in the version they're using.  I know it seems silly that it
could be the case with an open source project which is so easy to
update, but there are reasons (usually involving management ;)).

:Denny

--
Railo Technologies: getrailo.com   Professional Open Source
Skype: valliantster (505)510.1336  de...@getrailo.com
GnuPG-FP: DDEB 16E1 EF43 DCFD 0AEE 5CD0 964B B7B0 1C22 CB62

You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
More options Feb 27 2012, 3:26 pm
From: Igal <d...@21solutions.net>
Date: Mon, 27 Feb 2012 12:26:41 -0800 (PST)
Local: Mon, Feb 27 2012 3:26 pm
Subject: Re: [railo] building Railo from source error

your build script is really cool.  I was especially impressed with the use
of Jetty-Runner as opposed to running Jetty in a whole separate process.

the README is good albeit a little advanced.  maybe after I get a better
understanding of that build process I will have some suggestions for
changes, but for the time being it seems pretty good.

being able to debug in an IDE like you suggested would be awesome!  and
there's definitely room for video tutorials.  I was thinking of creating
some myself and hopefully will get to that at some point in the near future.

so is this build project planned to go into the main Railo project on
Github?

can it be used to build from local folders?  say that I make some changes
to code locally and then want to build it, is it possible with these
scripts?

You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
More options Feb 27 2012, 3:51 pm
From: Denny <de...@getrailo.com>
Date: Mon, 27 Feb 2012 13:51:01 -0700
Local: Mon, Feb 27 2012 3:51 pm
Subject: Re: [railo] building Railo from source error
On 2/27/12 1:26 PM, Igal wrote:

> your build script is really cool.  I was especially impressed with the
> use of Jetty-Runner as opposed to running Jetty in a whole separate process.

Thanks!  I love jetty-runner!  I slathered it with error checks to try
to avoid "ghost processes" if there is a build failure in that portion
of code, to make CI more bulletproof.

> the README is good albeit a little advanced.  maybe after I get a better
> understanding of that build process I will have some suggestions for
> changes, but for the time being it seems pretty good.

Rock'n.  Contributions are always welcome!  The complete picture is too
big to fit in one page, I think we'll need to break the bits down and
use an index of topics, which we should pull from the wiki maybe (or at
least link up the content w/docs in github).

> being able to debug in an IDE like you suggested would be awesome!  and
> there's definitely room for video tutorials.  I was thinking of creating
> some myself and hopefully will get to that at some point in the near future.

> so is this build project planned to go into the main Railo project on
> Github?

That's the idea.  We want it to be as painless as possible to get from
nothing, to pull requests.  :)

> can it be used to build from local folders?  say that I make some
> changes to code locally and then want to build it, is it possible with
> these scripts?

Totally!  To be safe, commit your changes locally before running a
build, so they will be there even if you do a "forced checkout" (happens
when you specify a different branch or tag to build).  The plain "build"
command won't check out anything if the source is already there (thus
builds after that first build are *much* faster =]).

:Denny

--
Railo Technologies: getrailo.com   Professional Open Source
Skype: valliantster (505)510.1336  de...@getrailo.com
GnuPG-FP: DDEB 16E1 EF43 DCFD 0AEE 5CD0 964B B7B0 1C22 CB62

You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
More options Feb 27 2012, 7:59 pm
From: Igal <d...@21solutions.net>
Date: Mon, 27 Feb 2012 16:59:56 -0800 (PST)
Local: Mon, Feb 27 2012 7:59 pm
Subject: Re: [railo] building Railo from source error

very cool!

I guess I will have to sharpen my Git skills before I can use it though.

as for my original problem here -- I have Uninstalled (and deleted all
registry entries of) all other versions of JDK/JRE and the only thing left
on my machine (Windows 7 32bit) is JDK1.6.0_31 -- to ensure that I'm using
the correct JDK.  I am still getting the same error.

so I did some digging, and the class in question is: *
com.sun.xml.internal.messaging.saaj.util.ByteInputStream*  (
http://www.docjar.com/html/api/com/sun/xml/internal/messaging/saaj/ut...) --
the weird part is that class is part of the runtime (rt.jar) of the JDK/JRE
and it Does exist on my machine in %Java%\jre\live\rt.jar

looking deeper into that class, it looks like it's just a thin wrapper
around java.io.ByteArrayInputStream, so I opened up the only class that
uses this one: *railo.runtime.text.pdf.PDFDocument* and replaced *
ByteInputStream* with *ByteArrayInputStream*

*line 35-:   import
com.sun.xml.internal.messaging.saaj.util.ByteInputStream;
line 35+:   import java.io.ByteArrayInputStream;

line 381-:  doc= PDDocument.load(new ByteInputStream
(barr,0,barr.length));
line 381+:  doc= PDDocument.load(new
ByteArrayInputStream(barr,0,barr.length));

line 385-:  doc= PDDocument.load(new ByteInputStream
(IOUtil.toBytes(resource),0,barr.length));
line 385+:  doc= PDDocument.load(new ByteArrayInputStream**
(IOUtil.toBytes(resource),0,barr.length));*

*and now the project builds!*

am I the only one this happens to?  any idea why this would happen?
weird...

Igal

You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
More options Feb 27 2012, 9:11 pm
From: Denny <de...@getrailo.com>
Date: Mon, 27 Feb 2012 19:11:59 -0700
Local: Mon, Feb 27 2012 9:11 pm
Subject: Re: [railo] building Railo from source error
On 2/27/12 5:59 PM, Igal wrote:
...

> am I the only one this happens to?  any idea why this would happen?
> weird...

Ah!  Now I remember that one (I think).

Which makes it even odder, because the problem is that the class in
question is an internal Sun class, which Eclipse doesn't have trouble
including (one of the reasons I like ECJ), but that Sun compilers can
have trouble including (and not always) because it doesn't import
correctly (and again, not always *shrug*).

Are you using custom compiler options in Eclipse?  Maybe specified the
Sun compiler (javac) instead of the Eclipse compiler (ECJ)?

I think that would explain the troubles, and why the new build script
worked where the old one didn't (old one uses javac by default, though
you can configure Ant to use ECJ with some compiler properties).

For giggles, you could try importing the Railo projects into a new
Eclipse workspace, and see if things compile using the defaults... or
maybe just check your build options, and see what it's using now.

:Denny

--
Railo Technologies: getrailo.com   Professional Open Source
Skype: valliantster (505)510.1336  de...@getrailo.com
GnuPG-FP: DDEB 16E1 EF43 DCFD 0AEE 5CD0 964B B7B0 1C22 CB62

You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
More options Feb 27 2012, 10:11 pm
From: Igal <d...@21solutions.net>
Date: Mon, 27 Feb 2012 19:11:27 -0800 (PST)
Local: Mon, Feb 27 2012 10:11 pm
Subject: Re: [railo] building Railo from source error

I don't think that I specified explicitly the Sun compiler, but anything is
possible.  especially since it didn't work from the beginning and I started
tweaking things in an attempt to "fix" it.  I'm learning how to use Eclipse
as I go (personally prefer NetBeans).

I tried creating a new workspace and importing the projects there.  this
time, unlike before, I checked the box that reads "copy projects".  after
fixing the build-paths I had to manually copy the libs folder (I guess it's
specified in the build script).  this time it worked like you suggested.

the question is that if the *
com.sun.xml.internal.messaging.saaj.util.ByteInputStream* doesn't do much,
and the  *PDDocument.load( InputStream in )* doesn't care for the
implementation -- maybe changing to *java.io.ByteArrayInputStream* will
solve similar problems in the future.  probably a question for Michael?
maybe I'll open a ticket in the JIRA.

anyway, thank you Denny, you've been a great help.  I owe you a beer (more
like a six pack by now).

Igal

You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
 End of messages
 « Back to Discussions « Newer topic Older topic »