Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Ant problem with 2.10M6
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.
flag
  9 messages - Collapse all  -  Translate all to Translated (View all originals)
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. Listen and type the numbers you hear
 
Alan Burlison  
View profile  
 More options Aug 3 2012, 7:13 pm
From: Alan Burlison <alan.burli...@gmail.com>
Date: Sat, 04 Aug 2012 00:13:58 +0100
Local: Fri, Aug 3 2012 7:13 pm
Subject: Ant problem with 2.10M6
I've just upgraded from 2.10M4 to 2.10M6 and my ant config which has
worked since 2.9 has stopped working.  The error I'm getting is:

/home/alanbur/scala/OLS/build.xml:13: The following error occurred while
executing this line:
/home/alanbur/scala/OLS/build-scala.xml:14: The following error occurred
while executing this line:
jar:file:/opt/scala/lib/scala-compiler.jar!/scala/tools/ant/antlib.xml:5: taskdef
A class needed by class scala.tools.ant.FastScalac cannot be found:
scala/reflect/internal/settings/MutableSettings$SettingValue using the
classloader
AntClassLoader[/opt/scala/lib/scala-library.jar:/opt/scala/lib/scala-compil er.jar]

Anyone have any ideas?

Thanks,

--
Alan Burlison
--


 
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.
Paolo Giarrusso  
View profile  
 More options Aug 3 2012, 9:56 pm
From: Paolo Giarrusso <p.giarru...@gmail.com>
Date: Fri, 3 Aug 2012 18:56:39 -0700 (PDT)
Local: Fri, Aug 3 2012 9:56 pm
Subject: Re: Ant problem with 2.10M6

This will be solved by adding on the CLASSPATH $SCALA_HOME/lib/
scala-reflect.jar:$SCALA_HOME/lib/scala-library.jar - before launching ant.

For instance, on a typical (Bourne) Unix shell, if CLASSPATH has already a
value, you can type:

export CLASSPATH=$SCALA_HOME/lib/scala-reflect.jar:$SCALA_HOME/
lib/scala-library.jar:$CLASSPATH

(replacing $SCALA_HOME by the actual path, probably).

I think that in fact for this problem, it's enough to have:

export CLASSPATH=$SCALA_HOME/lib/scala-reflect.jar:$CLASSPATH

but I also needed to add scala-library to fix a problem with running the
tests.
In general, when upgrading to -M5 or -M6, take a look at $SCALA_HOME/lib/,
since libraries have been split much more granularly. Actors have also been
split out from the main library for various reasons (the Akka actor library
is being integrated as an alternative, in some way).

Il giorno sabato 4 agosto 2012 01:13:58 UTC+2, Alan Burlison ha scritto:


 
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.
Alan Burlison  
View profile  
 More options Aug 7 2012, 6:15 am
From: Alan Burlison <alan.burli...@gmail.com>
Date: Tue, 07 Aug 2012 11:15:31 +0100
Local: Tues, Aug 7 2012 6:15 am
Subject: Re: [scala-user] Re: Ant problem with 2.10M6
On 04/08/2012 02:56, Paolo Giarrusso wrote:

> This will be solved by adding on the CLASSPATH $SCALA_HOME/lib/
> scala-reflect.jar:$SCALA_HOME/lib/scala-library.jar - before launching ant.

That was the hint I needed, thanks.  I've modified my ant file to add in
references to scala-reflect.jar as follows, and that's fixed the problem:

     <property name="scala.home" value="/opt/scala"/>

     <property name="scala.lib" value="${scala.home}/lib"/>
     <property name="scala.compiler"
value="${scala.lib}/scala-compiler.jar"/>
     <property name="scala.reflect" value="${scala.lib}/scala-reflect.jar"/>
     <property name="scala.library" value="${scala.lib}/scala-library.jar"/>

     <taskdef resource="scala/tools/ant/antlib.xml">
         <classpath>
             <pathelement location="${scala.library}"/>
             <pathelement location="${scala.reflect}"/>
             <pathelement location="${scala.compiler}"/>
         </classpath>
     </taskdef>

     <target name="scala-compile">
         <fsc
             srcdir="${src.java.dir}:${src.scala.dir}"
             destdir="${build.classes.dir}"
             classpath="${javac.classpath}:${scala.library}"
             target="jvm-${javac.target}"
             deprecation="${javac.deprecation}"
             unchecked="yes"
             encoding="${source.encoding}"
             addparams="-optimize -Xlint"
             force="yes"
             fork="no">
         </fsc>
     </target>

--
Alan Burlison
--


 
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.
Alan Burlison  
View profile  
 More options Aug 7 2012, 8:22 am
From: Alan Burlison <alan.burli...@gmail.com>
Date: Tue, 07 Aug 2012 13:22:22 +0100
Local: Tues, Aug 7 2012 8:22 am
Subject: Re: [scala-user] Re: Ant problem with 2.10M6
On 07/08/2012 11:15, Alan Burlison wrote:

> That was the hint I needed, thanks. I've modified my ant file to add in
> references to scala-reflect.jar as follows, and that's fixed the problem:

I spoke too soon.  It apparently works with the ant fsc task, but the
scalac task blows up:

uncaught exception during compilation: scala.reflect.internal.FatalError
scala.reflect.internal.FatalError: package reflect does not have a
member ClassManifest
        at
scala.reflect.internal.Definitions$DefinitionsClass.scala$reflect$internal$ Definitions$DefinitionsClass$$fatalMissingSymbol(Definitions.scala:979)
        at
scala.reflect.internal.Definitions$DefinitionsClass$$anonfun$getMember$1.ap ply(Definitions.scala:1008)
        at
scala.reflect.internal.Definitions$DefinitionsClass$$anonfun$getMember$1.ap ply(Definitions.scala:1003)
        at scala.reflect.internal.Symbols$Symbol.orElse(Symbols.scala:2332)
        at
scala.reflect.internal.Definitions$DefinitionsClass.getMember(Definitions.s cala:1002)
        at
scala.reflect.internal.Definitions$DefinitionsClass.getMemberType(Definitio ns.scala:1027)
        at
scala.reflect.internal.Definitions$DefinitionsClass.PartialManifestClass$lz ycompute(Definitions.scala:467)
        at
scala.reflect.internal.Definitions$DefinitionsClass.PartialManifestClass(De finitions.scala:467)
        at
scala.tools.nsc.typechecker.Implicits$ImplicitSearch.<init>(Implicits.scala :1221)
        at
scala.tools.nsc.typechecker.Implicits$class.inferImplicit(Implicits.scala:8 2)
        at scala.tools.nsc.Global$$anon$1.inferImplicit(Global.scala:488)
        at
scala.tools.nsc.typechecker.Implicits$class.inferImplicit(Implicits.scala:3 7)
        at scala.tools.nsc.Global$$anon$1.inferImplicit(Global.scala:488)
        at
scala.tools.nsc.typechecker.Typers$Typer$$anonfun$applyImplicitArgs$2.apply (Typers.scala:133)
        at
scala.tools.nsc.typechecker.Typers$Typer$$anonfun$applyImplicitArgs$2.apply (Typers.scala:128)
        at
scala.collection.LinearSeqOptimized$class.foreach(LinearSeqOptimized.scala: 59)
        at scala.collection.immutable.List.foreach(List.scala:78)
[rest of stack trace snipped]

The same code compiles fine with scalac from the command-line.  Any
suggestions of how to track this down?

Thanks,

--
Alan Burlison
--


 
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.
Alan Burlison  
View profile  
 More options Aug 7 2012, 11:59 am
From: Alan Burlison <alan.burli...@gmail.com>
Date: Tue, 07 Aug 2012 16:59:46 +0100
Local: Tues, Aug 7 2012 11:59 am
Subject: Re: [scala-user] Re: Ant problem with 2.10M6
On 07/08/2012 13:22, Alan Burlison wrote:

> I spoke too soon. It apparently works with the ant fsc task, but the
> scalac task blows up:

Logged as https://issues.scala-lang.org/browse/SI-6203

--
Alan Burlison
--


 
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.
Josh Suereth  
View profile  
 More options Aug 7 2012, 12:14 pm
From: Josh Suereth <joshua.suer...@gmail.com>
Date: Tue, 7 Aug 2012 12:14:41 -0400
Local: Tues, Aug 7 2012 12:14 pm
Subject: Re: [scala-user] Re: Ant problem with 2.10M6

Can we get some more info here?  I can't even begin to look into it without
some kind of *small* reproducible test case.

- Josh

On Tue, Aug 7, 2012 at 11:59 AM, Alan Burlison <alan.burli...@gmail.com>wrote:


 
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.
Alan Burlison  
View profile  
 More options Aug 7 2012, 12:30 pm
From: Alan Burlison <alan.burli...@gmail.com>
Date: Tue, 07 Aug 2012 17:30:15 +0100
Local: Tues, Aug 7 2012 12:30 pm
Subject: Re: [scala-user] Re: Ant problem with 2.10M6
On 07/08/2012 17:14, Josh Suereth wrote:

> Can we get some more info here?  I can't even begin to look into it without
> some kind of *small* reproducible test case.

Absolutely, working on it now.

--
Alan Burlison
--


 
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.
workingDog  
View profile  
 More options Sep 1 2012, 6:51 pm
From: workingDog <wathele...@yahoo.com.au>
Date: Sat, 1 Sep 2012 15:51:11 -0700 (PDT)
Local: Sat, Sep 1 2012 6:51 pm
Subject: Re: [scala-user] Re: Ant problem with 2.10M6

Alan,

could you post the solution please. I could not really understand "The fix
is to delete and recreate the Scala NetBeans libraries and the project
references to them and make sure that the versions of the libraries that
end up in $PROJECT/lib correspond to the scalac version you are using."

I can't even remove the scala platform from Netbeans.


 
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.
Alan Burlison  
View profile  
 More options Sep 3 2012, 5:09 am
From: Alan Burlison <alan.burli...@gmail.com>
Date: Mon, 03 Sep 2012 10:09:46 +0100
Local: Mon, Sep 3 2012 5:09 am
Subject: Re: [scala-user] Re: Ant problem with 2.10M6
On 01/09/2012 23:51, workingDog wrote:

> could you post the solution please. I could not really understand "The fix
> is to delete and recreate the Scala NetBeans libraries and the project
> references to them and make sure that the versions of the libraries that
> end up in $PROJECT/lib correspond to the scalac version you are using."

NetBeans usually keeps a local copy of scala-library.jar inside your
project.  If you update the scala version, it doesn't get updated so you
get all sorts of oddness because of the mismatch - and because scala is
self-hosted, that includes compile-time oddness, not just run-time
oddness.  That's why you need to manually clean up any old copies that
are lying around and make sure everything matches version-wise.

--
Alan Burlison
--


 
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 »