Re: [classlib] using cpp

2006-02-14 Thread Alexey Petrenko
  You suggest not to use C++ in Harmony at all?
 As Geir says elsewhere, I mean in classlib in particular.
I do not think that is good idea...
I agree that it's almost does not matter for JNI code. But C++ code
looks nicer there :)
But if native code will use some native class library this restriction
will make developers life much harder.

--
Alexey A. Petrenko
Intel Middleware Products Division


Re: [classlib] build / test system

2006-02-14 Thread Stepan Mishura
If redistributing Eclipse's jars is not an issue then I think it would be
good to put them to SVN and set up the ant build script accordingly. This
will simplify build process.
Also this can be applied, for example, to BC provider jar - we'll avoid
questions like: which version of BC did you use? Everybody will use jar that
is distributed with Harmony code base and is used to test it.

Thanks,
Stepan Mishura
Intel Middleware Products Division

On 2/13/06, Geir Magnusson Jr [EMAIL PROTECTED] wrote:

 I'm dorking around with some ant scripts for doing a complete unit test
 run over all modules.

 After some pondering, I'd like to have us eat our own dogfood (ok,
 Eclipse's dogfood) and start doing everything that we can using the
 eclipse java compiler, with the goal of self-hosting at some point with
 a javac.exe that uses it.

 So to that end, I'd like to set things up so that by default, we use the
 eclipse compiler, but that means that people have to go through a
 [painful] process to get the jars (2 of them) - namely if you don't have
 Eclipse installed, you have to go get it and dig two jars out.

 I'd like to set things up so we don't have to put in ant/lib to make it
 less intrusive to people - we could have a local lib dir and do that
 maybe.

 Anyway, anyone have strong feelings or suggestions?

 geir



Re: [classlib] build / test system

2006-02-14 Thread George Harley

Hi Stepan,

And if redistributing the Eclipse jars was an issue then we could simply 
make use of the Maven jar repository at ibiblio.org. The jars necessary 
for using the Eclipse compiler can be obtained from there without the 
need to download the entire Eclipse platform (see 
http://www.ibiblio.org/maven/eclipse/jars/jdtcore-3.1.0.jar) which 
reduces the pain considerably.


Ant build scripts could simply make use of the get task (with the 
usetimestamp option to avoid unnecessary downloading) to get the 
jdtcore-3.1.0.jar and then use unzip to extract the 
jdtCompilerAdapter.jar that is contained in there. The modified 
trunk/make/build-java.xml file inside the attachments for HARMONY-57 and 
HARMONY-88 use the ibiblio.org repository in just this way to obtain 
various xml support jars and even the junit jar.



Best regards,
George
IBM United Kingdom Limited


Stepan Mishura wrote:

If redistributing Eclipse's jars is not an issue then I think it would be
good to put them to SVN and set up the ant build script accordingly. This
will simplify build process.
Also this can be applied, for example, to BC provider jar - we'll avoid
questions like: which version of BC did you use? Everybody will use jar that
is distributed with Harmony code base and is used to test it.

Thanks,
Stepan Mishura
Intel Middleware Products Division

On 2/13/06, Geir Magnusson Jr [EMAIL PROTECTED] wrote:
  

I'm dorking around with some ant scripts for doing a complete unit test
run over all modules.

After some pondering, I'd like to have us eat our own dogfood (ok,
Eclipse's dogfood) and start doing everything that we can using the
eclipse java compiler, with the goal of self-hosting at some point with
a javac.exe that uses it.

So to that end, I'd like to set things up so that by default, we use the
eclipse compiler, but that means that people have to go through a
[painful] process to get the jars (2 of them) - namely if you don't have
Eclipse installed, you have to go get it and dig two jars out.

I'd like to set things up so we don't have to put in ant/lib to make it
less intrusive to people - we could have a local lib dir and do that
maybe.

Anyway, anyone have strong feelings or suggestions?

geir




  




[jira] Assigned: (HARMONY-89) java.util.jar.Manifest().read(InputStream is) throws OutOfMemoryError

2006-02-14 Thread Tim Ellison (JIRA)
 [ http://issues.apache.org/jira/browse/HARMONY-89?page=all ]

Tim Ellison reassigned HARMONY-89:
--

Assign To: Tim Ellison

 java.util.jar.Manifest().read(InputStream is) throws OutOfMemoryError
 -

  Key: HARMONY-89
  URL: http://issues.apache.org/jira/browse/HARMONY-89
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Svetlana Samoilenko
 Assignee: Tim Ellison
  Attachments: fix.txt

 Synopsis: java.util.jar.Manifest().read(InputStream is) throws 
 OutOfMemoryError 
 Description: For test listed below BEA throws IOException while Harmony 
 throws OutOfMemoryError. 
 The test creates an instance of InputStreamImpl  where read method is 
 implemented in simple way and returned any integer value, in particular 
 in.available()== 0 and  in.read(buf) == buf.length.
 There is no checking for this conditions  in the InitManifest.readLines 
 method  and as a result an endless loop occurs.
 Suggested fix in attachment may be incomplete, needs additional investigation.
 Code to reproduce: 
 import java.util.jar.*; 
 import java.io.*; 
  
 public class test2 { 
 public static void main(String args[]) { 
 InputStream is = new InputStreamImpl(); 
 try { 
 new Manifest().read(is); 
 } catch (IOException e) { 
  e.printStackTrace(); 
  System.out.println(PASSED); 
 } 
   } 
 }
 class InputStreamImpl extends InputStream{
 public InputStreamImpl() { 
 super(); 
 } 
 public int read() { 
 return 0; 
 } 
 } 
 Steps to Reproduce: 
 1. Build Harmony (check-out on 2006-01-30) j2se subset as described in 
 README.txt. 
 2. Compile test2.java using BEA 1.4 javac 
  javac -d . test2.java 
 3. Run java using compatible VM (J9) 
  java -showversion test2
 Output: 
 C:\tmpC:\jrockit-j2sdk1.4.2_04\bin\java.exe -showversion test2 
 java version 1.4.2_04 
 Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) 
 BEA WebLogic JRockit(TM) 1.4.2_04 JVM (build 
 ari-31788-20040616-1132-win-ia32, Native Threads, GC strategy: parallel) 
 java.io.IOException: line too long
 at 
 java.util.jar.Attributes.read(Ljava.util.jar.Manifest$FastInputStream;[B)V(Attributes.java:356)
 at 
 java.util.jar.Manifest.read(Ljava.io.InputStream;)V(Manifest.java:167)
 at test2.main([Ljava.lang.String;)V(test2.java:8)
 PASSED
 C:\tmpC:\harmony\trunk\deploy\jre\bin\java -showversion test2 
 (c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as 
 applicable. 
 java.lang.OutOfMemoryError
 at java.util.jar.InitManifest.readLines(InitManifest.java:224)
 at java.util.jar.InitManifest.init(InitManifest.java:61)
 at java.util.jar.Manifest.read(Manifest.java:273)
 at test2.main(test2.java:10)
 Suggested junit test case:
  ManifestTest.java 
 - 
 import junit.framework.*; 
 import java.io.*;
 import java.util.jar.Manifest; 
 public class ManifestTest extends TestCase { 
 public static void main(String[] args) { 
 junit.textui.TestRunner.run(ManifestTest.class); 
 } 
 public void test_read () { 
 InputStream is = new InputStreamImpl(); 
 try { 
new Manifest().read(is); 
 } catch (IOException e) { 
   //expected 
 } 
 } 
 }
 class InputStreamImpl extends InputStream 
 
 public InputStreamImpl() { 
 super(); 
 } 
 public int read() { 
 return 0; 
 } 
 }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



Re: [classlib] build / test system

2006-02-14 Thread Dalibor Topic
George Harley george.c.harley at googlemail.com writes:

 
 Hi Stepan,
 
 And if redistributing the Eclipse jars was an issue then we could simply 
 make use of the Maven jar repository at ibiblio.org. 

We want to be able to redistribute a java compiler implementation as well. If
redistributing eclipse jars is an issue, we'll just have to write a new Apache
Licensed compiler to go with Harmony, even though we may prefer to use something
else for development.

cheers,
dalibor topic





Re: [classlib] build / test system

2006-02-14 Thread Dalibor Topic
Stepan Mishura stepan.mishura at gmail.com writes:

 Also this can be applied, for example, to BC provider jar - we'll avoid
 questions like: which version of BC did you use? Everybody will use jar that
 is distributed with Harmony code base and is used to test it.

Not necessarily. When deploying software written in Java, distributions go to
great lengths to ensure that what they redistribute is indeed free software. 

Ocassionally, that means removing proprietary software from binaries/sources
distributed by the Apache Software Foundation (used to redistribute Sun's BCL
licensed stuff a while ago, and may still do, see [1] for an example) in order
to make them redistributable by other entities not interested in the bundled
proprietary software.

In addition, distributions are fixing the jar hell by streamlining the package
dependencies to use packages of specific libraries, rather than each application
bundling their own copies of XYZ.jar.

In order to perform such necessary and useful work, knowing where from, at which
version, and under which license bundled third party libraries are included is a
great help for packagers, and other downstream users wishing to customize
deployments of the application.

cheers,
dalibor topic

[1] http://lists.gnu.org/archive/html/classpath/2005-08/msg00033.html



Re: [classlib] build / test system

2006-02-14 Thread Alexey Petrenko
 Well, it would be nice. However I don't like build scripts that depend on
 network.
Yes, there should be the possibility to download needed jars once and
forget about network.

--
Alexey A. Petrenko
Intel Middleware Products Division


[jira] Resolved: (HARMONY-89) java.util.jar.Manifest().read(InputStream is) throws OutOfMemoryError

2006-02-14 Thread Tim Ellison (JIRA)
 [ http://issues.apache.org/jira/browse/HARMONY-89?page=all ]
 
Tim Ellison resolved HARMONY-89:


Resolution: Fixed

Svetlana,

Fixed in ARCHIVE module java.util.jar.InitManifest at repo revision 377690.

Please check this fully resolves your problem.

 java.util.jar.Manifest().read(InputStream is) throws OutOfMemoryError
 -

  Key: HARMONY-89
  URL: http://issues.apache.org/jira/browse/HARMONY-89
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Svetlana Samoilenko
 Assignee: Tim Ellison
  Attachments: fix.txt

 Synopsis: java.util.jar.Manifest().read(InputStream is) throws 
 OutOfMemoryError 
 Description: For test listed below BEA throws IOException while Harmony 
 throws OutOfMemoryError. 
 The test creates an instance of InputStreamImpl  where read method is 
 implemented in simple way and returned any integer value, in particular 
 in.available()== 0 and  in.read(buf) == buf.length.
 There is no checking for this conditions  in the InitManifest.readLines 
 method  and as a result an endless loop occurs.
 Suggested fix in attachment may be incomplete, needs additional investigation.
 Code to reproduce: 
 import java.util.jar.*; 
 import java.io.*; 
  
 public class test2 { 
 public static void main(String args[]) { 
 InputStream is = new InputStreamImpl(); 
 try { 
 new Manifest().read(is); 
 } catch (IOException e) { 
  e.printStackTrace(); 
  System.out.println(PASSED); 
 } 
   } 
 }
 class InputStreamImpl extends InputStream{
 public InputStreamImpl() { 
 super(); 
 } 
 public int read() { 
 return 0; 
 } 
 } 
 Steps to Reproduce: 
 1. Build Harmony (check-out on 2006-01-30) j2se subset as described in 
 README.txt. 
 2. Compile test2.java using BEA 1.4 javac 
  javac -d . test2.java 
 3. Run java using compatible VM (J9) 
  java -showversion test2
 Output: 
 C:\tmpC:\jrockit-j2sdk1.4.2_04\bin\java.exe -showversion test2 
 java version 1.4.2_04 
 Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) 
 BEA WebLogic JRockit(TM) 1.4.2_04 JVM (build 
 ari-31788-20040616-1132-win-ia32, Native Threads, GC strategy: parallel) 
 java.io.IOException: line too long
 at 
 java.util.jar.Attributes.read(Ljava.util.jar.Manifest$FastInputStream;[B)V(Attributes.java:356)
 at 
 java.util.jar.Manifest.read(Ljava.io.InputStream;)V(Manifest.java:167)
 at test2.main([Ljava.lang.String;)V(test2.java:8)
 PASSED
 C:\tmpC:\harmony\trunk\deploy\jre\bin\java -showversion test2 
 (c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as 
 applicable. 
 java.lang.OutOfMemoryError
 at java.util.jar.InitManifest.readLines(InitManifest.java:224)
 at java.util.jar.InitManifest.init(InitManifest.java:61)
 at java.util.jar.Manifest.read(Manifest.java:273)
 at test2.main(test2.java:10)
 Suggested junit test case:
  ManifestTest.java 
 - 
 import junit.framework.*; 
 import java.io.*;
 import java.util.jar.Manifest; 
 public class ManifestTest extends TestCase { 
 public static void main(String[] args) { 
 junit.textui.TestRunner.run(ManifestTest.class); 
 } 
 public void test_read () { 
 InputStream is = new InputStreamImpl(); 
 try { 
new Manifest().read(is); 
 } catch (IOException e) { 
   //expected 
 } 
 } 
 }
 class InputStreamImpl extends InputStream 
 
 public InputStreamImpl() { 
 super(); 
 } 
 public int read() { 
 return 0; 
 } 
 }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



Re: [classlib] proposal to revisit componentization for security (was: Re: problems with security2)

2006-02-14 Thread Tim Ellison
Mikhail Loenko wrote:
 Tim
 
 On 2/13/06, Tim Ellison [EMAIL PROTECTED] wrote:
 Mikhail Loenko wrote:
 It looks good but it is not clear where would you put certification stuff.
 According to SUN's guide it is splitted between JSSE and general security.
 (According to SUN general security includes also crypto architecture)
 I wouldn't get too hung up about where Sun put it.  There is likely a
 different partitioning about where the architectural/semantic boundaries
 are best placed, and how we componentize the implementation.

 Looking into this a bit more, the certificate management
 (java.security.cert.*) code should likely go in 'general security'.

 It is mostly instinct behind the decision, but that was formed by the
 following reasoning:

 Historical - JCE, JSSE and JAAS used to be optional packages for the JDK
 at a time when the certificate management code was included in the JDK
 By process of exclusion - the other modules ('crypto', 'x-net' and
 'jaas') are self-contained and can be removed without breaking any other
 APIs.
 
 That was in the past. In 1.5 for example
 java.security.KeyStore.SecretKeyEntry.getSecretKey()
 returns
 javax.crypto.SecretKey
 
 Method
 java.security.AuthProvider.login()
 takes  arguments
 javax.security.auth.Subject and 
 javax.security.auth.callback.CallbackHandler
 
 Another example
 java.net.SecureCacheResponse.getPeerPrincipal()
 throws
 javax.net.ssl.SSLPeerUnverifiedException
 
 So, none of the components is self-contained.

Right, but these are all public type dependencies, for sure the modules
will have many dependencies on other modules' public types.
Do you see a close coupling of the implementation types too?

Regards,
Tim

 Removing certificate management would break APIs in java.util.jar
 and java.security so it doesn't make sense to separate it from them.

 US Export Control office is less interested in digital
 signing/verification than they are in the cryptography and secure
 communications packages.  Keeping them pluggable makes sense.

 Perhaps we should name the 'jaas' package 'auth'.  JAAS may be a
 protected trademark.  The org.ietf.jgss package may belong in 'auth' as
 well.

 Regards,
 Tim

 I'd rather put it  into crypto (or maybe into x-net) - all of them use
 service-provider architecture. What do you think?

 Thanks,
 Mikhail

 On 2/10/06, Tim Ellison [EMAIL PROTECTED] wrote:
 Mikhail Loenko wrote:
 What I'd like to propose is:

 1. separate Authentication and Authorization stuff (javax.security
 package) from general security
 Ok, so I can see this.

 2. unite crypto (java.security) and crypto extension (javax.crypto)
 but this makes no sense to me.  Why would you want to unite JCE with
 general security?  There is no close coupling afaict.

 How about
  - general security
  - crypto
  - x-net
  - jaas

 there may be good reason to want to replace crypto independently of
 general security.  Am I missing something?

 Regards,
 Tim

 --

 Tim Ellison ([EMAIL PROTECTED])
 IBM Java technology centre, UK.

 --

 Tim Ellison ([EMAIL PROTECTED])
 IBM Java technology centre, UK.

 

-- 

Tim Ellison ([EMAIL PROTECTED])
IBM Java technology centre, UK.


Re: [classlib] build / test system

2006-02-14 Thread George Harley

Hi Alexey,

The usetimestamp attribute of Ant's get task kind of offers this 
functionality. Setting the attribute value to true means that the 
download only proceeds if the local copy of the resource is missing or 
stale.


There is more information on this at 
http://ant.apache.org/manual/CoreTasks/get.html


Best regards,
George
IBM UK



Alexey Petrenko wrote:

Well, it would be nice. However I don't like build scripts that depend on
network.


Yes, there should be the possibility to download needed jars once and
forget about network.

--
Alexey A. Petrenko
Intel Middleware Products Division
  




Re: [jchevm] native method API for _jc_new_intern_string -- do you plan to add to _jc_ilib_entry table?

2006-02-14 Thread Tim Ellison
sure -- String interning is in the kernel precisely so that the VM
implementor (i.e. you) can choose to do it in native or Java code.

Of course, they have to be interned into the same table as the JLS
string literals.

Regards,
Tim

Archie Cobbs wrote:
 Weldon Washburn wrote:
 I am working on kernel_path String.java.  It wants to call a native
 method to do the intern work.  If you plan to add a native method that
 does String intern, I won't spend the time doing interning in Java
 code.   I think this code is related to  _jc_ilib_entry table.  Do you
 have thoughts on the best approach?
 
 The best approach (imho) is to do interning in Java, using a
 WeakHashMap, which is perfect for the task. The Classpath
 implementation is a mere 10 lines or so.
 
 -Archie
 
 __
 Archie Cobbs  *CTO, Awarix*  http://www.awarix.com
 

-- 

Tim Ellison ([EMAIL PROTECTED])
IBM Java technology centre, UK.


Re: [classlib] build / test system

2006-02-14 Thread Stepan Mishura
And to detect whether it is stale or not you need network. Right?

It is very inconvenient to find out in the middle of the build that network
is too slow and it will take hours to download new version of a jar file.
You know, it always happens when you are in a big hurry :-)

Thanks,
Stepan


On 2/14/06, George Harley george.c.harley at googlemail.com wrote:

 Hi Alexey,

 The usetimestamp attribute of Ant's get task kind of offers this
 functionality. Setting the attribute value to true means that the
 download only proceeds if the local copy of the resource is missing or
 stale.

 There is more information on this at
 http://ant.apache.org/manual/CoreTasks/get.html

 Best regards,
 George
 IBM UK



 Alexey Petrenko wrote:
  Well, it would be nice. However I don't like build scripts that depend
 on
  network.
 
  Yes, there should be the possibility to download needed jars once and
  forget about network.
 
  --
  Alexey A. Petrenko
  Intel Middleware Products Division
 




Re: [classlib] proposal to revisit componentization for security (was: Re: problems with security2)

2006-02-14 Thread Mikhail Loenko
There is coupling.
BTW... Could you give an example of close and weak coupling?

The following two groups of classes use the same internal stuff:
GROUP1 (use/provide inernal implementation of 'getInstance' ):
java.security.AlgorithmParameterGenerator
java.security.AlgorithmParameters
java.security.KeyFactory
java.security.KeyPairGenerator
java.security.KeyStore
java.security.KeyStoreSpi
java.security.MessageDigest
java.security.Provider
java.security.SecureRandom
java.security.Security
java.security.Signature
java.security.cert.CertPathBuilder
java.security.cert.CertPathValidator
java.security.cert.CertStore
java.security.cert.CertificateFactory
javax.crypto.Cipher
javax.crypto.ExemptionMechanism
javax.crypto.KeyAgreement
javax.crypto.KeyGenerator
javax.crypto.Mac
javax.crypto.SecretKeyFactory
javax.net.ssl.KeyManagerFactory
javax.net.ssl.SSLContext
javax.net.ssl.SSLServerSocketFactory
javax.net.ssl.SSLSocketFactory
javax.net.ssl.TrustManagerFactory

GROUP2 (all use internal implementation of ASN.1):
java.security.cert.PolicyQualifierInfo
java.security.cert.TrustAnchor
java.security.cert.X509CRLSelector
java.security.cert.X509CertSelector
javax.crypto.EncryptedPrivateKeyInfo
javax.security.auth.kerberos.KerberosKey
javax.security.auth.kerberos.KerberosTicket

All other dependencies seem to be public ones.

Thanks,
Mikhail

On 2/14/06, Tim Ellison [EMAIL PROTECTED] wrote:
 Mikhail Loenko wrote:
  Tim
 
  On 2/13/06, Tim Ellison [EMAIL PROTECTED] wrote:
  Mikhail Loenko wrote:
  It looks good but it is not clear where would you put certification stuff.
  According to SUN's guide it is splitted between JSSE and general security.
  (According to SUN general security includes also crypto architecture)
  I wouldn't get too hung up about where Sun put it.  There is likely a
  different partitioning about where the architectural/semantic boundaries
  are best placed, and how we componentize the implementation.
 
  Looking into this a bit more, the certificate management
  (java.security.cert.*) code should likely go in 'general security'.
 
  It is mostly instinct behind the decision, but that was formed by the
  following reasoning:
 
  Historical - JCE, JSSE and JAAS used to be optional packages for the JDK
  at a time when the certificate management code was included in the JDK
  By process of exclusion - the other modules ('crypto', 'x-net' and
  'jaas') are self-contained and can be removed without breaking any other
  APIs.
 
  That was in the past. In 1.5 for example
  java.security.KeyStore.SecretKeyEntry.getSecretKey()
  returns
  javax.crypto.SecretKey
 
  Method
  java.security.AuthProvider.login()
  takes  arguments
  javax.security.auth.Subject and 
  javax.security.auth.callback.CallbackHandler
 
  Another example
  java.net.SecureCacheResponse.getPeerPrincipal()
  throws
  javax.net.ssl.SSLPeerUnverifiedException
 
  So, none of the components is self-contained.

 Right, but these are all public type dependencies, for sure the modules
 will have many dependencies on other modules' public types.
 Do you see a close coupling of the implementation types too?

 Regards,
 Tim

  Removing certificate management would break APIs in java.util.jar
  and java.security so it doesn't make sense to separate it from them.
 
  US Export Control office is less interested in digital
  signing/verification than they are in the cryptography and secure
  communications packages.  Keeping them pluggable makes sense.
 
  Perhaps we should name the 'jaas' package 'auth'.  JAAS may be a
  protected trademark.  The org.ietf.jgss package may belong in 'auth' as
  well.
 
  Regards,
  Tim
 
  I'd rather put it  into crypto (or maybe into x-net) - all of them use
  service-provider architecture. What do you think?
 
  Thanks,
  Mikhail
 
  On 2/10/06, Tim Ellison [EMAIL PROTECTED] wrote:
  Mikhail Loenko wrote:
  What I'd like to propose is:
 
  1. separate Authentication and Authorization stuff (javax.security
  package) from general security
  Ok, so I can see this.
 
  2. unite crypto (java.security) and crypto extension (javax.crypto)
  but this makes no sense to me.  Why would you want to unite JCE with
  general security?  There is no close coupling afaict.
 
  How about
   - general security
   - crypto
   - x-net
   - jaas
 
  there may be good reason to want to replace crypto independently of
  general security.  Am I missing something?
 
  Regards,
  Tim
 
  --
 
  Tim Ellison ([EMAIL PROTECTED])
  IBM Java technology centre, UK.
 
  --
 
  Tim Ellison ([EMAIL PROTECTED])
  IBM Java technology centre, UK.
 
 

 --

 Tim Ellison ([EMAIL PROTECTED])
 IBM Java technology centre, UK.



Re: [classlib] build / test system

2006-02-14 Thread George Harley

Hi,

OK, yes, it needs a network connection. My point was really that 
usetimestamp provides a mechanism for jars to be downloaded only when 
required (i.e. when not present or when stale). I wasn't really 
intending to sell it as a way of working without the network hence the 
declaration that it kind of offers this functionality.


I could mention that setting the ignoreerrors attribute to true 
would mean that, in the absence of a network, the task could fail (to 
check the local and remote timestamps of the resources) without bringing 
the whole build script to a screeching halt. But that probably wouldn't 
be of interest to you either :-)


Best regards,
George
IBM UK



Tim Ellison wrote:

How does it know it is stale without a network connection ?

Regards,
Tim

George Harley wrote:
  

Hi Alexey,

The usetimestamp attribute of Ant's get task kind of offers this
functionality. Setting the attribute value to true means that the
download only proceeds if the local copy of the resource is missing or
stale.

There is more information on this at
http://ant.apache.org/manual/CoreTasks/get.html

Best regards,
George
IBM UK



Alexey Petrenko wrote:


Well, it would be nice. However I don't like build scripts that
depend on
network.



Yes, there should be the possibility to download needed jars once and
forget about network.

--
Alexey A. Petrenko
Intel Middleware Products Division
  
  



  




Re: [jchevm] native method API for _jc_new_intern_string -- do you plan to add to _jc_ilib_entry table?

2006-02-14 Thread Oliver Deakin

Hi Weldon,

Weldon Washburn wrote:

Archie,
I am working on kernel_path String.java.  
The only VM specific method in String currently is intern. However, 
inclusion of this method in the kernel forces the VM vendor to implement 
the rest of the String class, which has no further VM specific code.


Can we propose to move String out of kernel and into LUNI, and reroute 
Strings intern call through an intern method the VM class in kernel? 
This was mentioned in a JIRA comment made by Tim a couple of weeks ago:

http://mail-archives.apache.org/mod_mbox/incubator-harmony-dev/200601.mbox/[EMAIL
 PROTECTED]

So the String implementation will be held in LUNI, and its intern method 
will just make a direct call to VM.intern(String), which is in the 
kernel. This means that a VM vendor only needs to produce the intern 
method (in VM.java), and not the rest of the String class, cutting down 
the kernel size and the resulting workload for the VM vendor.



It wants to call a native
method to do the intern work.  If you plan to add a native method that
does String intern, I won't spend the time doing interning in Java
code.   I think this code is related to  _jc_ilib_entry table.  Do you
have thoughts on the best approach?

Thanks

--
Weldon Washburn
Intel Middleware Products Division

  


--
Oliver Deakin
IBM United Kingdom Limited



[jira] Commented: (HARMONY-40) FileChannel assotiated with FileOutputStream not closed after closing output stream

2006-02-14 Thread Vladimir Strigun (JIRA)
[ 
http://issues.apache.org/jira/browse/HARMONY-40?page=comments#action_12366330 ] 

Vladimir Strigun commented on HARMONY-40:
-

This bug is a part of Harmony-42 issue. I can't reproduce it with latest 
sources. Anyway, I think suggested test can be added to tests/java/io .

 FileChannel assotiated with FileOutputStream not closed after closing output 
 stream
 ---

  Key: HARMONY-40
  URL: http://issues.apache.org/jira/browse/HARMONY-40
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Vladimir Strigun


 When I receive FileChannel from file output stream, write something to stream 
 and then close it, channel, assotiated with the stream is still open. I'll 
 attach unit test for the issue.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



Re: [classlib] build / test system

2006-02-14 Thread Geir Magnusson Jr
Yah, that or just fetch from ibiblio or -ish dynamically.  I hate 
connecting anything to ibiblio because it's so painfully slow at times...


But I do want to establish precise versions for things - keeps the what 
was on your classpath problems to a bare minimum.


geir

Stepan Mishura wrote:

If redistributing Eclipse's jars is not an issue then I think it would be
good to put them to SVN and set up the ant build script accordingly. This
will simplify build process.
Also this can be applied, for example, to BC provider jar - we'll avoid
questions like: which version of BC did you use? Everybody will use jar that
is distributed with Harmony code base and is used to test it.

Thanks,
Stepan Mishura
Intel Middleware Products Division

On 2/13/06, Geir Magnusson Jr [EMAIL PROTECTED] wrote:

I'm dorking around with some ant scripts for doing a complete unit test
run over all modules.

After some pondering, I'd like to have us eat our own dogfood (ok,
Eclipse's dogfood) and start doing everything that we can using the
eclipse java compiler, with the goal of self-hosting at some point with
a javac.exe that uses it.

So to that end, I'd like to set things up so that by default, we use the
eclipse compiler, but that means that people have to go through a
[painful] process to get the jars (2 of them) - namely if you don't have
Eclipse installed, you have to go get it and dig two jars out.

I'd like to set things up so we don't have to put in ant/lib to make it
less intrusive to people - we could have a local lib dir and do that
maybe.

Anyway, anyone have strong feelings or suggestions?

geir





Re: [classlib] build / test system

2006-02-14 Thread Geir Magnusson Jr



George Harley wrote:

Hi Stepan,

And if redistributing the Eclipse jars was an issue then we could simply 
make use of the Maven jar repository at ibiblio.org. The jars necessary 
for using the Eclipse compiler can be obtained from there without the 
need to download the entire Eclipse platform (see 
http://www.ibiblio.org/maven/eclipse/jars/jdtcore-3.1.0.jar) which 
reduces the pain considerably.


Well, ibiblio is a pain - it can be slow to the point of timeout, which 
is really no fun.  Been there, raged at that.





Ant build scripts could simply make use of the get task (with the 
usetimestamp option to avoid unnecessary downloading) to get the 
jdtcore-3.1.0.jar and then use unzip to extract the 
jdtCompilerAdapter.jar that is contained in there. The modified 
trunk/make/build-java.xml file inside the attachments for HARMONY-57 and 
HARMONY-88 use the ibiblio.org repository in just this way to obtain 
various xml support jars and even the junit jar.


Yes, this is what I was trying to do in security2 a while back to 
automate getting the junit and bcprov jars for testing.  problem was 
that ibiblio didn't have the right version of bcprov :)





Best regards,
George
IBM United Kingdom Limited


Stepan Mishura wrote:

If redistributing Eclipse's jars is not an issue then I think it would be
good to put them to SVN and set up the ant build script accordingly. This
will simplify build process.
Also this can be applied, for example, to BC provider jar - we'll avoid
questions like: which version of BC did you use? Everybody will use 
jar that

is distributed with Harmony code base and is used to test it.

Thanks,
Stepan Mishura
Intel Middleware Products Division

On 2/13/06, Geir Magnusson Jr [EMAIL PROTECTED] wrote:
 

I'm dorking around with some ant scripts for doing a complete unit test
run over all modules.

After some pondering, I'd like to have us eat our own dogfood (ok,
Eclipse's dogfood) and start doing everything that we can using the
eclipse java compiler, with the goal of self-hosting at some point with
a javac.exe that uses it.

So to that end, I'd like to set things up so that by default, we use the
eclipse compiler, but that means that people have to go through a
[painful] process to get the jars (2 of them) - namely if you don't have
Eclipse installed, you have to go get it and dig two jars out.

I'd like to set things up so we don't have to put in ant/lib to make it
less intrusive to people - we could have a local lib dir and do that
maybe.

Anyway, anyone have strong feelings or suggestions?

geir




  





Re: [classlib] build / test system

2006-02-14 Thread Geir Magnusson Jr



Dalibor Topic wrote:

Ocassionally, that means removing proprietary software from binaries/sources
distributed by the Apache Software Foundation (used to redistribute Sun's BCL
licensed stuff a while ago, and may still do, see [1] for an example) in order
to make them redistributable by other entities not interested in the bundled
proprietary software.



That was a mistake, the BCL stuff.  That is being taken care of.

geir



Re: [classlib] build / test system

2006-02-14 Thread Geir Magnusson Jr



Alexey Petrenko wrote:

Well, it would be nice. However I don't like build scripts that depend on
network.

Yes, there should be the possibility to download needed jars once and
forget about network.


That's what using get in ant does - it should be able to fail 
silently.  Or, if not, we put in a offline mode.


geir


Re: [classlib] build / test system

2006-02-14 Thread Geir Magnusson Jr



Stepan Mishura wrote:

And to detect whether it is stale or not you need network. Right?


If you have a network, then you get it.  If you don't have a network, 
then it doesn't matter if it's stale or not, because there is nothing 
you can do about it anyway.


The assumption is that you keep the whole tree up to date - therefore, 
while a given dependency may be stale, it's no more stale than your 
tree, so you can still work until you get back online.


If you update code, and don't update deps into the local repository, 
it's your problem :)


geir




Re: [classlib] build / test system

2006-02-14 Thread George Harley

Hi Geir,

If folks find the ibiblio site slow and the latest versions of what we 
need are not available, is there any merit in an Apache Harmony 
repository being set up that would contain whatever binaries are 
required by developers (e.g. eclipse compiler jars, BC provider jar, etc) ?


Best regards,
George
IBM United Kingdom Limited


Geir Magnusson Jr wrote:



George Harley wrote:

Hi Stepan,

And if redistributing the Eclipse jars was an issue then we could 
simply make use of the Maven jar repository at ibiblio.org. The jars 
necessary for using the Eclipse compiler can be obtained from there 
without the need to download the entire Eclipse platform (see 
http://www.ibiblio.org/maven/eclipse/jars/jdtcore-3.1.0.jar) which 
reduces the pain considerably.


Well, ibiblio is a pain - it can be slow to the point of timeout, 
which is really no fun.  Been there, raged at that.





Ant build scripts could simply make use of the get task (with the 
usetimestamp option to avoid unnecessary downloading) to get the 
jdtcore-3.1.0.jar and then use unzip to extract the 
jdtCompilerAdapter.jar that is contained in there. The modified 
trunk/make/build-java.xml file inside the attachments for HARMONY-57 
and HARMONY-88 use the ibiblio.org repository in just this way to 
obtain various xml support jars and even the junit jar.


Yes, this is what I was trying to do in security2 a while back to 
automate getting the junit and bcprov jars for testing.  problem was 
that ibiblio didn't have the right version of bcprov :)





Best regards,
George
IBM United Kingdom Limited


Stepan Mishura wrote:
If redistributing Eclipse's jars is not an issue then I think it 
would be
good to put them to SVN and set up the ant build script accordingly. 
This

will simplify build process.
Also this can be applied, for example, to BC provider jar - we'll avoid
questions like: which version of BC did you use? Everybody will use 
jar that

is distributed with Harmony code base and is used to test it.

Thanks,
Stepan Mishura
Intel Middleware Products Division

On 2/13/06, Geir Magnusson Jr [EMAIL PROTECTED] wrote:
 
I'm dorking around with some ant scripts for doing a complete unit 
test

run over all modules.

After some pondering, I'd like to have us eat our own dogfood (ok,
Eclipse's dogfood) and start doing everything that we can using the
eclipse java compiler, with the goal of self-hosting at some point 
with

a javac.exe that uses it.

So to that end, I'd like to set things up so that by default, we 
use the

eclipse compiler, but that means that people have to go through a
[painful] process to get the jars (2 of them) - namely if you don't 
have

Eclipse installed, you have to go get it and dig two jars out.

I'd like to set things up so we don't have to put in ant/lib to 
make it

less intrusive to people - we could have a local lib dir and do that
maybe.

Anyway, anyone have strong feelings or suggestions?

geir




  









Re: compiling JCHEVM with GCC/Cygwin

2006-02-14 Thread Enrico Migliore

snowdosker wrote:


Hello Enrico

I'm trying to build JCHEVM following your steps described at
http://www.mail-archive.com/harmony-dev@incubator.apache.org/msg03212.html 



I was able to build Classpath sucsesfuly, but
fail making JCHEVM

In result I have

native/java_lang_VMThread.c: In function `JCNI_java_lang_VMThread_start':
native/java_lang_VMThread.c:388: warning: implicit declaration of 
function `pthread_attr_setstackaddr'
native/java_lang_VMThread.c:388: warning: nested extern declaration of 
`pthread_attr_setstackaddr'

make[2]: *** [java_lang_VMThread.o] Error 1
make[2]: Leaving directory `/home/ivan/jchevm/libjc'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/ivan/jchevm/libjc'
make: *** [all-recursive] Error 1


Can you help me, please.
Thanks, Ivan




Hi Ivan,

if you're building JCHEVM with Cygwin, modify the following file:

.\libjc\arch\arch_definitions.h

at line 95.

Remove:
#define _JC_LIBRARY_FMTlib%s.so

Add:
#define _JC_LIBRARY_FMTlib%s.dll.a

In order to achieve a successfull build, I had to change a few other things.
Before I post them here, let's see how it goes your build.
Are you using a Home or a Professional Windows edition?

Enrico





Re: [classlib] build / test system

2006-02-14 Thread Geir Magnusson Jr



George Harley wrote:

Hi Geir,

If folks find the ibiblio site slow and the latest versions of what we 
need are not available, is there any merit in an Apache Harmony 
repository being set up that would contain whatever binaries are 
required by developers (e.g. eclipse compiler jars, BC provider jar, etc) ?


Of course. We've thought about this before for other projects, like 
Geronimo.


The problem is how such availability is interpreted - are we 
redistributing (i.e. publishing) software?  Generally, the ASF only 
makes external software available when it's part of a program that uses it.


This is different if we have a repository of naked jars that we make 
available for any and all comers.  I've been around this tree before w/ 
Geronimo.  I'll revisit for us and see where people stand.


geir



Best regards,
George
IBM United Kingdom Limited


Geir Magnusson Jr wrote:



George Harley wrote:

Hi Stepan,

And if redistributing the Eclipse jars was an issue then we could 
simply make use of the Maven jar repository at ibiblio.org. The jars 
necessary for using the Eclipse compiler can be obtained from there 
without the need to download the entire Eclipse platform (see 
http://www.ibiblio.org/maven/eclipse/jars/jdtcore-3.1.0.jar) which 
reduces the pain considerably.


Well, ibiblio is a pain - it can be slow to the point of timeout, 
which is really no fun.  Been there, raged at that.





Ant build scripts could simply make use of the get task (with the 
usetimestamp option to avoid unnecessary downloading) to get the 
jdtcore-3.1.0.jar and then use unzip to extract the 
jdtCompilerAdapter.jar that is contained in there. The modified 
trunk/make/build-java.xml file inside the attachments for HARMONY-57 
and HARMONY-88 use the ibiblio.org repository in just this way to 
obtain various xml support jars and even the junit jar.


Yes, this is what I was trying to do in security2 a while back to 
automate getting the junit and bcprov jars for testing.  problem was 
that ibiblio didn't have the right version of bcprov :)





Best regards,
George
IBM United Kingdom Limited


Stepan Mishura wrote:
If redistributing Eclipse's jars is not an issue then I think it 
would be
good to put them to SVN and set up the ant build script accordingly. 
This

will simplify build process.
Also this can be applied, for example, to BC provider jar - we'll avoid
questions like: which version of BC did you use? Everybody will use 
jar that

is distributed with Harmony code base and is used to test it.

Thanks,
Stepan Mishura
Intel Middleware Products Division

On 2/13/06, Geir Magnusson Jr [EMAIL PROTECTED] wrote:
 
I'm dorking around with some ant scripts for doing a complete unit 
test

run over all modules.

After some pondering, I'd like to have us eat our own dogfood (ok,
Eclipse's dogfood) and start doing everything that we can using the
eclipse java compiler, with the goal of self-hosting at some point 
with

a javac.exe that uses it.

So to that end, I'd like to set things up so that by default, we 
use the

eclipse compiler, but that means that people have to go through a
[painful] process to get the jars (2 of them) - namely if you don't 
have

Eclipse installed, you have to go get it and dig two jars out.

I'd like to set things up so we don't have to put in ant/lib to 
make it

less intrusive to people - we could have a local lib dir and do that
maybe.

Anyway, anyone have strong feelings or suggestions?

geir




  










[jira] Assigned: (HARMONY-86) java.util.zip.Inflater.needsDictionary() throws unspecified IllegalStateException

2006-02-14 Thread Tim Ellison (JIRA)
 [ http://issues.apache.org/jira/browse/HARMONY-86?page=all ]

Tim Ellison reassigned HARMONY-86:
--

Assign To: Tim Ellison

 java.util.zip.Inflater.needsDictionary() throws unspecified 
 IllegalStateException
 -

  Key: HARMONY-86
  URL: http://issues.apache.org/jira/browse/HARMONY-86
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Svetlana Samoilenko
 Assignee: Tim Ellison


 According to the j2se 1.4 and 1.5 specification 
 java.util.zip.needsDictionary() method must not throw any exception.
 Harmony throws unspecified IllegalStateException that contradicts 
 specification.
 Code to reproduce: 
 import java.util.zip.*; 
 public class test2 { 
 public static void main(String args[]) { 
 Inflater inf = new Inflater(); 
 System.out.println(Inflater.needsDictionary() = 
 +inf.needsDictionary()); 
 } 
 }
 Steps to Reproduce: 
 1. Build Harmony (check-out on 2006-01-30) j2se subset as described in 
 README.txt. 
 2. Compile test2.java using BEA 1.4 javac 
  javac -d . test2.java 
 3. Run java using compatible VM (J9) 
  java -showversion test2
 Output: 
 C:\tmpC:\jrockit-j2sdk1.4.2_04\bin\java.exe -showversion test2 
 java version 1.4.2_04 
 Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) 
 BEA WebLogic JRockit(TM) 1.4.2_04 JVM (build 
 ari-31788-20040616-1132-win-ia32, Native Threads, GC strategy: parallel) 
 Inflater.needsDictionary() = true
 C:\tmpC:\harmony\trunk\deploy\jre\bin\java -showversion test2 
 (c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as 
 applicable. 
 java.lang.IllegalStateException
 at java.util.zip.Inflater.needsDictionary(Inflater.java:212)
 at test2.main(test2.java:8)
 Siggested fix: to remove the lines in needsDictionary() method in 
 archive/src/main/java/java/util/zip/Inflater.java :   
  211  if (inputBuffer == null)
  212throw new IllegalStateException();
  Suggested junit test case:
  InflaterTest.java 
 - 
 import java.util.zip.*;
 import junit.framework.*; 
 public class InflaterTest extends TestCase { 
 public static void main(String[] args) { 
 junit.textui.TestRunner.run(InflaterTest .class); 
 } 
 public void test_needsDictionary () { 
Inflater inf = new Inflater(); 
assertFalse(inf.needsDictionary());
} 
 }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



[jira] Resolved: (HARMONY-86) java.util.zip.Inflater.needsDictionary() throws unspecified IllegalStateException

2006-02-14 Thread Tim Ellison (JIRA)
 [ http://issues.apache.org/jira/browse/HARMONY-86?page=all ]
 
Tim Ellison resolved HARMONY-86:


Resolution: Fixed

Svetlana,

Fixed in archive module java.util.zip.Inflater at repo revision 377723.

Please check that this fully resolves your problem.


 java.util.zip.Inflater.needsDictionary() throws unspecified 
 IllegalStateException
 -

  Key: HARMONY-86
  URL: http://issues.apache.org/jira/browse/HARMONY-86
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Svetlana Samoilenko
 Assignee: Tim Ellison


 According to the j2se 1.4 and 1.5 specification 
 java.util.zip.needsDictionary() method must not throw any exception.
 Harmony throws unspecified IllegalStateException that contradicts 
 specification.
 Code to reproduce: 
 import java.util.zip.*; 
 public class test2 { 
 public static void main(String args[]) { 
 Inflater inf = new Inflater(); 
 System.out.println(Inflater.needsDictionary() = 
 +inf.needsDictionary()); 
 } 
 }
 Steps to Reproduce: 
 1. Build Harmony (check-out on 2006-01-30) j2se subset as described in 
 README.txt. 
 2. Compile test2.java using BEA 1.4 javac 
  javac -d . test2.java 
 3. Run java using compatible VM (J9) 
  java -showversion test2
 Output: 
 C:\tmpC:\jrockit-j2sdk1.4.2_04\bin\java.exe -showversion test2 
 java version 1.4.2_04 
 Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) 
 BEA WebLogic JRockit(TM) 1.4.2_04 JVM (build 
 ari-31788-20040616-1132-win-ia32, Native Threads, GC strategy: parallel) 
 Inflater.needsDictionary() = true
 C:\tmpC:\harmony\trunk\deploy\jre\bin\java -showversion test2 
 (c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as 
 applicable. 
 java.lang.IllegalStateException
 at java.util.zip.Inflater.needsDictionary(Inflater.java:212)
 at test2.main(test2.java:8)
 Siggested fix: to remove the lines in needsDictionary() method in 
 archive/src/main/java/java/util/zip/Inflater.java :   
  211  if (inputBuffer == null)
  212throw new IllegalStateException();
  Suggested junit test case:
  InflaterTest.java 
 - 
 import java.util.zip.*;
 import junit.framework.*; 
 public class InflaterTest extends TestCase { 
 public static void main(String[] args) { 
 junit.textui.TestRunner.run(InflaterTest .class); 
 } 
 public void test_needsDictionary () { 
Inflater inf = new Inflater(); 
assertFalse(inf.needsDictionary());
} 
 }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



[jira] Assigned: (HARMONY-33) java.nio.BufferOverflow exception while decoding ByteBuffer with UTF-16 charset

2006-02-14 Thread Tim Ellison (JIRA)
 [ http://issues.apache.org/jira/browse/HARMONY-33?page=all ]

Tim Ellison reassigned HARMONY-33:
--

Assign To: Tim Ellison  (was: Geir Magnusson Jr)

 java.nio.BufferOverflow exception while decoding ByteBuffer with UTF-16 
 charset
 ---

  Key: HARMONY-33
  URL: http://issues.apache.org/jira/browse/HARMONY-33
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Vladimir Strigun
 Assignee: Tim Ellison
 Priority: Minor


 If I try to decode ByteBuffer with lengh 1 using UTF-16 decoder unexpected 
 java.nio.BufferOverflow exception occured. Please see testcase below.
 import java.nio.*;
 import java.nio.charset.*;
 import junit.framework.TestCase;
 public class TestDecoder extends TestCase {
 public static void main(String[] args) {
 junit.textui.TestRunner.run(TestDecoder.class);
 }
 public static void testDecoder(){
 try{
 ByteBuffer bb = ByteBuffer.allocate(1); 
 bb.put(0,(byte)77); 
 CharsetDecoder utf16D = Charset.forName(UTF-16).newDecoder();
 CharBuffer cb = 
 utf16D.onMalformedInput(CodingErrorAction.REPLACE).onUnmappableCharacter(CodingErrorAction.REPLACE).decode(bb);
 }catch(Exception e){
 fail(Exception occured: +e);
 }
 }
 }
 Output on RI:
 .
 Time: 0,03
 OK (1 test)
 Output with Harmony:
 .F
 Time: 0,01
 There was 1 failure:
 1) testDecoder(TestDecoder)junit.framework.AssertionFailedError: Exception 
 occured: java.nio.BufferOverflowException
 at TestDecoder.testDecoder(TestDecoder.java:20)
 at 
 java.lang.reflect.AccessibleObject.invokeV(AccessibleObject.java:211)
 at TestDecoder.main(TestDecoder.java:10)
 FAILURES!!!
 Tests run: 1,  Failures: 1,  Errors: 0

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



[jira] Assigned: (HARMONY-67) java.nio.charset.Charset.decode(ByteBuffer) throws unexpected BufferOverflowException for UTF-16BE, UTF-16LE, UTF-16 charsets.

2006-02-14 Thread Tim Ellison (JIRA)
 [ http://issues.apache.org/jira/browse/HARMONY-67?page=all ]

Tim Ellison reassigned HARMONY-67:
--

Assign To: Tim Ellison

 java.nio.charset.Charset.decode(ByteBuffer) throws unexpected 
 BufferOverflowException  for UTF-16BE, UTF-16LE, UTF-16 charsets.
 ---

  Key: HARMONY-67
  URL: http://issues.apache.org/jira/browse/HARMONY-67
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Svetlana Samoilenko
 Assignee: Tim Ellison


 According to j2se 1.4.2 specification for Charset.decode(ByteBuffer  b) the 
 method must not throw any exceptions.
 The test listed below shows that there is unexpected BufferOverflowException 
 thrown if charset name is one in the following:  UTF-16BE, UTF-16LE, UTF-16.
 BEA does not throw any exceptions.
 Code to reproduce: 
 import java.nio.charset.Charset; 
 import java.nio.ByteBuffer; 
 import java.nio.CharBuffer; 
 public class test2 {   
 public static void main(String[] args) throws Exception { 
 byte[] b = new byte[] {(byte)1}; 
 ByteBuffer buf= ByteBuffer.wrap(b); 
 CharBuffer charbuf=Charset.forName(UTF-16).decode(buf); 
 System.out.println(CharBuffer.length()=+ charbuf.length());
 } 
 }
 Steps to Reproduce: 
 1. Build Harmony (check-out on 2006-01-30) j2se subset as described in 
 README.txt. 
 2. Compile test2.java using BEA 1.4 javac 
  javac -d . test2.java 
 3. Run java using compatible VM (J9) 
  java -showversion test2 
 Output: 
 C:\tmpC:\jrockit-j2sdk1.4.2_04\bin\java.exe -showversion test2 
 java version 1.4.2_04 
 Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) 
 BEA WebLogic JRockit(TM) 1.4.2_04 JVM (build 
 ari-31788-20040616-1132-win-ia32, Native Threads, GC strategy: parallel) 
 CharBuffer.length()=0
 C:\tmpC:\harmony\trunk\deploy\jre\bin\java -showversion test2 
 (c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as 
 applicable. 
  java.nio.BufferOverflowException
 at java.nio.CharBuffer.put(CharBuffer.java:662) 
 at java.nio.CharBuffer.put(CharBuffer.java:629) 
 at java.nio.charset.CharsetDecoder.decode(CharsetDecoder.java:406) 
 at java.nio.charset.CharsetDecoder.decode(CharsetDecoder.java:243) 
 at java.nio.charset.Charset.decode(Charset.java:630) 
 at test2.main(test2.java:8)
 Suggested junit test case:
  CharsetTest.java 
 - 
 import java.nio.charset.Charset; 
 import java.nio.ByteBuffer; 
 import java.nio.CharBuffer; 
 import junit.framework.*; 
 public class CharsetTest extends TestCase { 
 public static void main(String[] args) { 
 junit.textui.TestRunner.run(CharsetTest.class); 
 } 
 public void test_decode() { 
 byte[] b = new byte[] {(byte)1}; 
 ByteBuffer buf= ByteBuffer.wrap(b); 
 CharBuffer charbuf=Charset.forName(UTF-16).decode(buf); 
 assertEquals(Assert 0: charset UTF-16,0,charbuf.length());
 
 charbuf=Charset.forName(UTF-16BE).decode(buf); 
 assertEquals(Assert 1: charset UTF-16BE,0, charbuf.length());   
  
 
 charbuf=Charset.forName(UTF-16LE).decode(buf); 
 assertEquals(Assert 2: charset UTF16LE,0, charbuf.length());
 
} 
 }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



build fails - what next?

2006-02-14 Thread karan malhi
I followed the steps on the incubator website to build classlib from 
source. Build fails. What should I do next? Should I file a JIRA. I 
tried asking questions on the IRC channel but looks like that channel is 
just for general chat and not serious issues


--
Karan Singh



[jira] Resolved: (HARMONY-67) java.nio.charset.Charset.decode(ByteBuffer) throws unexpected BufferOverflowException for UTF-16BE, UTF-16LE, UTF-16 charsets.

2006-02-14 Thread Tim Ellison (JIRA)
 [ http://issues.apache.org/jira/browse/HARMONY-67?page=all ]
 
Tim Ellison resolved HARMONY-67:


Resolution: Fixed

Svetlana,

Fixed in NIO_CHAR module java.nio.charset.CharsetDecoder at repo revision 
377729.

Please check that this fully resolves your problem.


 java.nio.charset.Charset.decode(ByteBuffer) throws unexpected 
 BufferOverflowException  for UTF-16BE, UTF-16LE, UTF-16 charsets.
 ---

  Key: HARMONY-67
  URL: http://issues.apache.org/jira/browse/HARMONY-67
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Svetlana Samoilenko
 Assignee: Tim Ellison


 According to j2se 1.4.2 specification for Charset.decode(ByteBuffer  b) the 
 method must not throw any exceptions.
 The test listed below shows that there is unexpected BufferOverflowException 
 thrown if charset name is one in the following:  UTF-16BE, UTF-16LE, UTF-16.
 BEA does not throw any exceptions.
 Code to reproduce: 
 import java.nio.charset.Charset; 
 import java.nio.ByteBuffer; 
 import java.nio.CharBuffer; 
 public class test2 {   
 public static void main(String[] args) throws Exception { 
 byte[] b = new byte[] {(byte)1}; 
 ByteBuffer buf= ByteBuffer.wrap(b); 
 CharBuffer charbuf=Charset.forName(UTF-16).decode(buf); 
 System.out.println(CharBuffer.length()=+ charbuf.length());
 } 
 }
 Steps to Reproduce: 
 1. Build Harmony (check-out on 2006-01-30) j2se subset as described in 
 README.txt. 
 2. Compile test2.java using BEA 1.4 javac 
  javac -d . test2.java 
 3. Run java using compatible VM (J9) 
  java -showversion test2 
 Output: 
 C:\tmpC:\jrockit-j2sdk1.4.2_04\bin\java.exe -showversion test2 
 java version 1.4.2_04 
 Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) 
 BEA WebLogic JRockit(TM) 1.4.2_04 JVM (build 
 ari-31788-20040616-1132-win-ia32, Native Threads, GC strategy: parallel) 
 CharBuffer.length()=0
 C:\tmpC:\harmony\trunk\deploy\jre\bin\java -showversion test2 
 (c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as 
 applicable. 
  java.nio.BufferOverflowException
 at java.nio.CharBuffer.put(CharBuffer.java:662) 
 at java.nio.CharBuffer.put(CharBuffer.java:629) 
 at java.nio.charset.CharsetDecoder.decode(CharsetDecoder.java:406) 
 at java.nio.charset.CharsetDecoder.decode(CharsetDecoder.java:243) 
 at java.nio.charset.Charset.decode(Charset.java:630) 
 at test2.main(test2.java:8)
 Suggested junit test case:
  CharsetTest.java 
 - 
 import java.nio.charset.Charset; 
 import java.nio.ByteBuffer; 
 import java.nio.CharBuffer; 
 import junit.framework.*; 
 public class CharsetTest extends TestCase { 
 public static void main(String[] args) { 
 junit.textui.TestRunner.run(CharsetTest.class); 
 } 
 public void test_decode() { 
 byte[] b = new byte[] {(byte)1}; 
 ByteBuffer buf= ByteBuffer.wrap(b); 
 CharBuffer charbuf=Charset.forName(UTF-16).decode(buf); 
 assertEquals(Assert 0: charset UTF-16,0,charbuf.length());
 
 charbuf=Charset.forName(UTF-16BE).decode(buf); 
 assertEquals(Assert 1: charset UTF-16BE,0, charbuf.length());   
  
 
 charbuf=Charset.forName(UTF-16LE).decode(buf); 
 assertEquals(Assert 2: charset UTF16LE,0, charbuf.length());
 
} 
 }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



[jira] Resolved: (HARMONY-33) java.nio.BufferOverflow exception while decoding ByteBuffer with UTF-16 charset

2006-02-14 Thread Tim Ellison (JIRA)
 [ http://issues.apache.org/jira/browse/HARMONY-33?page=all ]
 
Tim Ellison resolved HARMONY-33:


Resolution: Fixed

Vladimir,

Fixed in NIO_CHAR module java.nio.charset.CharsetDecoder at repo revision 
377729.

Please check that this fully resolves your problem.


 java.nio.BufferOverflow exception while decoding ByteBuffer with UTF-16 
 charset
 ---

  Key: HARMONY-33
  URL: http://issues.apache.org/jira/browse/HARMONY-33
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Vladimir Strigun
 Assignee: Tim Ellison
 Priority: Minor


 If I try to decode ByteBuffer with lengh 1 using UTF-16 decoder unexpected 
 java.nio.BufferOverflow exception occured. Please see testcase below.
 import java.nio.*;
 import java.nio.charset.*;
 import junit.framework.TestCase;
 public class TestDecoder extends TestCase {
 public static void main(String[] args) {
 junit.textui.TestRunner.run(TestDecoder.class);
 }
 public static void testDecoder(){
 try{
 ByteBuffer bb = ByteBuffer.allocate(1); 
 bb.put(0,(byte)77); 
 CharsetDecoder utf16D = Charset.forName(UTF-16).newDecoder();
 CharBuffer cb = 
 utf16D.onMalformedInput(CodingErrorAction.REPLACE).onUnmappableCharacter(CodingErrorAction.REPLACE).decode(bb);
 }catch(Exception e){
 fail(Exception occured: +e);
 }
 }
 }
 Output on RI:
 .
 Time: 0,03
 OK (1 test)
 Output with Harmony:
 .F
 Time: 0,01
 There was 1 failure:
 1) testDecoder(TestDecoder)junit.framework.AssertionFailedError: Exception 
 occured: java.nio.BufferOverflowException
 at TestDecoder.testDecoder(TestDecoder.java:20)
 at 
 java.lang.reflect.AccessibleObject.invokeV(AccessibleObject.java:211)
 at TestDecoder.main(TestDecoder.java:10)
 FAILURES!!!
 Tests run: 1,  Failures: 1,  Errors: 0

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



Re: build fails - what next?

2006-02-14 Thread karan malhi

Alexey,
Thanks for such a quick response. I have copied the errors below:

compile.api:
[echo] Compiling api classes from 
/home/karan/projects/Harmony/modules/security2/src/common/javasrc, 
/home/karan/projects/Harmony/modules/security2/src/linux/javasrc
   [javac] Compiling 1 source file to 
/home/karan/projects/Harmony/modules/security2/build/classes

   [javac] --
   [javac] 1. ERROR in 
/home/karan/projects/Harmony/modules/security2/src/common/javasrc/javax/crypto/SealedObject.java

   [javac]  (at line 63)
   [javac] encodedParams = (byte []) s.readUnshared();
   [javac] 
   [javac] The method readUnshared() is undefined for the type 
ObjectInputStream

   [javac] --
   [javac] 2. ERROR in 
/home/karan/projects/Harmony/modules/security2/src/common/javasrc/javax/crypto/SealedObject.java

   [javac]  (at line 64)
   [javac] encryptedContent = (byte []) s.readUnshared();
   [javac]
   [javac] The method readUnshared() is undefined for the type 
ObjectInputStream

   [javac] --
   [javac] 3. ERROR in 
/home/karan/projects/Harmony/modules/security2/src/common/javasrc/javax/crypto/SealedObject.java

   [javac]  (at line 65)
   [javac] sealAlg = (String) s.readUnshared();
   [javac]  
   [javac] The method readUnshared() is undefined for the type 
ObjectInputStream

   [javac] --
   [javac] 4. ERROR in 
/home/karan/projects/Harmony/modules/security2/src/common/javasrc/javax/crypto/SealedObject.java

   [javac]  (at line 66)
   [javac] paramsAlg = (String) s.readUnshared();
   [javac]
   [javac] The method readUnshared() is undefined for the type 
ObjectInputStream

   [javac] --
   [javac] 4 problems (4 errors)

BUILD FAILED
/home/karan/projects/Harmony/make/build.xml:41: The following error 
occurred while executing this line:
/home/karan/projects/Harmony/native-src/build.xml:103: The following 
error occurred while executing this line:
/home/karan/projects/Harmony/modules/security2/make/build.xml:299: 
Compile failed; see the compiler error output for details.



Alexey Petrenko wrote:


First of all you can add error message to your post :)

--
Alexey A. Petrenko
Intel Middleware Products Division
 



--
Karan Singh



[jira] Assigned: (HARMONY-85) java.util.jar.Attributes.Name(String name) does not throw IllegalArgumentException if name.length 70

2006-02-14 Thread Tim Ellison (JIRA)
 [ http://issues.apache.org/jira/browse/HARMONY-85?page=all ]

Tim Ellison reassigned HARMONY-85:
--

Assign To: Tim Ellison

 java.util.jar.Attributes.Name(String name) does not throw 
 IllegalArgumentException if name.length  70
 --

  Key: HARMONY-85
  URL: http://issues.apache.org/jira/browse/HARMONY-85
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Svetlana Samoilenko
 Assignee: Tim Ellison


 According to j2se 1.4.2 and 1.5 specification for Attributes.Name(String 
 name) a string length cannot exceed 70 characters.
 Harmony does not throw IllegalArgumentException if name.length  70. 
 Code to reproduce: import java.util.jar.*;
 public class test2 { 
 public static void main(String args[]) throws Exception { 
 try { 
 //no more than 70 chars in attribute name allowed 
 new Attributes.Name( 
 01234567890123456789012345678901234567890123456789012345678901234567890); 
 System.out.println(Failed. Should be IllegalArgumentException 
 ); 
 } catch(IllegalArgumentException e) { 
 System.out.println(Expected IllegalArgumentException); 
 } 
 } 
 }
 Steps to Reproduce: 
 1. Build Harmony (check-out on 2006-01-30) j2se subset as described in 
 README.txt. 
 2. Compile test2.java using BEA 1.4 javac 
  javac -d . test2.java 
 3. Run java using compatible VM (J9) 
  java -showversion test2
 Output: 
 C:\tmpC:\jrockit-j2sdk1.4.2_04\bin\java.exe -showversion test2 
 java version 1.4.2_04 
 Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) 
 BEA WebLogic JRockit(TM) 1.4.2_04 JVM (build 
 ari-31788-20040616-1132-win-ia32, Native Threads, GC strategy: parallel) 
 Expected IllegalArgumentException
  C:\tmpC:\harmony\trunk\deploy\jre\bin\java -showversion test2 
 (c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as 
 applicable.
 Failed. Should be IllegalArgumentException
 Siggested fix: 
 @@ -84,7 +84,7 @@
 public Name(String s) {
   int i = s.length();
 - if (i == 0)
 + if (i == 0 || i 70)
 throw new IllegalArgumentException();
   for (; --i = 0;) {
 char ch = s.charAt(i);
 Suggested junit test case:
  AttributesTest.java 
 - 
 import java.util.jar.*;
 import junit.framework.*; 
 public class AttributesTest extends TestCase { 
 public static void main(String[] args) { 
 junit.textui.TestRunner.run(AttributesTest.class); 
 } 
 public void test_constructor () { 
 try {
 new Attributes.Name( 
 01234567890123456789012345678901234567890123456789012345678901234567890); 
 fail(Should be IllegalArgumentException); 
 } catch(IllegalArgumentException e) { 
 //expected
 }
 } 
 }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



Re: build fails - what next?

2006-02-14 Thread Alexey Petrenko
I can not reproduce your errors on my machine with latest sources.

So you can try to update your sources and check the build environment.

Which commnad do you run for building? I've tried to run ant from
classlib/trunk/make directory.

--
Alexey A. Petrenko
Intel Middleware Products Division


[jira] Resolved: (HARMONY-85) java.util.jar.Attributes.Name(String name) does not throw IllegalArgumentException if name.length 70

2006-02-14 Thread Tim Ellison (JIRA)
 [ http://issues.apache.org/jira/browse/HARMONY-85?page=all ]
 
Tim Ellison resolved HARMONY-85:


Resolution: Fixed

Svetlana,

Fixed in archive module in java.util.jar.Attributes.Name at repo revision 
377734.

Please check that this fully resolves your problem.


 java.util.jar.Attributes.Name(String name) does not throw 
 IllegalArgumentException if name.length  70
 --

  Key: HARMONY-85
  URL: http://issues.apache.org/jira/browse/HARMONY-85
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Svetlana Samoilenko
 Assignee: Tim Ellison


 According to j2se 1.4.2 and 1.5 specification for Attributes.Name(String 
 name) a string length cannot exceed 70 characters.
 Harmony does not throw IllegalArgumentException if name.length  70. 
 Code to reproduce: import java.util.jar.*;
 public class test2 { 
 public static void main(String args[]) throws Exception { 
 try { 
 //no more than 70 chars in attribute name allowed 
 new Attributes.Name( 
 01234567890123456789012345678901234567890123456789012345678901234567890); 
 System.out.println(Failed. Should be IllegalArgumentException 
 ); 
 } catch(IllegalArgumentException e) { 
 System.out.println(Expected IllegalArgumentException); 
 } 
 } 
 }
 Steps to Reproduce: 
 1. Build Harmony (check-out on 2006-01-30) j2se subset as described in 
 README.txt. 
 2. Compile test2.java using BEA 1.4 javac 
  javac -d . test2.java 
 3. Run java using compatible VM (J9) 
  java -showversion test2
 Output: 
 C:\tmpC:\jrockit-j2sdk1.4.2_04\bin\java.exe -showversion test2 
 java version 1.4.2_04 
 Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) 
 BEA WebLogic JRockit(TM) 1.4.2_04 JVM (build 
 ari-31788-20040616-1132-win-ia32, Native Threads, GC strategy: parallel) 
 Expected IllegalArgumentException
  C:\tmpC:\harmony\trunk\deploy\jre\bin\java -showversion test2 
 (c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as 
 applicable.
 Failed. Should be IllegalArgumentException
 Siggested fix: 
 @@ -84,7 +84,7 @@
 public Name(String s) {
   int i = s.length();
 - if (i == 0)
 + if (i == 0 || i 70)
 throw new IllegalArgumentException();
   for (; --i = 0;) {
 char ch = s.charAt(i);
 Suggested junit test case:
  AttributesTest.java 
 - 
 import java.util.jar.*;
 import junit.framework.*; 
 public class AttributesTest extends TestCase { 
 public static void main(String[] args) { 
 junit.textui.TestRunner.run(AttributesTest.class); 
 } 
 public void test_constructor () { 
 try {
 new Attributes.Name( 
 01234567890123456789012345678901234567890123456789012345678901234567890); 
 fail(Should be IllegalArgumentException); 
 } catch(IllegalArgumentException e) { 
 //expected
 }
 } 
 }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



Re: build fails - what next?

2006-02-14 Thread karan malhi
I just tried to follow the steps to build classlib. Here is the link to 
the page I followed the instructions from.


http://incubator.apache.org/harmony/subcomponents/classlibrary/build_classlib.html

I ran ant from the Harmony/make folder

Alexey Petrenko wrote:


I can not reproduce your errors on my machine with latest sources.

So you can try to update your sources and check the build environment.

Which commnad do you run for building? I've tried to run ant from
classlib/trunk/make directory.

--
Alexey A. Petrenko
Intel Middleware Products Division
 



--
Karan Singh



Re: build fails - what next?

2006-02-14 Thread Alexey Petrenko
[javac] 1. ERROR in
 /home/karan/projects/Harmony/modules/security2/src/common/javasrc/javax/crypto/SealedObject.java
[javac]  (at line 63)
[javac] encodedParams = (byte []) s.readUnshared();
[javac] 
[javac] The method readUnshared() is undefined for the type
 ObjectInputStream

What JVM do you use to run ant? It seems that there is no
ObjectInputStream.readUnshared method in your JVM...

--
Alexey A. Petrenko
Intel Middleware Products Division


Re: [classlib] build / test system

2006-02-14 Thread Dalibor Topic
Geir Magnusson Jr geir at pobox.com writes:

 That was a mistake, the BCL stuff.  

Yeah, I believe everyone agrees on that.

 That is being taken care of.

Does that mean tomcat 4[1] will it be pulled completely from Apache.org,
or will there be a new release? 

It would be easy to write a script that unpacks all the tarballs on 
dist, finds all jars, zipinfo's them and greps for sun to spot 
problematic projects and 'quarantene' them, so that we don't distribute
bits that may impose additional hardships on unassuming users of Apache
software, as we currently unfortunately still seem to do[2].

cheers,
dalibor topic

[1] And for some odd reason tomcat 4.1.31 binary relase tarball doesn't 
seem to mention BCL anywhere, despite having lots of com.sun.* classes 
in the various jars, which makes sanitizing it so painful: one needs 
to look into every single JAR to figure out if it is redistributable 
at all, or not. Yay non-transferable proprietary licenses. :/

So ... please let's always document where each bundled artifact came from, 
under which license and version it was included, for the sake of our users. 
If that's not an ASF policy already, it should become one, and we should
start using it in harmony by documenting origins, licenses and 
versions of our dependencies for all to see and verify.

[2]
http://www.apache.org/dist/tomcat/tomcat-4/v4.1.31/bin/jakarta-tomcat-4.1.31.tar.gz



Re: build fails - what next?

2006-02-14 Thread Tim Ellison
Can you tell us which JDK you are using build the code? and which platform?

FWIW I just tried building the code (at SVN revision 377734) with Sun's
JDK 1.4.2 and it worked ok.

Regards,
Tim

karan malhi wrote:
 I just tried to follow the steps to build classlib. Here is the link to
 the page I followed the instructions from.
 
 http://incubator.apache.org/harmony/subcomponents/classlibrary/build_classlib.html
 
 
 I ran ant from the Harmony/make folder
 
 Alexey Petrenko wrote:
 
 I can not reproduce your errors on my machine with latest sources.

 So you can try to update your sources and check the build environment.

 Which commnad do you run for building? I've tried to run ant from
 classlib/trunk/make directory.

 -- 
 Alexey A. Petrenko
 Intel Middleware Products Division
  

 

-- 

Tim Ellison ([EMAIL PROTECTED])
IBM Java technology centre, UK.


Re: build fails - what next?

2006-02-14 Thread karan malhi

[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre VM 
version = 4.0.2 20051125 (Red Hat 4.0.2-8) vendor = Free Software 
Foundation, Inc.



Alexey Petrenko wrote:


  [javac] 1. ERROR in
/home/karan/projects/Harmony/modules/security2/src/common/javasrc/javax/crypto/SealedObject.java
  [javac]  (at line 63)
  [javac] encodedParams = (byte []) s.readUnshared();
  [javac] 
  [javac] The method readUnshared() is undefined for the type
ObjectInputStream
   



What JVM do you use to run ant? It seems that there is no
ObjectInputStream.readUnshared method in your JVM...

--
Alexey A. Petrenko
Intel Middleware Products Division
 



--
Karan Singh



Re: [jchevm] native method API for _jc_new_intern_string -- do you plan to add to _jc_ilib_entry table?

2006-02-14 Thread Archie Cobbs

Tim Ellison wrote:

sure -- String interning is in the kernel precisely so that the VM
implementor (i.e. you) can choose to do it in native or Java code.

Of course, they have to be interned into the same table as the JLS
string literals.


Of course :-) JCHEVM handles this correctly.

-Archie

__
Archie Cobbs  *CTO, Awarix*  http://www.awarix.com


Re: build fails - what next?

2006-02-14 Thread Geir Magnusson Jr

That's the problem.  As far as I know, GCJ isn't quite complete yet...



karan malhi wrote:

[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre VM 
version = 4.0.2 20051125 (Red Hat 4.0.2-8) vendor = Free Software 
Foundation, Inc.



Alexey Petrenko wrote:


  [javac] 1. ERROR in
/home/karan/projects/Harmony/modules/security2/src/common/javasrc/javax/crypto/SealedObject.java 


  [javac]  (at line 63)
  [javac] encodedParams = (byte []) s.readUnshared();
  [javac] 
  [javac] The method readUnshared() is undefined for the type
ObjectInputStream
  


What JVM do you use to run ant? It seems that there is no
ObjectInputStream.readUnshared method in your JVM...

--
Alexey A. Petrenko
Intel Middleware Products Division
 





[classlib] creating a new snapshot, and planned breakage heads-up

2006-02-14 Thread Tim Ellison
I'd like to propose that we create a new snapshot of the classlib code
and make it available on the binary downloads page:
http://cvs.apache.org/dist/incubator/harmony/snapshots/

Now that the security2 code is integrated into the build it seems a good
time to refresh the snapshot, and there have been quite a few fixes in
other parts.

In addition, and once the snapshot is safely tucked away, I'd like to
break the world :-)

I want to rename some of the packages in LUNI from com.ibm to
org.apache.  Some of these packages are referenced by kernel code, which
means that there will need to be a new IBM Harmony VME made available on
Developerworks.  Unfortunately (due to the renaming) you will not be
able to use an old Harmony VME with the new classlib code and vice versa.

Please indicate ASAP if you object to this renaming work taking place
within the next couple of days.

Regards,
Tim

-- 

Tim Ellison ([EMAIL PROTECTED])
IBM Java technology centre, UK.


Re: build fails - what next?

2006-02-14 Thread karan malhi

I set JAVA_HOME to jdk1.5 and the build still fails

timestamp:
[echo] build-date=20060214
[echo] build-time=20060214_1033)
[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /home/karan/jdk1.5.0_06/jre VM version = 
1.5.0_06-b05 vendor = Sun Microsystems Inc.


BUILD FAILED
/home/karan/projects/Harmony/make/build.xml:41: The following error 
occurred while executing this line:
/home/karan/projects/Harmony/native-src/build.xml:103: The following 
error occurred while executing this line:
/home/karan/projects/Harmony/modules/security2/make/build.xml:331: The 
following error occurred while executing this line:
/home/karan/projects/Harmony/modules/security2/make/native/linux/jaasnix.xml:72: 
exec returned: 1



Geir Magnusson Jr wrote:


That's the problem.  As far as I know, GCJ isn't quite complete yet...



karan malhi wrote:


[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre 
VM version = 4.0.2 20051125 (Red Hat 4.0.2-8) vendor = Free Software 
Foundation, Inc.



Alexey Petrenko wrote:


  [javac] 1. ERROR in
/home/karan/projects/Harmony/modules/security2/src/common/javasrc/javax/crypto/SealedObject.java 


  [javac]  (at line 63)
  [javac] encodedParams = (byte []) s.readUnshared();
  [javac] 
  [javac] The method readUnshared() is undefined for the type
ObjectInputStream
  



What JVM do you use to run ant? It seems that there is no
ObjectInputStream.readUnshared method in your JVM...

--
Alexey A. Petrenko
Intel Middleware Products Division
 







--
Karan Singh



Re: [jchevm] native method API for _jc_new_intern_string -- do you plan to add to _jc_ilib_entry table?

2006-02-14 Thread Weldon Washburn
For the initial hello world phase of Harmony Class Library on
JCHEVM, I wrote a real stupid, simple String intern in java.  It can
be replaced later with a more sophisticated version.

Question -- does it make sense to include a stupid, simple
String.intern() in the kernel class to make it even easier and more
convenient for someone trying to graft Harmony Class Libraries to a
new JVM?

 - Weldon


On 2/14/06, Archie Cobbs [EMAIL PROTECTED] wrote:
 Tim Ellison wrote:
  sure -- String interning is in the kernel precisely so that the VM
  implementor (i.e. you) can choose to do it in native or Java code.
 
  Of course, they have to be interned into the same table as the JLS
  string literals.

 Of course :-) JCHEVM handles this correctly.

 -Archie

 __
 Archie Cobbs  *CTO, Awarix*  http://www.awarix.com



--
Weldon Washburn
Intel Middleware Products Division


Re: [classlib] build / test system

2006-02-14 Thread Geir Magnusson Jr



Dalibor Topic wrote:

Geir Magnusson Jr geir at pobox.com writes:

That was a mistake, the BCL stuff.  


Yeah, I believe everyone agrees on that.


That is being taken care of.


Does that mean tomcat 4[1] will it be pulled completely from Apache.org,
or will there be a new release? 


I have no clue, and I'm not too worried about it.  It's something for 
them to work out.


geir



Re: build fails - what next?

2006-02-14 Thread Alexey Petrenko
JAVA_HOME will not help if you want to run ant on different JDK.
set JAVACMD to the full path to java executable.

--
Alexey A. Petrenko
Intel Middleware Products Division


Re: build fails - what next?

2006-02-14 Thread Geir Magnusson Jr

ok.  Now we're making progress.

Did you look at what that line in the xml document is?  It's the c/c++ 
compiler.


There's a file outerr.txt  That should have more information about 
what exactly failed...


Can you look there and report back?


karan malhi wrote:

I set JAVA_HOME to jdk1.5 and the build still fails

timestamp:
[echo] build-date=20060214
[echo] build-time=20060214_1033)
[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /home/karan/jdk1.5.0_06/jre VM version = 
1.5.0_06-b05 vendor = Sun Microsystems Inc.


BUILD FAILED
/home/karan/projects/Harmony/make/build.xml:41: The following error 
occurred while executing this line:
/home/karan/projects/Harmony/native-src/build.xml:103: The following 
error occurred while executing this line:
/home/karan/projects/Harmony/modules/security2/make/build.xml:331: The 
following error occurred while executing this line:
/home/karan/projects/Harmony/modules/security2/make/native/linux/jaasnix.xml:72: 
exec returned: 1



Geir Magnusson Jr wrote:


That's the problem.  As far as I know, GCJ isn't quite complete yet...



karan malhi wrote:


[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre 
VM version = 4.0.2 20051125 (Red Hat 4.0.2-8) vendor = Free Software 
Foundation, Inc.



Alexey Petrenko wrote:


  [javac] 1. ERROR in
/home/karan/projects/Harmony/modules/security2/src/common/javasrc/javax/crypto/SealedObject.java 


  [javac]  (at line 63)
  [javac] encodedParams = (byte []) s.readUnshared();
  [javac] 
  [javac] The method readUnshared() is undefined for the type
ObjectInputStream
  



What JVM do you use to run ant? It seems that there is no
ObjectInputStream.readUnshared method in your JVM...

--
Alexey A. Petrenko
Intel Middleware Products Division
 









Re: build fails - what next?

2006-02-14 Thread Geir Magnusson Jr
Please - always provide at least a snippet of the note to which you are 
replying (including author) to make it easy for someone to read the 
thread...




Alexey Petrenko wrote:

JAVA_HOME will not help if you want to run ant on different JDK.
set JAVACMD to the full path to java executable.

--
Alexey A. Petrenko
Intel Middleware Products Division




Re: build fails - what next?

2006-02-14 Thread Oliver Deakin

Hi Karan,

Line 72 of jaasnix.xml is:
exec executable=${compiler.name} output=${tmp}/outerr.txt 
failonerror=true


so its a call to the make command on your system. It also produces 
output from the make into ${tmp}/outerr.txt, which I believe
expands to modules/security2/build/tmp/outerr.txt (at least that is 
where it appears on my machine). Inside that file there
should be error messages from the build which will be more helpful for 
diagnosing the problem.


--
Oliver Deakin
IBM United Kingdom Limited



karan malhi wrote:

I set JAVA_HOME to jdk1.5 and the build still fails

timestamp:
[echo] build-date=20060214
[echo] build-time=20060214_1033)
[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /home/karan/jdk1.5.0_06/jre VM version = 
1.5.0_06-b05 vendor = Sun Microsystems Inc.


BUILD FAILED
/home/karan/projects/Harmony/make/build.xml:41: The following error 
occurred while executing this line:
/home/karan/projects/Harmony/native-src/build.xml:103: The following 
error occurred while executing this line:
/home/karan/projects/Harmony/modules/security2/make/build.xml:331: The 
following error occurred while executing this line:
/home/karan/projects/Harmony/modules/security2/make/native/linux/jaasnix.xml:72: 
exec returned: 1



Geir Magnusson Jr wrote:


That's the problem.  As far as I know, GCJ isn't quite complete yet...



karan malhi wrote:


[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre 
VM version = 4.0.2 20051125 (Red Hat 4.0.2-8) vendor = Free Software 
Foundation, Inc.



Alexey Petrenko wrote:


  [javac] 1. ERROR in
/home/karan/projects/Harmony/modules/security2/src/common/javasrc/javax/crypto/SealedObject.java 


  [javac]  (at line 63)
  [javac] encodedParams = (byte []) s.readUnshared();
  [javac] 
  [javac] The method readUnshared() is undefined for the type
ObjectInputStream
  



What JVM do you use to run ant? It seems that there is no
ObjectInputStream.readUnshared method in your JVM...

--
Alexey A. Petrenko
Intel Middleware Products Division
 











Re: [classlib] creating a new snapshot, and planned breakage heads-up

2006-02-14 Thread Tim Ellison
Geir Magnusson Jr wrote:
 I object :)
 
 I don't mean that seriously.
 
 Here is what I want to do first -
 
 I'll do the security change as agreed, and get the regex/bean/math in,
 so that the snapshot has all we can.  Even try to get some of the
 testcase or sql code in.

hey! get in line ... ;-)

 Let me suggest we discuss a different way - when do you plan on breaking?

Timing is not crucial, so whatever suits best (was thinking some time
during Wed - Fri).

The LUNI package renaming will touch a number of modules, so I can
either lock the world until I'm done, or release each of the renamed
references over a short period of time (expect ~1hr svn-willing).
After the rename you *will* need a new version of the IBM Harmony VME if
you want to continue running it on that VM.

Regards,
Tim

 gier
 
 
 Tim Ellison wrote:
 I'd like to propose that we create a new snapshot of the classlib code
 and make it available on the binary downloads page:
 http://cvs.apache.org/dist/incubator/harmony/snapshots/

 Now that the security2 code is integrated into the build it seems a good
 time to refresh the snapshot, and there have been quite a few fixes in
 other parts.

 In addition, and once the snapshot is safely tucked away, I'd like to
 break the world :-)

 I want to rename some of the packages in LUNI from com.ibm to
 org.apache.  Some of these packages are referenced by kernel code, which
 means that there will need to be a new IBM Harmony VME made available on
 Developerworks.  Unfortunately (due to the renaming) you will not be
 able to use an old Harmony VME with the new classlib code and vice versa.

 Please indicate ASAP if you object to this renaming work taking place
 within the next couple of days.

 Regards,
 Tim

 

-- 

Tim Ellison ([EMAIL PROTECTED])
IBM Java technology centre, UK.


Re: [classlib] creating a new snapshot, and planned breakage heads-up

2006-02-14 Thread Geir Magnusson Jr



Tim Ellison wrote:

Geir Magnusson Jr wrote:

I object :)

I don't mean that seriously.

Here is what I want to do first -

I'll do the security change as agreed, and get the regex/bean/math in,
so that the snapshot has all we can.  Even try to get some of the
testcase or sql code in.


hey! get in line ... ;-)


Hey, it's your testcases I was talking about.




Let me suggest we discuss a different way - when do you plan on breaking?


Timing is not crucial, so whatever suits best (was thinking some time
during Wed - Fri).

The LUNI package renaming will touch a number of modules, so I can
either lock the world until I'm done, or release each of the renamed
references over a short period of time (expect ~1hr svn-willing).
After the rename you *will* need a new version of the IBM Harmony VME if
you want to continue running it on that VM


Ok.  I assume that you can get a new VME to the IBM website that 
supports the changes you are making before/simultaneous to the commit 
you do?


IOW, could you do the changes on your system, and do the commit when you 
are reasonably certain that the VME will be available so it doesn't hose 
the rest of us?


Also, can you leave a link up for the old VME too?

In parallel, I can make the changes to security and r/b/m and get the 
snapshot built and published.


How does that sound?

geir



Re: build fails - what next? -- outerr.txt

2006-02-14 Thread karan malhi

Below are the contents of the file outerr.txt

gcc: installation problem, cannot exec 'cc1plus': No such file or directory

I dont know why it is still saying gcc problem. I specified a JAVACMD 
variable to point to the java executable under jdk1.5/bin,  as Alexey 
had mentioned in a previous email.


Geir Magnusson Jr wrote:


ok.  Now we're making progress.

Did you look at what that line in the xml document is?  It's the c/c++ 
compiler.


There's a file outerr.txt  That should have more information about 
what exactly failed...


Can you look there and report back?


karan malhi wrote:


I set JAVA_HOME to jdk1.5 and the build still fails

timestamp:
[echo] build-date=20060214
[echo] build-time=20060214_1033)
[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /home/karan/jdk1.5.0_06/jre VM version = 
1.5.0_06-b05 vendor = Sun Microsystems Inc.


BUILD FAILED
/home/karan/projects/Harmony/make/build.xml:41: The following error 
occurred while executing this line:
/home/karan/projects/Harmony/native-src/build.xml:103: The following 
error occurred while executing this line:
/home/karan/projects/Harmony/modules/security2/make/build.xml:331: 
The following error occurred while executing this line:
/home/karan/projects/Harmony/modules/security2/make/native/linux/jaasnix.xml:72: 
exec returned: 1



Geir Magnusson Jr wrote:


That's the problem.  As far as I know, GCJ isn't quite complete yet...



karan malhi wrote:


[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre 
VM version = 4.0.2 20051125 (Red Hat 4.0.2-8) vendor = Free 
Software Foundation, Inc.



Alexey Petrenko wrote:


  [javac] 1. ERROR in
/home/karan/projects/Harmony/modules/security2/src/common/javasrc/javax/crypto/SealedObject.java 


  [javac]  (at line 63)
  [javac] encodedParams = (byte []) s.readUnshared();
  [javac] 
  [javac] The method readUnshared() is undefined for the type
ObjectInputStream
  




What JVM do you use to run ant? It seems that there is no
ObjectInputStream.readUnshared method in your JVM...

--
Alexey A. Petrenko
Intel Middleware Products Division
 











--
Karan Singh



Re: build fails - what next? -- outerr.txt

2006-02-14 Thread Geir Magnusson Jr
It has nothing to do w/ Java.  That's the C++ compiler for GCC.  Your 
installation of GCC is incomplete it appears - it doesn't seem to have 
C++ installed.


(Hey Tim... what was that you were saying about C++??)

geir



karan malhi wrote:

Below are the contents of the file outerr.txt

gcc: installation problem, cannot exec 'cc1plus': No such file or directory

I dont know why it is still saying gcc problem. I specified a JAVACMD 
variable to point to the java executable under jdk1.5/bin,  as Alexey 
had mentioned in a previous email.


Geir Magnusson Jr wrote:


ok.  Now we're making progress.

Did you look at what that line in the xml document is?  It's the c/c++ 
compiler.


There's a file outerr.txt  That should have more information about 
what exactly failed...


Can you look there and report back?


karan malhi wrote:


I set JAVA_HOME to jdk1.5 and the build still fails

timestamp:
[echo] build-date=20060214
[echo] build-time=20060214_1033)
[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /home/karan/jdk1.5.0_06/jre VM version = 
1.5.0_06-b05 vendor = Sun Microsystems Inc.


BUILD FAILED
/home/karan/projects/Harmony/make/build.xml:41: The following error 
occurred while executing this line:
/home/karan/projects/Harmony/native-src/build.xml:103: The following 
error occurred while executing this line:
/home/karan/projects/Harmony/modules/security2/make/build.xml:331: 
The following error occurred while executing this line:
/home/karan/projects/Harmony/modules/security2/make/native/linux/jaasnix.xml:72: 
exec returned: 1



Geir Magnusson Jr wrote:


That's the problem.  As far as I know, GCJ isn't quite complete yet...



karan malhi wrote:


[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre 
VM version = 4.0.2 20051125 (Red Hat 4.0.2-8) vendor = Free 
Software Foundation, Inc.



Alexey Petrenko wrote:


  [javac] 1. ERROR in
/home/karan/projects/Harmony/modules/security2/src/common/javasrc/javax/crypto/SealedObject.java 


  [javac]  (at line 63)
  [javac] encodedParams = (byte []) s.readUnshared();
  [javac] 
  [javac] The method readUnshared() is undefined for the type
ObjectInputStream
  




What JVM do you use to run ant? It seems that there is no
ObjectInputStream.readUnshared method in your JVM...

--
Alexey A. Petrenko
Intel Middleware Products Division
 













Re: build fails - what next? -- outerr.txt

2006-02-14 Thread Alexey Petrenko
 I specified a JAVACMD variable to point to the java executable
 under jdk1.5/bin,  as Alexey had mentioned in a previous email.
Did it build Java part after that?

--
Alexey A. Petrenko
Intel Middleware Products Division


Re: build fails - what next? -- outerr.txt

2006-02-14 Thread karan malhi
I dont know why it is still saying gcc problem. I specified a JAVACMD 
variable to point to the java executable under jdk1.5/bin,  as Alexey 
had mentioned in a previous email. 


I didnt realize it was a gcc issue and not a gcj issue. Sorry

Geir Magnusson Jr wrote:


ok.  Now we're making progress.

Did you look at what that line in the xml document is?  It's the c/c++ 
compiler.


There's a file outerr.txt  That should have more information about 
what exactly failed...


Can you look there and report back?


karan malhi wrote:


I set JAVA_HOME to jdk1.5 and the build still fails

timestamp:
[echo] build-date=20060214
[echo] build-time=20060214_1033)
[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /home/karan/jdk1.5.0_06/jre VM version = 
1.5.0_06-b05 vendor = Sun Microsystems Inc.


BUILD FAILED
/home/karan/projects/Harmony/make/build.xml:41: The following error 
occurred while executing this line:
/home/karan/projects/Harmony/native-src/build.xml:103: The following 
error occurred while executing this line:
/home/karan/projects/Harmony/modules/security2/make/build.xml:331: 
The following error occurred while executing this line:
/home/karan/projects/Harmony/modules/security2/make/native/linux/jaasnix.xml:72: 
exec returned: 1



Geir Magnusson Jr wrote:


That's the problem.  As far as I know, GCJ isn't quite complete yet...



karan malhi wrote:


[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre 
VM version = 4.0.2 20051125 (Red Hat 4.0.2-8) vendor = Free 
Software Foundation, Inc.



Alexey Petrenko wrote:


  [javac] 1. ERROR in
/home/karan/projects/Harmony/modules/security2/src/common/javasrc/javax/crypto/SealedObject.java 


  [javac]  (at line 63)
  [javac] encodedParams = (byte []) s.readUnshared();
  [javac] 
  [javac] The method readUnshared() is undefined for the type
ObjectInputStream
  




What JVM do you use to run ant? It seems that there is no
ObjectInputStream.readUnshared method in your JVM...

--
Alexey A. Petrenko
Intel Middleware Products Division
 











--
Karan Singh



Re: build fails - what next? -- outerr.txt

2006-02-14 Thread Geir Magnusson Jr

no problem.  We're here to help. This stuff isn't always obvious...

karan malhi wrote:
I dont know why it is still saying gcc problem. I specified a JAVACMD 
variable to point to the java executable under jdk1.5/bin,  as Alexey 
had mentioned in a previous email. 


I didnt realize it was a gcc issue and not a gcj issue. Sorry

Geir Magnusson Jr wrote:


ok.  Now we're making progress.

Did you look at what that line in the xml document is?  It's the c/c++ 
compiler.


There's a file outerr.txt  That should have more information about 
what exactly failed...


Can you look there and report back?


karan malhi wrote:


I set JAVA_HOME to jdk1.5 and the build still fails

timestamp:
[echo] build-date=20060214
[echo] build-time=20060214_1033)
[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /home/karan/jdk1.5.0_06/jre VM version = 
1.5.0_06-b05 vendor = Sun Microsystems Inc.


BUILD FAILED
/home/karan/projects/Harmony/make/build.xml:41: The following error 
occurred while executing this line:
/home/karan/projects/Harmony/native-src/build.xml:103: The following 
error occurred while executing this line:
/home/karan/projects/Harmony/modules/security2/make/build.xml:331: 
The following error occurred while executing this line:
/home/karan/projects/Harmony/modules/security2/make/native/linux/jaasnix.xml:72: 
exec returned: 1



Geir Magnusson Jr wrote:


That's the problem.  As far as I know, GCJ isn't quite complete yet...



karan malhi wrote:


[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre 
VM version = 4.0.2 20051125 (Red Hat 4.0.2-8) vendor = Free 
Software Foundation, Inc.



Alexey Petrenko wrote:


  [javac] 1. ERROR in
/home/karan/projects/Harmony/modules/security2/src/common/javasrc/javax/crypto/SealedObject.java 


  [javac]  (at line 63)
  [javac] encodedParams = (byte []) s.readUnshared();
  [javac] 
  [javac] The method readUnshared() is undefined for the type
ObjectInputStream
  




What JVM do you use to run ant? It seems that there is no
ObjectInputStream.readUnshared method in your JVM...

--
Alexey A. Petrenko
Intel Middleware Products Division
 













Re: Using Cairo for Harmony graphic stuff?

2006-02-14 Thread Davanum Srinivas
Pluggable look and feel
(http://java.sun.com/j2se/1.4.2/docs/api/javax/swing/plaf/package-summary.html)

-- dims

On 2/14/06, Stefano Mazzocchi [EMAIL PROTECTED] wrote:
 Anton Avtamonov wrote:
  Yeah, thank you Tim.
 
  I also thought about SwingWT when saw Stefano's letter.
  Unfortunately such approach have serious problem with supporting PLAF
  concept, as I know :-(, but really very fast (thanks to swt :-))

 what's PLAF?

 
  --
  Anton Avtamonov,
  Intel Middleware Products Division
 
 
  On 2/13/06, Tim Ellison [EMAIL PROTECTED] wrote:
  http://swingwt.sourceforge.net/
 
  (I merely mention it, not recommending it)
 
  Regards,
  Tim
 
  Stefano Mazzocchi wrote:
  Anton Avtamonov wrote:
  On 2/13/06, Stefano Mazzocchi [EMAIL PROTECTED] wrote:
  [snip]
  The other thing to consider is to follow apple's advice and implement
  Swing using native widgets. I don't know what this entails in terms of
  complexity but I always found stupid that swing is barely scratching the
  surface of what my GPU accelerator could do for me.
 
  [snip]
  --
  Stefano.
 
  Hi Stefano,
 
  Am I right you propose to implement Swing on native widgets? I mean
  using real native push buttons, etc. and get rid of 'standard' Swing
  approach to have lightweight platform-independent stuff? Sorry if I
  caught you wrong...
  I don't even know what I'm saying myself :-)
 
  All I know is that I want something fast that feels as solid as SWT on
  windows or swing/java2d on macosx.
 
  Unfortunately, I don't think I know enough how to figure out how to get
  there though, but I suspect you guys do ;-)
 
  --
 
  Tim Ellison ([EMAIL PROTECTED])
  IBM Java technology centre, UK.
 


 --
 Stefano.




--
Davanum Srinivas : http://wso2.com/blogs/


Re: Using Cairo for Harmony graphic stuff?

2006-02-14 Thread Geir Magnusson Jr

Isn't it a rice dish?

Stefano Mazzocchi wrote:

Anton Avtamonov wrote:

Yeah, thank you Tim.

I also thought about SwingWT when saw Stefano's letter.
Unfortunately such approach have serious problem with supporting PLAF
concept, as I know :-(, but really very fast (thanks to swt :-))


what's PLAF?



--
Anton Avtamonov,
Intel Middleware Products Division


On 2/13/06, Tim Ellison [EMAIL PROTECTED] wrote:

http://swingwt.sourceforge.net/

(I merely mention it, not recommending it)

Regards,
Tim

Stefano Mazzocchi wrote:

Anton Avtamonov wrote:

On 2/13/06, Stefano Mazzocchi [EMAIL PROTECTED] wrote:
[snip]

The other thing to consider is to follow apple's advice and implement
Swing using native widgets. I don't know what this entails in 
terms of
complexity but I always found stupid that swing is barely 
scratching the

surface of what my GPU accelerator could do for me.


[snip]

--
Stefano.


Hi Stefano,

Am I right you propose to implement Swing on native widgets? I mean
using real native push buttons, etc. and get rid of 'standard' Swing
approach to have lightweight platform-independent stuff? Sorry if I
caught you wrong...

I don't even know what I'm saying myself :-)

All I know is that I want something fast that feels as solid as SWT on
windows or swing/java2d on macosx.

Unfortunately, I don't think I know enough how to figure out how to get
there though, but I suspect you guys do ;-)


--

Tim Ellison ([EMAIL PROTECTED])
IBM Java technology centre, UK.






Re: [jchevm] native method API for _jc_new_intern_string -- do you plan to add to _jc_ilib_entry table?

2006-02-14 Thread Tim Ellison
Weldon Washburn wrote:
 Question -- does it make sense to include a stupid, simple
 String.intern() in the kernel class to make it even easier and more
 convenient for someone trying to graft Harmony Class Libraries to a
 new JVM?

Sure, we can add it to the KERNEL module stubs so people can choose to
reuse it or replace it as they see fit.  Care to contribute yours?

Regards,
Tim

-- 

Tim Ellison ([EMAIL PROTECTED])
IBM Java technology centre, UK.


Re: Using Cairo for Harmony graphic stuff?

2006-02-14 Thread Davanum Srinivas
hehe :) good one for those uninitiated...that's with an 'i' like so
(http://images.google.com/images?hl=enq=pilaf)

-- dims

On 2/14/06, Geir Magnusson Jr [EMAIL PROTECTED] wrote:
 Isn't it a rice dish?

 Stefano Mazzocchi wrote:
  Anton Avtamonov wrote:
  Yeah, thank you Tim.
 
  I also thought about SwingWT when saw Stefano's letter.
  Unfortunately such approach have serious problem with supporting PLAF
  concept, as I know :-(, but really very fast (thanks to swt :-))
 
  what's PLAF?
 
 
  --
  Anton Avtamonov,
  Intel Middleware Products Division
 
 
  On 2/13/06, Tim Ellison [EMAIL PROTECTED] wrote:
  http://swingwt.sourceforge.net/
 
  (I merely mention it, not recommending it)
 
  Regards,
  Tim
 
  Stefano Mazzocchi wrote:
  Anton Avtamonov wrote:
  On 2/13/06, Stefano Mazzocchi [EMAIL PROTECTED] wrote:
  [snip]
  The other thing to consider is to follow apple's advice and implement
  Swing using native widgets. I don't know what this entails in
  terms of
  complexity but I always found stupid that swing is barely
  scratching the
  surface of what my GPU accelerator could do for me.
 
  [snip]
  --
  Stefano.
 
  Hi Stefano,
 
  Am I right you propose to implement Swing on native widgets? I mean
  using real native push buttons, etc. and get rid of 'standard' Swing
  approach to have lightweight platform-independent stuff? Sorry if I
  caught you wrong...
  I don't even know what I'm saying myself :-)
 
  All I know is that I want something fast that feels as solid as SWT on
  windows or swing/java2d on macosx.
 
  Unfortunately, I don't think I know enough how to figure out how to get
  there though, but I suspect you guys do ;-)
 
  --
 
  Tim Ellison ([EMAIL PROTECTED])
  IBM Java technology centre, UK.
 
 
 



--
Davanum Srinivas : http://wso2.com/blogs/


Re: build fails - what next?

2006-02-14 Thread Stuart Ballard
Geir Magnusson Jr geir at pobox.com writes:
 
 That's the problem.  As far as I know, GCJ isn't quite complete yet...
 

[javac]  (at line 63)
[javac] encodedParams = (byte []) s.readUnshared();
[javac] 
[javac] The method readUnshared() is undefined for the type
  ObjectInputStream

http://www.kaffe.org/~stuart/japi/htmlout/cvs/h-jdk14-classpath#err_missing_java_io

Congratulations! You managed to hit one of the only two missing methods in
Classpath's implementation of java.io. Might want to report what this breaks on
the Classpath list - they're usually quick to fix holes like this if they break
a real app, especially if it's a Free one.

Of course, getting it fixed is an entirely different issue from getting it into
gcj in a released version of your distro...

Stuart.



Re: Using Cairo for Harmony graphic stuff?

2006-02-14 Thread Stefano Mazzocchi

Tim Ellison wrote:

... or the sound a user makes when they see a Swing app start up.


ROTFL :-)


Tim

Davanum Srinivas wrote:

Pluggable look and feel
(http://java.sun.com/j2se/1.4.2/docs/api/javax/swing/plaf/package-summary.html)

-- dims

On 2/14/06, Stefano Mazzocchi [EMAIL PROTECTED] wrote:

Anton Avtamonov wrote:

Yeah, thank you Tim.

I also thought about SwingWT when saw Stefano's letter.
Unfortunately such approach have serious problem with supporting PLAF
concept, as I know :-(, but really very fast (thanks to swt :-))

what's PLAF?


--
Anton Avtamonov,
Intel Middleware Products Division


On 2/13/06, Tim Ellison [EMAIL PROTECTED] wrote:

http://swingwt.sourceforge.net/

(I merely mention it, not recommending it)

Regards,
Tim

Stefano Mazzocchi wrote:

Anton Avtamonov wrote:

On 2/13/06, Stefano Mazzocchi [EMAIL PROTECTED] wrote:
[snip]

The other thing to consider is to follow apple's advice and implement
Swing using native widgets. I don't know what this entails in terms of
complexity but I always found stupid that swing is barely scratching the
surface of what my GPU accelerator could do for me.


[snip]

--
Stefano.


Hi Stefano,

Am I right you propose to implement Swing on native widgets? I mean
using real native push buttons, etc. and get rid of 'standard' Swing
approach to have lightweight platform-independent stuff? Sorry if I
caught you wrong...

I don't even know what I'm saying myself :-)

All I know is that I want something fast that feels as solid as SWT on
windows or swing/java2d on macosx.

Unfortunately, I don't think I know enough how to figure out how to get
there though, but I suspect you guys do ;-)


--

Tim Ellison ([EMAIL PROTECTED])
IBM Java technology centre, UK.


--
Stefano.




--
Davanum Srinivas : http://wso2.com/blogs/






--
Stefano.



Re: build fails - what next? -- outerr.txt

2006-02-14 Thread Alexey Petrenko
So Java part is built and you got troubles with gcc...


2006/2/14, karan malhi [EMAIL PROTECTED]:
 Alexey,
 I have set the JAVACMD variable to point to java executable explicitly
 as you can see below:
 [EMAIL PROTECTED] make]$ echo $JAVACMD
 /home/karan/jdk1.5.0_06/bin/java

 Below is the complete output after running ant.

 [EMAIL PROTECTED] make]$ ant
 Buildfile: build.xml

 default:
  [echo]
  [echo] 
  [echo] Building Java component archives...
  [echo] 

 clean-bin:
[delete] Deleting 1645 files from /home/karan/projects/Harmony/bin
[delete] Deleted 85 directories from /home/karan/projects/Harmony/bin

 clean-layout:
[delete] Deleting 34 files from /home/karan/projects/Harmony/deploy

 clean-package:
[delete] Deleting 11 files from /home/karan/projects/Harmony/components
[delete] Deleted 1 directory from /home/karan/projects/Harmony/components

 clean:

 copy-resources:
 [mkdir] Created dir: /home/karan/projects/Harmony/bin
  [copy] Copying 2 files to /home/karan/projects/Harmony/bin

 compile:
 [javac] Compiling 1280 source files to /home/karan/projects/Harmony/bin
 [javac] Note: Some input files use or override a deprecated API.
 [javac] Note: Recompile with -Xlint:deprecation for details.

 package:
 [mkdir] Created dir: /home/karan/projects/Harmony/components
   [jar] Building jar:
 /home/karan/projects/Harmony/components/archive.jar
   [jar] Building jar:
 /home/karan/projects/Harmony/components/kernel-stubs.jar
   [jar] Building jar: /home/karan/projects/Harmony/components/luni.jar
   [jar] Building jar: /home/karan/projects/Harmony/components/nio.jar
   [jar] Building jar:
 /home/karan/projects/Harmony/components/nio_char.jar
   [jar] Building jar:
 /home/karan/projects/Harmony/components/security.jar
   [jar] Building jar: /home/karan/projects/Harmony/components/x-net.jar
   [jar] Building jar: /home/karan/projects/Harmony/components/text.jar
   [jar] Building jar: /home/karan/projects/Harmony/components/math.jar
   [jar] Building jar: /home/karan/projects/Harmony/components/regex.jar
   [jar] Building jar: /home/karan/projects/Harmony/components/sql.jar

 layout:
  [copy] Copying 2 files to
 /home/karan/projects/Harmony/deploy/jre/lib/boot
  [copy] Copying 11 files to
 /home/karan/projects/Harmony/deploy/jre/lib/boot
  [copy] Copying 1 file to
 /home/karan/projects/Harmony/deploy/jre/lib/boot
  [copy] Copying 18 files to /home/karan/projects/Harmony/deploy/jre/bin
  [copy] Copying 2 files to
 /home/karan/projects/Harmony/deploy/jre/lib/security

 default:
  [echo]
  [echo] 
  [echo] Building native libs and executables...
  [echo] 

 init:

 windows-properties:

 linux-properties:

 properties:

 overlay-oss:
 [unzip] Expanding:
 /home/karan/projects/Harmony/depends/oss/fdlibm_5.2.zip into
 /home/karan/projects/Harmony/native-src/linux.IA32/fdlibm
 [unzip] Expanding:
 /home/karan/projects/Harmony/depends/oss/zlib_1.2.3.zip into
 /home/karan/projects/Harmony/native-src/linux.IA32/zlib
 [unzip] Expanding:
 /home/karan/projects/Harmony/depends/oss/linux.IA32/icu4c-3.4-harmony.zip
 into /home/karan/projects/Harmony/native-src/linux.IA32

 make-clean:

 make-all:

 timestamp:
  [echo] build-date=20060214
  [echo] build-time=20060214_1115)
  [echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
  [echo] with java home = /home/karan/jdk1.5.0_06/jre VM version =
 1.5.0_06-b05 vendor = Sun Microsystems Inc.

 setname.win:

 setname.linux:

 init:
  [echo] platform name=lnx
  [echo] if.x86_64=${if.x86_64}
  [echo] if.x86=true
  [echo] if.ipf=${if.ipf}
  [echo] create base dirs...

 init.java_home:
  [echo] JAVA_HOME=/home/karan/jdk1.5.0_06

 init.win:

 init.linux:

 compile.api:
  [echo] Compiling api classes from
 /home/karan/projects/Harmony/modules/security2/src/common/javasrc,
 /home/karan/projects/Harmony/modules/security2/src/linux/javasrc

 build.jars:

 build.one.jar:

 build.one.jar:

 build.one.jar:

 build.native:
  [echo]
 jni_h.path=/home/karan/projects/Harmony/native-src/linux.IA32/include
  [echo]
 jni_md_h.path=/home/karan/projects/Harmony/native-src/linux.IA32/include

 init:
  [echo] native_compiler.name=gcc
  [echo] library.name=jaasnix
  [echo]
 ntvlibname.path=/home/karan/projects/Harmony/modules/security2/src/linux/other/jaasnix

 compile.linux.native:
  [echo] make linux native...
  [echo]
 path.to.build.native=/home/karan/projects/Harmony/modules/security2/src/linux/other/jaasnix

 BUILD FAILED
 /home/karan/projects/Harmony/make/build.xml:41: The following error
 occurred while executing this line:
 /home/karan/projects/Harmony/native-src/build.xml:103: The following
 error

Re: build fails - what next? -- outerr.txt

2006-02-14 Thread karan malhi

The build was successful. The problem was with gcc-c++.
Thanks for all the help.

Alexey Petrenko wrote:


So Java part is built and you got troubles with gcc...


2006/2/14, karan malhi [EMAIL PROTECTED]:
 


Alexey,
I have set the JAVACMD variable to point to java executable explicitly
as you can see below:
   [EMAIL PROTECTED] make]$ echo $JAVACMD
   /home/karan/jdk1.5.0_06/bin/java

Below is the complete output after running ant.

[EMAIL PROTECTED] make]$ ant
Buildfile: build.xml

default:
[echo]
[echo] 
[echo] Building Java component archives...
[echo] 

clean-bin:
  [delete] Deleting 1645 files from /home/karan/projects/Harmony/bin
  [delete] Deleted 85 directories from /home/karan/projects/Harmony/bin

clean-layout:
  [delete] Deleting 34 files from /home/karan/projects/Harmony/deploy

clean-package:
  [delete] Deleting 11 files from /home/karan/projects/Harmony/components
  [delete] Deleted 1 directory from /home/karan/projects/Harmony/components

clean:

copy-resources:
   [mkdir] Created dir: /home/karan/projects/Harmony/bin
[copy] Copying 2 files to /home/karan/projects/Harmony/bin

compile:
   [javac] Compiling 1280 source files to /home/karan/projects/Harmony/bin
   [javac] Note: Some input files use or override a deprecated API.
   [javac] Note: Recompile with -Xlint:deprecation for details.

package:
   [mkdir] Created dir: /home/karan/projects/Harmony/components
 [jar] Building jar:
/home/karan/projects/Harmony/components/archive.jar
 [jar] Building jar:
/home/karan/projects/Harmony/components/kernel-stubs.jar
 [jar] Building jar: /home/karan/projects/Harmony/components/luni.jar
 [jar] Building jar: /home/karan/projects/Harmony/components/nio.jar
 [jar] Building jar:
/home/karan/projects/Harmony/components/nio_char.jar
 [jar] Building jar:
/home/karan/projects/Harmony/components/security.jar
 [jar] Building jar: /home/karan/projects/Harmony/components/x-net.jar
 [jar] Building jar: /home/karan/projects/Harmony/components/text.jar
 [jar] Building jar: /home/karan/projects/Harmony/components/math.jar
 [jar] Building jar: /home/karan/projects/Harmony/components/regex.jar
 [jar] Building jar: /home/karan/projects/Harmony/components/sql.jar

layout:
[copy] Copying 2 files to
/home/karan/projects/Harmony/deploy/jre/lib/boot
[copy] Copying 11 files to
/home/karan/projects/Harmony/deploy/jre/lib/boot
[copy] Copying 1 file to
/home/karan/projects/Harmony/deploy/jre/lib/boot
[copy] Copying 18 files to /home/karan/projects/Harmony/deploy/jre/bin
[copy] Copying 2 files to
/home/karan/projects/Harmony/deploy/jre/lib/security

default:
[echo]
[echo] 
[echo] Building native libs and executables...
[echo] 

init:

windows-properties:

linux-properties:

properties:

overlay-oss:
   [unzip] Expanding:
/home/karan/projects/Harmony/depends/oss/fdlibm_5.2.zip into
/home/karan/projects/Harmony/native-src/linux.IA32/fdlibm
   [unzip] Expanding:
/home/karan/projects/Harmony/depends/oss/zlib_1.2.3.zip into
/home/karan/projects/Harmony/native-src/linux.IA32/zlib
   [unzip] Expanding:
/home/karan/projects/Harmony/depends/oss/linux.IA32/icu4c-3.4-harmony.zip
into /home/karan/projects/Harmony/native-src/linux.IA32

make-clean:

make-all:

timestamp:
[echo] build-date=20060214
[echo] build-time=20060214_1115)
[echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
[echo] with java home = /home/karan/jdk1.5.0_06/jre VM version =
1.5.0_06-b05 vendor = Sun Microsystems Inc.

setname.win:

setname.linux:

init:
[echo] platform name=lnx
[echo] if.x86_64=${if.x86_64}
[echo] if.x86=true
[echo] if.ipf=${if.ipf}
[echo] create base dirs...

init.java_home:
[echo] JAVA_HOME=/home/karan/jdk1.5.0_06

init.win:

init.linux:

compile.api:
[echo] Compiling api classes from
/home/karan/projects/Harmony/modules/security2/src/common/javasrc,
/home/karan/projects/Harmony/modules/security2/src/linux/javasrc

build.jars:

build.one.jar:

build.one.jar:

build.one.jar:

build.native:
[echo]
jni_h.path=/home/karan/projects/Harmony/native-src/linux.IA32/include
[echo]
jni_md_h.path=/home/karan/projects/Harmony/native-src/linux.IA32/include

init:
[echo] native_compiler.name=gcc
[echo] library.name=jaasnix
[echo]
ntvlibname.path=/home/karan/projects/Harmony/modules/security2/src/linux/other/jaasnix

compile.linux.native:
[echo] make linux native...
[echo]
path.to.build.native=/home/karan/projects/Harmony/modules/security2/src/linux/other/jaasnix

BUILD FAILED
/home/karan/projects/Harmony/make/build.xml:41: The following error
occurred while executing this line:
/home/karan/projects/Harmony/native-src/build.xml:103: The following
error occurred while executing this line:
/home/karan/projects/Harmony

Re: build fails - what next? -- outerr.txt

2006-02-14 Thread Tim Ellison
great -- let us know what you do with it!

Regards,
Tim

karan malhi wrote:
 The build was successful. The problem was with gcc-c++.
 Thanks for all the help.
 
 Alexey Petrenko wrote:
 
 So Java part is built and you got troubles with gcc...


 2006/2/14, karan malhi [EMAIL PROTECTED]:
  

 Alexey,
 I have set the JAVACMD variable to point to java executable explicitly
 as you can see below:
[EMAIL PROTECTED] make]$ echo $JAVACMD
/home/karan/jdk1.5.0_06/bin/java

 Below is the complete output after running ant.

 [EMAIL PROTECTED] make]$ ant
 Buildfile: build.xml

 default:
 [echo]
 [echo] 
 [echo] Building Java component archives...
 [echo] 

 clean-bin:
   [delete] Deleting 1645 files from /home/karan/projects/Harmony/bin
   [delete] Deleted 85 directories from /home/karan/projects/Harmony/bin

 clean-layout:
   [delete] Deleting 34 files from /home/karan/projects/Harmony/deploy

 clean-package:
   [delete] Deleting 11 files from
 /home/karan/projects/Harmony/components
   [delete] Deleted 1 directory from
 /home/karan/projects/Harmony/components

 clean:

 copy-resources:
[mkdir] Created dir: /home/karan/projects/Harmony/bin
 [copy] Copying 2 files to /home/karan/projects/Harmony/bin

 compile:
[javac] Compiling 1280 source files to
 /home/karan/projects/Harmony/bin
[javac] Note: Some input files use or override a deprecated API.
[javac] Note: Recompile with -Xlint:deprecation for details.

 package:
[mkdir] Created dir: /home/karan/projects/Harmony/components
  [jar] Building jar:
 /home/karan/projects/Harmony/components/archive.jar
  [jar] Building jar:
 /home/karan/projects/Harmony/components/kernel-stubs.jar
  [jar] Building jar:
 /home/karan/projects/Harmony/components/luni.jar
  [jar] Building jar: /home/karan/projects/Harmony/components/nio.jar
  [jar] Building jar:
 /home/karan/projects/Harmony/components/nio_char.jar
  [jar] Building jar:
 /home/karan/projects/Harmony/components/security.jar
  [jar] Building jar:
 /home/karan/projects/Harmony/components/x-net.jar
  [jar] Building jar:
 /home/karan/projects/Harmony/components/text.jar
  [jar] Building jar:
 /home/karan/projects/Harmony/components/math.jar
  [jar] Building jar:
 /home/karan/projects/Harmony/components/regex.jar
  [jar] Building jar: /home/karan/projects/Harmony/components/sql.jar

 layout:
 [copy] Copying 2 files to
 /home/karan/projects/Harmony/deploy/jre/lib/boot
 [copy] Copying 11 files to
 /home/karan/projects/Harmony/deploy/jre/lib/boot
 [copy] Copying 1 file to
 /home/karan/projects/Harmony/deploy/jre/lib/boot
 [copy] Copying 18 files to
 /home/karan/projects/Harmony/deploy/jre/bin
 [copy] Copying 2 files to
 /home/karan/projects/Harmony/deploy/jre/lib/security

 default:
 [echo]
 [echo] 
 [echo] Building native libs and executables...
 [echo] 

 init:

 windows-properties:

 linux-properties:

 properties:

 overlay-oss:
[unzip] Expanding:
 /home/karan/projects/Harmony/depends/oss/fdlibm_5.2.zip into
 /home/karan/projects/Harmony/native-src/linux.IA32/fdlibm
[unzip] Expanding:
 /home/karan/projects/Harmony/depends/oss/zlib_1.2.3.zip into
 /home/karan/projects/Harmony/native-src/linux.IA32/zlib
[unzip] Expanding:
 /home/karan/projects/Harmony/depends/oss/linux.IA32/icu4c-3.4-harmony.zip

 into /home/karan/projects/Harmony/native-src/linux.IA32

 make-clean:

 make-all:

 timestamp:
 [echo] build-date=20060214
 [echo] build-time=20060214_1115)
 [echo] on platform=Linux version=2.6.14-1.1656_FC4 arch=i386
 [echo] with java home = /home/karan/jdk1.5.0_06/jre VM version =
 1.5.0_06-b05 vendor = Sun Microsystems Inc.

 setname.win:

 setname.linux:

 init:
 [echo] platform name=lnx
 [echo] if.x86_64=${if.x86_64}
 [echo] if.x86=true
 [echo] if.ipf=${if.ipf}
 [echo] create base dirs...

 init.java_home:
 [echo] JAVA_HOME=/home/karan/jdk1.5.0_06

 init.win:

 init.linux:

 compile.api:
 [echo] Compiling api classes from
 /home/karan/projects/Harmony/modules/security2/src/common/javasrc,
 /home/karan/projects/Harmony/modules/security2/src/linux/javasrc

 build.jars:

 build.one.jar:

 build.one.jar:

 build.one.jar:

 build.native:
 [echo]
 jni_h.path=/home/karan/projects/Harmony/native-src/linux.IA32/include
 [echo]
 jni_md_h.path=/home/karan/projects/Harmony/native-src/linux.IA32/include

 init:
 [echo] native_compiler.name=gcc
 [echo] library.name=jaasnix
 [echo]
 ntvlibname.path=/home/karan/projects/Harmony/modules/security2/src/linux/other/jaasnix


 compile.linux.native:
 [echo] make linux native...
 [echo]
 path.to.build.native=/home/karan/projects/Harmony/modules/security2/src/linux/other/jaasnix


 BUILD FAILED
 /home/karan/projects/Harmony/make

Re: error when using sun compiler

2006-02-14 Thread Thomas Engelschmidt

Hi,

Try java -version or which java - to clarify the version and path of the 
java binary.


regards


karan malhi wrote:


Hi,

Tried to compile and run a simple hello world program. When I use the 
eclipse programmer, it works fine, but when I use the sun's jdk 
compiler, I get an error . I am still trying to get a feel of this 
project, so probably this was not supposed to work. Could you please 
help me understand why am I getting this error?


-Eclipse Compiler ---
[EMAIL PROTECTED] bin]$ pwd
/home/karan/projects/Harmony/deploy/jre/bin

[EMAIL PROTECTED] bin]$ javac -version
Eclipse Java Compiler v_579_R31x, 3.1.1 release, Copyright IBM Corp 
2000, 2005. All rights reserved.


[EMAIL PROTECTED] bin]$ javac Test.java
[EMAIL PROTECTED] bin]$ ./java Test
Hello World

---Suns JDK 
[EMAIL PROTECTED] bin]$ ~/jdk1.5.0_06/bin/javac -version
javac 1.5.0_06

[EMAIL PROTECTED] bin]$ ~/jdk1.5.0_06/bin/javac Test.java

[EMAIL PROTECTED] bin]$ ./java Test
Exception in thread main java.lang.UnsupportedClassVersionError: 
(Test) bad major version at offset=6

   at java.lang.ClassLoader.defineClassImpl(Native Method)
   at java.lang.ClassLoader.defineClass(ClassLoader.java:271)
   at 
java.security.SecureClassLoader.defineClass(SecureClassLoader.java:64)

   at java.net.URLClassLoader.findClassImpl(URLClassLoader.java:1087)
   at java.net.URLClassLoader$4.run(URLClassLoader.java:598)
   at 
java.security.AccessController.doPrivileged(AccessController.java:206)

   at java.net.URLClassLoader.findClass(URLClassLoader.java:595)
   at 
com.ibm.oti.vm.URLSystemClassLoader.findClass(URLSystemClassLoader.java:25) 


   at java.lang.ClassLoader.loadClass(ClassLoader.java:631)
   at 
com.ibm.oti.vm.URLSystemClassLoader.loadClass(URLSystemClassLoader.java:56) 


   at java.lang.ClassLoader.loadClass(ClassLoader.java:587)





Re: error when using sun compiler

2006-02-14 Thread Alexey Petrenko
 ---Suns JDK 
 [EMAIL PROTECTED] bin]$ ~/jdk1.5.0_06/bin/javac -version
 javac 1.5.0_06

 [EMAIL PROTECTED] bin]$ ~/jdk1.5.0_06/bin/javac Test.java

 [EMAIL PROTECTED] bin]$ ./java Test
 Exception in thread main java.lang.UnsupportedClassVersionError:
 (Test) bad major version at offset=6
It easy :)
You've compiled a class with 1.5 compiler and then run it on 1.4 VM.
You can fix this issue by two ways:
1. Complile the class with -target 1.4 javac option
(~/jdk1.5.0_06/bin/javac -target 1.4 Test.java) and run as ./java Test
2. Compile without target option as you did it before and run on 1.5
VM (~/jdk1.5.0_06/bin/java Test)

This should help.

--
Alexey A. Petrenko
Intel Middleware Products Division


Re: error when using sun compiler

2006-02-14 Thread karan malhi

[EMAIL PROTECTED] bin]$ ./java -version
java version 1.4.2 (subset)

(c) Copyright 1991, 2005 The Apache Software Foundation or its 
licensors, as applicable.


What I want to do is compile the class with sun jdk and run it within 
harmony. Is it possible to do something like that right now?


Thomas Engelschmidt wrote:


Hi,

Try java -version or which java - to clarify the version and path of 
the java binary.


regards


karan malhi wrote:


Hi,

Tried to compile and run a simple hello world program. When I use the 
eclipse programmer, it works fine, but when I use the sun's jdk 
compiler, I get an error . I am still trying to get a feel of this 
project, so probably this was not supposed to work. Could you please 
help me understand why am I getting this error?


-Eclipse Compiler ---
[EMAIL PROTECTED] bin]$ pwd
/home/karan/projects/Harmony/deploy/jre/bin

[EMAIL PROTECTED] bin]$ javac -version
Eclipse Java Compiler v_579_R31x, 3.1.1 release, Copyright IBM Corp 
2000, 2005. All rights reserved.


[EMAIL PROTECTED] bin]$ javac Test.java
[EMAIL PROTECTED] bin]$ ./java Test
Hello World

---Suns JDK 
[EMAIL PROTECTED] bin]$ ~/jdk1.5.0_06/bin/javac -version
javac 1.5.0_06

[EMAIL PROTECTED] bin]$ ~/jdk1.5.0_06/bin/javac Test.java

[EMAIL PROTECTED] bin]$ ./java Test
Exception in thread main java.lang.UnsupportedClassVersionError: 
(Test) bad major version at offset=6

   at java.lang.ClassLoader.defineClassImpl(Native Method)
   at java.lang.ClassLoader.defineClass(ClassLoader.java:271)
   at 
java.security.SecureClassLoader.defineClass(SecureClassLoader.java:64)
   at 
java.net.URLClassLoader.findClassImpl(URLClassLoader.java:1087)

   at java.net.URLClassLoader$4.run(URLClassLoader.java:598)
   at 
java.security.AccessController.doPrivileged(AccessController.java:206)

   at java.net.URLClassLoader.findClass(URLClassLoader.java:595)
   at 
com.ibm.oti.vm.URLSystemClassLoader.findClass(URLSystemClassLoader.java:25) 


   at java.lang.ClassLoader.loadClass(ClassLoader.java:631)
   at 
com.ibm.oti.vm.URLSystemClassLoader.loadClass(URLSystemClassLoader.java:56) 


   at java.lang.ClassLoader.loadClass(ClassLoader.java:587)






--
Karan Singh



Re: error when using sun compiler

2006-02-14 Thread karan malhi

Thanks Alexey,

This works now. Actually I had to also specify the version of the 
source. When I only specify the -target this is what I get:

[EMAIL PROTECTED] bin]$ ~/jdk1.5.0_06/bin/javac -target 1.4 Test.java
javac: target release 1.4 conflicts with default source release 1.5

However, when i specify both -source and -target, it works fine.
[EMAIL PROTECTED] bin]$ ~/jdk1.5.0_06/bin/javac -target 1.4 -source 1.4 
Test.java
[EMAIL PROTECTED] bin]$ ./java Test
Hello World


Alexey Petrenko wrote:


---Suns JDK 
[EMAIL PROTECTED] bin]$ ~/jdk1.5.0_06/bin/javac -version
javac 1.5.0_06

[EMAIL PROTECTED] bin]$ ~/jdk1.5.0_06/bin/javac Test.java

[EMAIL PROTECTED] bin]$ ./java Test
Exception in thread main java.lang.UnsupportedClassVersionError:
(Test) bad major version at offset=6
   


It easy :)
You've compiled a class with 1.5 compiler and then run it on 1.4 VM.
You can fix this issue by two ways:
1. Complile the class with -target 1.4 javac option
(~/jdk1.5.0_06/bin/javac -target 1.4 Test.java) and run as ./java Test
2. Compile without target option as you did it before and run on 1.5
VM (~/jdk1.5.0_06/bin/java Test)

This should help.

--
Alexey A. Petrenko
Intel Middleware Products Division
 



--
Karan Singh



Re: error when using sun compiler

2006-02-14 Thread Alexey Petrenko
 Actually I had to also specify the version of the
 source.
I'm not using this options very often :)

--
Alexey A. Petrenko
Intel Middleware Products Division


[jira] Created: (HARMONY-92) Suggestion: Move com.ibm.platform from NIO to LUNI

2006-02-14 Thread Richard Liang (JIRA)
Suggestion: Move com.ibm.platform from NIO to LUNI
--

 Key: HARMONY-92
 URL: http://issues.apache.org/jira/browse/HARMONY-92
 Project: Harmony
Type: Improvement
  Components: Classlib  
Reporter: Richard Liang


Hello Tim,

As we discussed in JIRA 27 and JIRA 42, I suggest we move the packages 
com.ibm.platform and com.ibm.platform.struct from NIO to LUNI component. As 
these packages are used by java.net, as well as java.nio.channels. I will post 
the proposed fix soon :-)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



[jira] Commented: (HARMONY-92) Suggestion: Move com.ibm.platform from NIO to LUNI

2006-02-14 Thread Richard Liang (JIRA)
[ 
http://issues.apache.org/jira/browse/HARMONY-92?page=comments#action_12366423 ] 

Richard Liang commented on HARMONY-92:
--

According to the package naming convention 
(http://incubator.apache.org/harmony/subcomponents/classlibrary/pkgnaming.html),
 I suggest we rename com.ibm.platform to org.apache.harmony.luni.platform, and 
com.ibm.platform.struct to org.apache.harmony.luni.platform.struct

Any comments?

 Suggestion: Move com.ibm.platform from NIO to LUNI
 --

  Key: HARMONY-92
  URL: http://issues.apache.org/jira/browse/HARMONY-92
  Project: Harmony
 Type: Improvement
   Components: Classlib
 Reporter: Richard Liang


 Hello Tim,
 As we discussed in JIRA 27 and JIRA 42, I suggest we move the packages 
 com.ibm.platform and com.ibm.platform.struct from NIO to LUNI component. As 
 these packages are used by java.net, as well as java.nio.channels. I will 
 post the proposed fix soon :-)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



Shall we allows to create association between issues in Harmony JIRA system?

2006-02-14 Thread Richard Liang

Dear all,

As the subject. I cannot find Link in the JIRA Operations list. 
Thanks a lot.


--
Richard Liang
China Software Development Lab, IBM




Re: Shall we allows to create association between issues in Harmony JIRA system?

2006-02-14 Thread Geir Magnusson Jr

you should be able to link lemme see...

Ah - I changed the permission scheme to let any jira-user link issues in 
Harmony.


I can't see any harm - someone please bellow if I'm overlooking something.

geir


Richard Liang wrote:

Dear all,

As the subject. I cannot find Link in the JIRA Operations list. 
Thanks a lot.




RE: [classlib] creating a new snapshot, and planned breakage heads-up

2006-02-14 Thread Nathan Beyer
Not that my vote counts for a huge amount, but as long as there's a new IBM
Harmony VME or alternative available in a reasonable amount of time, do as
you please. As I prefer to stick with hacking around in the classlib modules
and leave the rocket science up the smart folk, I'm very dependent on a
working VM to build and execute test cases against.

That's my two cents worth.

-Nathan

-Original Message-
From: Tim Ellison [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, February 14, 2006 8:58 AM
To: harmony-dev
Subject: [classlib] creating a new snapshot, and planned breakage heads-up

I'd like to propose that we create a new snapshot of the classlib code
and make it available on the binary downloads page:
http://cvs.apache.org/dist/incubator/harmony/snapshots/

Now that the security2 code is integrated into the build it seems a good
time to refresh the snapshot, and there have been quite a few fixes in
other parts.

In addition, and once the snapshot is safely tucked away, I'd like to
break the world :-)

I want to rename some of the packages in LUNI from com.ibm to
org.apache.  Some of these packages are referenced by kernel code, which
means that there will need to be a new IBM Harmony VME made available on
Developerworks.  Unfortunately (due to the renaming) you will not be
able to use an old Harmony VME with the new classlib code and vice versa.

Please indicate ASAP if you object to this renaming work taking place
within the next couple of days.

Regards,
Tim

-- 

Tim Ellison ([EMAIL PROTECTED])
IBM Java technology centre, UK.



Re: [classlib] creating a new snapshot, and planned breakage heads-up

2006-02-14 Thread Geir Magnusson Jr
Yes, I think we're committed to ensuring that at any point that things 
are usable and stable.


geir

Nathan Beyer wrote:

Not that my vote counts for a huge amount, but as long as there's a new IBM
Harmony VME or alternative available in a reasonable amount of time, do as
you please. As I prefer to stick with hacking around in the classlib modules
and leave the rocket science up the smart folk, I'm very dependent on a
working VM to build and execute test cases against.

That's my two cents worth.

-Nathan

-Original Message-
From: Tim Ellison [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, February 14, 2006 8:58 AM

To: harmony-dev
Subject: [classlib] creating a new snapshot, and planned breakage heads-up

I'd like to propose that we create a new snapshot of the classlib code
and make it available on the binary downloads page:
http://cvs.apache.org/dist/incubator/harmony/snapshots/

Now that the security2 code is integrated into the build it seems a good
time to refresh the snapshot, and there have been quite a few fixes in
other parts.

In addition, and once the snapshot is safely tucked away, I'd like to
break the world :-)

I want to rename some of the packages in LUNI from com.ibm to
org.apache.  Some of these packages are referenced by kernel code, which
means that there will need to be a new IBM Harmony VME made available on
Developerworks.  Unfortunately (due to the renaming) you will not be
able to use an old Harmony VME with the new classlib code and vice versa.

Please indicate ASAP if you object to this renaming work taking place
within the next couple of days.

Regards,
Tim



Re: compiling JCHEVM with GCC/Cygwin

2006-02-14 Thread snowdosker

Enrico Migliore wrote:


snowdosker wrote:


Hello Enrico

I'm trying to build JCHEVM following your steps described at
http://www.mail-archive.com/harmony-dev@incubator.apache.org/msg03212.html 



I was able to build Classpath sucsesfuly, but
fail making JCHEVM

In result I have

native/java_lang_VMThread.c: In function 
`JCNI_java_lang_VMThread_start':
native/java_lang_VMThread.c:388: warning: implicit declaration of 
function `pthread_attr_setstackaddr'
native/java_lang_VMThread.c:388: warning: nested extern declaration 
of `pthread_attr_setstackaddr'

make[2]: *** [java_lang_VMThread.o] Error 1
make[2]: Leaving directory `/home/ivan/jchevm/libjc'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/ivan/jchevm/libjc'
make: *** [all-recursive] Error 1


Can you help me, please.
Thanks, Ivan




Hi Ivan,

if you're building JCHEVM with Cygwin, modify the following file:

.\libjc\arch\arch_definitions.h

at line 95.

Remove:
#define _JC_LIBRARY_FMTlib%s.so

Add:
#define _JC_LIBRARY_FMTlib%s.dll.a

In order to achieve a successfull build, I had to change a few other 
things.

Before I post them here, let's see how it goes your build.
Are you using a Home or a Professional Windows edition?

Enrico






Hi Enrico,

This trik doesn't work :(
I changed .\libjc\arch\arch_definitions.h as you say but in result I 
have the same


native/java_lang_VMThread.c: In function `JCNI_java_lang_VMThread_start':
native/java_lang_VMThread.c:388: warning: implicit declaration of 
function `pthread_attr_setstackaddr'
native/java_lang_VMThread.c:388: warning: nested extern declaration of 
`pthread_attr_setstackaddr'

make[2]: *** [java_lang_VMThread.o] Error 1
make[2]: Leaving directory `/home/ivan/jchevm/libjc'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/ivan/jchevm/libjc'
make: *** [all-recursive] Error 1


PS: I am using a Home Windows edition.

Ivan



Re: [jchevm] native method API for _jc_new_intern_string -- do you plan to add to _jc_ilib_entry table?

2006-02-14 Thread Weldon Washburn
On 2/14/06, Tim Ellison [EMAIL PROTECTED] wrote:
 Weldon Washburn wrote:
  Question -- does it make sense to include a stupid, simple
  String.intern() in the kernel class to make it even easier and more
  convenient for someone trying to graft Harmony Class Libraries to a
  new JVM?

 Sure, we can add it to the KERNEL module stubs so people can choose to
 reuse it or replace it as they see fit.  Care to contribute yours?
OK. But I warn you its really stupid, really simple and... its never
even been compiled.  Below is the code:

private String [] internArray = new String[256];
public String intern()
{
System.out.println(String.intern() is not fully implemented);

for (int ii = 0; ii  internArray.length; ii++)
{
if (this.equals(internArray[ii]))
return internArray[ii];
if (internArray[ii] == null)
{
internArray[ii] = this;
return this;
}
}
while (true)
System.out.println(String.intern() --- error, overflowed
intern storage);
}

--
Weldon Washburn
Intel Middleware Products Division


Re: [jira] Updated: (HARMONY-57) Contribution of unit test code for a number of components

2006-02-14 Thread Richard Liang

Dear George,

I have tried to run the test cases with Harmony code (2006-02-13). Here 
is what I have found:


1. In the ant script: compile-tests task reports warning: unmappable 
character for encoding GB18030 when I execute the script on my WinXP-SP2 
(Simplified-Chinese version)


== Suggest: add attribute encoding=iso-8859-1 for javac task

2. Two tests fail in tests.api.java.net.URLTest:
   test_ConstructorLjava_lang_StringLjava_lang_StringLjava_lang_String
   test_getAuthority

== Due to a bug (JIRA 60) has been fixed, suggest to update test cases 
accordingly


3. I'm investigating other testing failures/errors, and will post 
further comments soon. :-)


Richard Liang
China Software Development Lab, IBM



George Harley (JIRA) wrote:

 [ http://issues.apache.org/jira/browse/HARMONY-57?page=all ]

George Harley updated HARMONY-57:
-

Attachment: Harmony-Unit-Tests.zip

The contribution zip. 

  

Contribution of unit test code for a number of components
-

 Key: HARMONY-57
 URL: http://issues.apache.org/jira/browse/HARMONY-57
 Project: Harmony
Type: Test
  Components: Contributions
 Environment: All
Reporter: George Harley
 Attachments: Harmony-Unit-Tests.zip

Zip file containing JUnit tests for the following Harmony components :
* archive
* luni
* nio_char
* text
The contents of this zip have been laid out with the current classlib directory structure of the Apache Harmony SVN repository in mind. A version of enhanced/classlib/trunk/make/build-java.xml is included containing new Ant targets to compile and run the tests. 
Some of the tests depend on the availablity of additional resources (text files, jars, etc). These resources are included in the zip along with configuration instructions. 
A small number of the 3000+ test cases are known to fail when run against a built Harmony. The identities of these tests, plus some additional information on them have been listed in the file ZIP_EXTRACT_DIR/Harmony/Harmony_Tests/src/test/resources/config/jcltest-excludes.xml . This file can be used during the running of the tests to purposely exclude the set of known failures. Information on how this is accomplished is also included. 



  


Re: [jchevm] native method API for _jc_new_intern_string -- do you plan to add to _jc_ilib_entry table?

2006-02-14 Thread Geir Magnusson Jr

could it throw an Error rather than while(true)?  Much easier to debug... :)

Weldon Washburn wrote:

On 2/14/06, Tim Ellison [EMAIL PROTECTED] wrote:

Weldon Washburn wrote:

Question -- does it make sense to include a stupid, simple
String.intern() in the kernel class to make it even easier and more
convenient for someone trying to graft Harmony Class Libraries to a
new JVM?

Sure, we can add it to the KERNEL module stubs so people can choose to
reuse it or replace it as they see fit.  Care to contribute yours?

OK. But I warn you its really stupid, really simple and... its never
even been compiled.  Below is the code:

private String [] internArray = new String[256];
public String intern()
{
System.out.println(String.intern() is not fully implemented);

for (int ii = 0; ii  internArray.length; ii++)
{
if (this.equals(internArray[ii]))
return internArray[ii];
if (internArray[ii] == null)
{
internArray[ii] = this;
return this;
}
}
while (true)
System.out.println(String.intern() --- error, overflowed
intern storage);
}

--
Weldon Washburn
Intel Middleware Products Division




Re: [classlib] bouncy castle

2006-02-14 Thread Mikhail Loenko
On 2/13/06, Geir Magnusson Jr [EMAIL PROTECTED] wrote:
  . . .
  4.2) develop sources required to verify signature in the main BC JAR and
  redistribute BC.JAR as is

 Hm.  That's interesting.  What does this really mean?


we need to implement SHA-1 message digest and SHA1withDSA signature.

see 
http://mail-archives.apache.org/mod_mbox/incubator-harmony-dev/200602.mbox/[EMAIL
 PROTECTED]

It is not trivial, so might be good for mid-term solution.

  4.3) #2 but take only necessary classes

 Yes, it was always intended to just take the minimum amount necessary.

Sounds very reasonable.

Thanks,
Mikhail.



 
  If #3 is not legally pure, then I'd prefer #2
 
  Thanks,
  Mikhail
 
  On 2/13/06, Geir Magnusson Jr [EMAIL PROTECTED] wrote:
  Ok, the thread re BC has gotten a bit confusing.
 
  I thought the reason we needed to consider using a copy of the code is
  because we need to create our own signed JAR.  If this is incorrect,
  please say something.
 
  I think there are a few ways to do this (and please, suggest others...) :
 
  1) Rewrite the whole thing (certainly not ideal - noting here for
  completeness)
 
  2) Get a copy of the BC source and put in our repository
 
  3) manufacture our own signed JAR from their source JAR.
 
  4) Other?
 
 
  I'm uncomfortable w/ #3 because we're not really simply re-distributing
  someone else's code (because we re-package) nor are we publishing
  something with the standard ASF oversight.  I'd like to avoid #1.  Can
  we do #2 and then keep refreshing whenever they do an update, with us
  contributing to them if we find bugs?
 
  Ideas?
 
  geir
 
 
 
 
 



[jira] Created: (HARMONY-93) some methods in java.util.Collections don't throw NPE when the parameter is null

2006-02-14 Thread Svetlana Samoilenko (JIRA)
some methods in java.util.Collections don't throw  NPE when the parameter is 
null
-

 Key: HARMONY-93
 URL: http://issues.apache.org/jira/browse/HARMONY-93
 Project: Harmony
Type: Bug
  Components: Classlib  
Reporter: Svetlana Samoilenko


According to j2se 1.4.2 and 1.5 specification for the Collections class  The 
methods of this class all throw a NullPointerException if the collections 
provided to them are null.
Harmony does not throw NPE for some methods. 

Code to reproduce: 
import java.util.*; 

public class test2 { 
public static void main(String [] args) { 
   SortedMap m = null;
   Map map=null;
   Set set=null;   
   SortedSet sortedset=null;
   SortedMap sortedmap =null;
   Collection col=null;
   try {
   Collections.synchronizedCollection(col);
   System.out.println(synchronizedCollection(null) must throw 
NPE);
   } catch (NullPointerException e) {
   System.out.println(PASSED);
   }
   try {
   Collections.synchronizedSortedMap(sortedmap);
   System.out.println(synchronizedSortedMap(null) must throw NPE);
   } catch (NullPointerException e) {
   System.out.println(PASSED);
   }
   try {
   Collections.synchronizedMap(map); 
   System.out.println(synchronizedMap(map) must throw NPE);
   } catch (NullPointerException e) {
   System.out.println(PASSED);
   }
   try {
   Collections.synchronizedSet(set); 
   System.out.println(synchronizedSet(set) must throw NPE);
   } catch (NullPointerException e) {
   System.out.println(PASSED);
   }

   try {
Collections.synchronizedSortedSet(sortedset);
System.out.println(synchronizedSortedSet(null) must throw 
NPE);
   } catch (NullPointerException e) {
   System.out.println(PASSED);
   }
   try {
Collections.unmodifiableCollection(col);
System.out.println(unmodifiableCollection(null) must throw 
NPE);
   } catch (NullPointerException e) {
   System.out.println(PASSED);
   }
   try {
   Collections.unmodifiableMap(map);
   System.out.println(unmodifiableMap(null) must throw NPE);
   } catch (NullPointerException e) {
   System.out.println(PASSED);
   }
   try {
   Collections.unmodifiableSet(set);
   System.out.println(unmodifiableSet(null) must throw NPE);
   } catch (NullPointerException e) {
   System.out.println(PASSED);
   }
   try {
Collections.unmodifiableSortedMap(sortedmap);
System.out.println(unmodifiableSortedMap(null) must throw 
NPE);
   } catch (NullPointerException e) {
   System.out.println(PASSED);
   }
   try {
Collections.unmodifiableSortedSet(sortedset);
System.out.println(unmodifiableSortedSet(null) must throw 
NPE);   
   } catch (NullPointerException e) {
   System.out.println(PASSED);
   } 
} 
 } 

Steps to Reproduce: 
1. Build Harmony (check-out on 2006-01-30) j2se subset as described in 
README.txt. 
2. Compile test2.java using BEA 1.4 javac 
 javac -d . test2.java 
3. Run java using compatible VM (J9) 
 java -showversion test2

Output: 
C:\tmpC:\jrockit-j2sdk1.4.2_04\bin\java.exe -showversion test2 
java version 1.4.2_04 
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) 
BEA WebLogic JRockit(TM) 1.4.2_04 JVM (build ari-31788-20040616-1132-win-ia32, 
Native Threads, GC strategy: parallel) 
PASSED
PASSED
PASSED
PASSED
PASSED
PASSED
PASSED
PASSED
PASSED
PASSED

C:\tmpC:\harmony\trunk\deploy\jre\bin\java -showversion test2 
(c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as 
applicable. 
synchronizedCollection(null) must throw NPE
synchronizedSortedMap(null) must throw NPE
synchronizedMap(map) must throw NPE
synchronizedSet(set) must throw NPE
synchronizedSortedSet(null) must throw NPE
unmodifiableCollection(null) must throw NPE
unmodifiableMap(null) must throw NPE
unmodifiableSet(null) must throw NPE
unmodifiableSortedMap(null) must throw NPE
unmodifiableSortedSet(null) must throw NPE

Suggected fix and test in attachment. 


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



Re: [classlib:security2] bootclasspath for security tests [HARMONY-58]

2006-02-14 Thread Mikhail Loenko
Geir

As you can see [1] there is a consensus that x-security (or auth or x-auth -
as you want) should be separated from general security.

So I think the following packages could be moved to a separate module:

javax.security.* w/o javax.security.cert
org.ietf

Thanks,
Mikhail

[1]. 
http://mail-archives.apache.org/mod_mbox/incubator-harmony-dev/200602.mbox/[EMAIL
 PROTECTED]

On 2/13/06, Geir Magnusson Jr [EMAIL PROTECTED] wrote:
 When you quote someone, please indicate at least who it is.

 Stepan Mishura wrote:
  I think the similar can be done for 'security-x'. As there are no
  objections
  for creating the new component I can create a JIRA task for extracting
  'security-x' from 'security2'. And provide a patch for it by analogy with
  extracting 'x-net'.
 
  What do you think?
  I guess I'm interested in why.  I can see crypto being shaken out, but
  why x-security?
 
 
  Well, you meant security-x?
  I thought that we agreed on new module name, at least with you :-)
  ( see
  http://mail-archives.apache.org/mod_mbox/incubator-harmony-dev/200601.mbox/[EMAIL
   PROTECTED]
  )
 
  The discussion about modules reorganization was resumed, and I think we
  should postpone the module extraction for a while until everybody agrees on
  the proposal.
 
  Thanks,
  Stepan
 
 
  On 2/10/06, Geir Magnusson Jr [EMAIL PROTECTED] wrote:
 
 
  Stepan Mishura wrote:
  On 2/9/06, Geir Magnusson Jr [EMAIL PROTECTED] wrote:
 
  Stepan Mishura wrote:
  Hi Geir,
 
  For the record, I put the jvmarg line back - I did some test class
  renaming, and things broke!  I put it back, and all is well.  Dunno.
  Leaving there so it doesn't break anyone else.  Will continue to
  chase
  down after dinner
 
  crypto.jar and x_net.jar are not created by the 'main build file' (i.e
  .
  make/build.xml) and they are absent in Harmony boot
  (deploy/jre/lib/boot)
  directory. So the build script from 'security2' builds them and places
  explicitly to the bootclasspath.
  Then this is wrong then, correct?  We should put putting crypto.jar and
  x_net.jar into the bootclasspath?
  As I understood you removed only jvmarg line but didn't update ant
  script to
  copy generated jar files. So tests failed. Right?
  Yes, because we were inconsistent about what we are doing.  Not all jars
  made it to jre/lib/boot
 
  So I've now cut x-net out into a separate module, and will stuff crypto
  into security for now to keep the 1 artifact per module scheme.
 
  I'm sure we'll cut them apart again at some point in the future.
 
  The question was how to put required jars in jre/lib/boot directory. A
  fast
  solution was to copy jars generated with local make file in
  security2/make.
  And a right solution is to adjust 'security2' to common build structure
  (i.e.
  make/build.xml) as you did for 'x-net' component. I reviewed your update
  for
  x-net and I'm ok with it.
  Great.  I think that the build will evolve to having to drive the
  general build from the top because of the circular dependencies, and
  then testing being localized to the modules.  I've started on this -
  will have one build-test.xml at the top that calls the individual module
  tests scripts.  Just playing w/ it now - expect more later today.
 
  I think the similar can be done for 'security-x'. As there are no
  objections
  for creating the new component I can create a JIRA task for extracting
  'security-x' from 'security2'. And provide a patch for it by analogy
  with
  extracting 'x-net'.
 
  What do you think?
  I guess I'm interested in why.  I can see crypto being shaken out, but
  why x-security?
 
  geir
 
  Thanks,
  Stepan Mishura
  Intel Middleware Products Division
 
  If you remove jvmarg line then you need to update additionally
  make/build.xml or the build script from 'security2' to put these jars
  to
  Harmony boot directory.
  Yes - I think that is the sensical way to go as we do want them there,
  right?
 
  I think that we should work out some kind of 'transition procedure'
  for
  substituting security with security2 to be sure that we don't miss
  anything
  and we are consistent. The first step may be extracting x-net
  component
  because it is quite independent.
  Don't mix the issues.  Right now, no modules/security code is being
  built.
  So - first - any problem with crypto and x_net into bootclasspath?
 
  geir
 
  Thanks,
  Stepan Mishura
  Intel Middleware Products Division
 
 
 
  On 2/9/06, Geir Magnusson Jr [EMAIL PROTECTED] wrote:
  For the record, I put the jvmarg line back - I did some test class
  renaming, and things broke!  I put it back, and all is well.  Dunno.
  Leaving there so it doesn't break anyone else.  Will continue to
  chase
  down after dinner
 
 
  Geir Magnusson Jr wrote:
  I applied patch for HARMONY-58 (thanks Stepan and Tim) and closed
  the
  issue.
 
  However, there was a small thing that bugged me.  We were setting
  the
  bootclasspath as follows :
 
  jvmarg
  

[jira] Updated: (HARMONY-93) some methods in java.util.Collections don't throw NPE when the parameter is null

2006-02-14 Thread Svetlana Samoilenko (JIRA)
 [ http://issues.apache.org/jira/browse/HARMONY-93?page=all ]

Svetlana Samoilenko updated HARMONY-93:
---

Attachment: CollectionsTest.java

 some methods in java.util.Collections don't throw  NPE when the parameter is 
 null
 -

  Key: HARMONY-93
  URL: http://issues.apache.org/jira/browse/HARMONY-93
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Svetlana Samoilenko
  Attachments: CollectionsTest.java

 According to j2se 1.4.2 and 1.5 specification for the Collections class  The 
 methods of this class all throw a NullPointerException if the collections 
 provided to them are null.
 Harmony does not throw NPE for some methods. 
 Code to reproduce: 
 import java.util.*; 
 public class test2 { 
 public static void main(String [] args) { 
SortedMap m = null;
Map map=null;
Set set=null;   
SortedSet sortedset=null;
SortedMap sortedmap =null;
Collection col=null;
try {
Collections.synchronizedCollection(col);
System.out.println(synchronizedCollection(null) must throw 
 NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
Collections.synchronizedSortedMap(sortedmap);
System.out.println(synchronizedSortedMap(null) must throw 
 NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
Collections.synchronizedMap(map); 
System.out.println(synchronizedMap(map) must throw NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
Collections.synchronizedSet(set); 
System.out.println(synchronizedSet(set) must throw NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
 Collections.synchronizedSortedSet(sortedset);
 System.out.println(synchronizedSortedSet(null) must throw 
 NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
 Collections.unmodifiableCollection(col);
 System.out.println(unmodifiableCollection(null) must throw 
 NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
Collections.unmodifiableMap(map);
System.out.println(unmodifiableMap(null) must throw NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
Collections.unmodifiableSet(set);
System.out.println(unmodifiableSet(null) must throw NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
 Collections.unmodifiableSortedMap(sortedmap);
 System.out.println(unmodifiableSortedMap(null) must throw 
 NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
 Collections.unmodifiableSortedSet(sortedset);
 System.out.println(unmodifiableSortedSet(null) must throw 
 NPE);   
} catch (NullPointerException e) {
System.out.println(PASSED);
} 
 } 
  } 
 Steps to Reproduce: 
 1. Build Harmony (check-out on 2006-01-30) j2se subset as described in 
 README.txt. 
 2. Compile test2.java using BEA 1.4 javac 
  javac -d . test2.java 
 3. Run java using compatible VM (J9) 
  java -showversion test2
 Output: 
 C:\tmpC:\jrockit-j2sdk1.4.2_04\bin\java.exe -showversion test2 
 java version 1.4.2_04 
 Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) 
 BEA WebLogic JRockit(TM) 1.4.2_04 JVM (build 
 ari-31788-20040616-1132-win-ia32, Native Threads, GC strategy: parallel) 
 PASSED
 PASSED
 PASSED
 PASSED
 PASSED
 PASSED
 PASSED
 PASSED
 PASSED
 PASSED
 C:\tmpC:\harmony\trunk\deploy\jre\bin\java -showversion test2 
 (c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as 
 applicable. 
 synchronizedCollection(null) must throw NPE
 synchronizedSortedMap(null) must throw NPE
 synchronizedMap(map) must throw NPE
 synchronizedSet(set) must throw NPE
 synchronizedSortedSet(null) must throw NPE
 unmodifiableCollection(null) must throw NPE
 unmodifiableMap(null) must throw NPE
 unmodifiableSet(null) must throw NPE
 unmodifiableSortedMap(null) must throw NPE
 unmodifiableSortedSet(null) must throw NPE
 Suggected fix and test in attachment. 

-- 
This message is 

[jira] Updated: (HARMONY-93) some methods in java.util.Collections don't throw NPE when the parameter is null

2006-02-14 Thread Svetlana Samoilenko (JIRA)
 [ http://issues.apache.org/jira/browse/HARMONY-93?page=all ]

Svetlana Samoilenko updated HARMONY-93:
---

Attachment: fix.txt

 some methods in java.util.Collections don't throw  NPE when the parameter is 
 null
 -

  Key: HARMONY-93
  URL: http://issues.apache.org/jira/browse/HARMONY-93
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Svetlana Samoilenko
  Attachments: CollectionsTest.java, fix.txt

 According to j2se 1.4.2 and 1.5 specification for the Collections class  The 
 methods of this class all throw a NullPointerException if the collections 
 provided to them are null.
 Harmony does not throw NPE for some methods. 
 Code to reproduce: 
 import java.util.*; 
 public class test2 { 
 public static void main(String [] args) { 
SortedMap m = null;
Map map=null;
Set set=null;   
SortedSet sortedset=null;
SortedMap sortedmap =null;
Collection col=null;
try {
Collections.synchronizedCollection(col);
System.out.println(synchronizedCollection(null) must throw 
 NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
Collections.synchronizedSortedMap(sortedmap);
System.out.println(synchronizedSortedMap(null) must throw 
 NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
Collections.synchronizedMap(map); 
System.out.println(synchronizedMap(map) must throw NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
Collections.synchronizedSet(set); 
System.out.println(synchronizedSet(set) must throw NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
 Collections.synchronizedSortedSet(sortedset);
 System.out.println(synchronizedSortedSet(null) must throw 
 NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
 Collections.unmodifiableCollection(col);
 System.out.println(unmodifiableCollection(null) must throw 
 NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
Collections.unmodifiableMap(map);
System.out.println(unmodifiableMap(null) must throw NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
Collections.unmodifiableSet(set);
System.out.println(unmodifiableSet(null) must throw NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
 Collections.unmodifiableSortedMap(sortedmap);
 System.out.println(unmodifiableSortedMap(null) must throw 
 NPE);
} catch (NullPointerException e) {
System.out.println(PASSED);
}
try {
 Collections.unmodifiableSortedSet(sortedset);
 System.out.println(unmodifiableSortedSet(null) must throw 
 NPE);   
} catch (NullPointerException e) {
System.out.println(PASSED);
} 
 } 
  } 
 Steps to Reproduce: 
 1. Build Harmony (check-out on 2006-01-30) j2se subset as described in 
 README.txt. 
 2. Compile test2.java using BEA 1.4 javac 
  javac -d . test2.java 
 3. Run java using compatible VM (J9) 
  java -showversion test2
 Output: 
 C:\tmpC:\jrockit-j2sdk1.4.2_04\bin\java.exe -showversion test2 
 java version 1.4.2_04 
 Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) 
 BEA WebLogic JRockit(TM) 1.4.2_04 JVM (build 
 ari-31788-20040616-1132-win-ia32, Native Threads, GC strategy: parallel) 
 PASSED
 PASSED
 PASSED
 PASSED
 PASSED
 PASSED
 PASSED
 PASSED
 PASSED
 PASSED
 C:\tmpC:\harmony\trunk\deploy\jre\bin\java -showversion test2 
 (c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as 
 applicable. 
 synchronizedCollection(null) must throw NPE
 synchronizedSortedMap(null) must throw NPE
 synchronizedMap(map) must throw NPE
 synchronizedSet(set) must throw NPE
 synchronizedSortedSet(null) must throw NPE
 unmodifiableCollection(null) must throw NPE
 unmodifiableMap(null) must throw NPE
 unmodifiableSet(null) must throw NPE
 unmodifiableSortedMap(null) must throw NPE
 unmodifiableSortedSet(null) must throw NPE
 Suggected fix and test in attachment. 

-- 
This message is 

[jira] Commented: (HARMONY-86) java.util.zip.Inflater.needsDictionary() throws unspecified IllegalStateException

2006-02-14 Thread Svetlana Samoilenko (JIRA)
[ 
http://issues.apache.org/jira/browse/HARMONY-86?page=comments#action_12366443 ] 

Svetlana Samoilenko commented on HARMONY-86:


Tim, thank you, bug is not reproducible with latest sources.

 java.util.zip.Inflater.needsDictionary() throws unspecified 
 IllegalStateException
 -

  Key: HARMONY-86
  URL: http://issues.apache.org/jira/browse/HARMONY-86
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Svetlana Samoilenko
 Assignee: Tim Ellison


 According to the j2se 1.4 and 1.5 specification 
 java.util.zip.needsDictionary() method must not throw any exception.
 Harmony throws unspecified IllegalStateException that contradicts 
 specification.
 Code to reproduce: 
 import java.util.zip.*; 
 public class test2 { 
 public static void main(String args[]) { 
 Inflater inf = new Inflater(); 
 System.out.println(Inflater.needsDictionary() = 
 +inf.needsDictionary()); 
 } 
 }
 Steps to Reproduce: 
 1. Build Harmony (check-out on 2006-01-30) j2se subset as described in 
 README.txt. 
 2. Compile test2.java using BEA 1.4 javac 
  javac -d . test2.java 
 3. Run java using compatible VM (J9) 
  java -showversion test2
 Output: 
 C:\tmpC:\jrockit-j2sdk1.4.2_04\bin\java.exe -showversion test2 
 java version 1.4.2_04 
 Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) 
 BEA WebLogic JRockit(TM) 1.4.2_04 JVM (build 
 ari-31788-20040616-1132-win-ia32, Native Threads, GC strategy: parallel) 
 Inflater.needsDictionary() = true
 C:\tmpC:\harmony\trunk\deploy\jre\bin\java -showversion test2 
 (c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as 
 applicable. 
 java.lang.IllegalStateException
 at java.util.zip.Inflater.needsDictionary(Inflater.java:212)
 at test2.main(test2.java:8)
 Siggested fix: to remove the lines in needsDictionary() method in 
 archive/src/main/java/java/util/zip/Inflater.java :   
  211  if (inputBuffer == null)
  212throw new IllegalStateException();
  Suggested junit test case:
  InflaterTest.java 
 - 
 import java.util.zip.*;
 import junit.framework.*; 
 public class InflaterTest extends TestCase { 
 public static void main(String[] args) { 
 junit.textui.TestRunner.run(InflaterTest .class); 
 } 
 public void test_needsDictionary () { 
Inflater inf = new Inflater(); 
assertFalse(inf.needsDictionary());
} 
 }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



[jira] Commented: (HARMONY-85) java.util.jar.Attributes.Name(String name) does not throw IllegalArgumentException if name.length 70

2006-02-14 Thread Svetlana Samoilenko (JIRA)
[ 
http://issues.apache.org/jira/browse/HARMONY-85?page=comments#action_12366444 ] 

Svetlana Samoilenko commented on HARMONY-85:


Tim, thank you, bug is not reproducible with latest sources.

 java.util.jar.Attributes.Name(String name) does not throw 
 IllegalArgumentException if name.length  70
 --

  Key: HARMONY-85
  URL: http://issues.apache.org/jira/browse/HARMONY-85
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Svetlana Samoilenko
 Assignee: Tim Ellison


 According to j2se 1.4.2 and 1.5 specification for Attributes.Name(String 
 name) a string length cannot exceed 70 characters.
 Harmony does not throw IllegalArgumentException if name.length  70. 
 Code to reproduce: import java.util.jar.*;
 public class test2 { 
 public static void main(String args[]) throws Exception { 
 try { 
 //no more than 70 chars in attribute name allowed 
 new Attributes.Name( 
 01234567890123456789012345678901234567890123456789012345678901234567890); 
 System.out.println(Failed. Should be IllegalArgumentException 
 ); 
 } catch(IllegalArgumentException e) { 
 System.out.println(Expected IllegalArgumentException); 
 } 
 } 
 }
 Steps to Reproduce: 
 1. Build Harmony (check-out on 2006-01-30) j2se subset as described in 
 README.txt. 
 2. Compile test2.java using BEA 1.4 javac 
  javac -d . test2.java 
 3. Run java using compatible VM (J9) 
  java -showversion test2
 Output: 
 C:\tmpC:\jrockit-j2sdk1.4.2_04\bin\java.exe -showversion test2 
 java version 1.4.2_04 
 Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) 
 BEA WebLogic JRockit(TM) 1.4.2_04 JVM (build 
 ari-31788-20040616-1132-win-ia32, Native Threads, GC strategy: parallel) 
 Expected IllegalArgumentException
  C:\tmpC:\harmony\trunk\deploy\jre\bin\java -showversion test2 
 (c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as 
 applicable.
 Failed. Should be IllegalArgumentException
 Siggested fix: 
 @@ -84,7 +84,7 @@
 public Name(String s) {
   int i = s.length();
 - if (i == 0)
 + if (i == 0 || i 70)
 throw new IllegalArgumentException();
   for (; --i = 0;) {
 char ch = s.charAt(i);
 Suggested junit test case:
  AttributesTest.java 
 - 
 import java.util.jar.*;
 import junit.framework.*; 
 public class AttributesTest extends TestCase { 
 public static void main(String[] args) { 
 junit.textui.TestRunner.run(AttributesTest.class); 
 } 
 public void test_constructor () { 
 try {
 new Attributes.Name( 
 01234567890123456789012345678901234567890123456789012345678901234567890); 
 fail(Should be IllegalArgumentException); 
 } catch(IllegalArgumentException e) { 
 //expected
 }
 } 
 }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



Re: [classlib] build / test system

2006-02-14 Thread Stepan Mishura
I need sync. with repository once a day, for example, in the morning to get
yours and Tim's last updates :-) . And during a working day I may do dozen
workspace builds. So each build will verify whether used jar files (I think
we will have a number of them) are up to date or not. Right? Is this
necessary?

Also there is possibility that the next version of some jar will break the
build, for example, a bug may be introduced in a new jar's version and
Harmony tests will start to fail. Because a jar'a update is done secretly
(I don't like this) by the build script nobody will notice that. So one day
some of us will have to solve a mystery puzzle: why the last minor update
breaks everything :-)

If everybody OK with network build let's have it, but please add a special
property, like George suggested:
-DIdontHappyWithNetworkBuildUseLocalCopies

Thanks,
Stepan


On 2/14/06, Geir Magnusson Jr geir atpobox.com wrote:



 Stepan Mishura wrote:
  And to detect whether it is stale or not you need network. Right?

 If you have a network, then you get it.  If you don't have a network,
 then it doesn't matter if it's stale or not, because there is nothing
 you can do about it anyway.

 The assumption is that you keep the whole tree up to date - therefore,
 while a given dependency may be stale, it's no more stale than your
 tree, so you can still work until you get back online.

 If you update code, and don't update deps into the local repository,
 it's your problem :)

 geir





Re: [classlib] build / test system

2006-02-14 Thread Geir Magnusson Jr



Stepan Mishura wrote:

I need sync. with repository once a day, for example, in the morning to get
yours and Tim's last updates :-) . And during a working day I may do dozen
workspace builds. So each build will verify whether used jar files (I think
we will have a number of them) are up to date or not. Right? Is this
necessary?


Well, generally no, because dependencies won't change that fast.  When 
working with systems like this in the past, I would always run in 
offline mode until something broke - an then I would let it sync.


Overall, this was far more time efficient.



Also there is possibility that the next version of some jar will break the
build, for example, a bug may be introduced in a new jar's version and
Harmony tests will start to fail. Because a jar'a update is done secretly
(I don't like this) by the build script nobody will notice that. So one day
some of us will have to solve a mystery puzzle: why the last minor update
breaks everything :-)


it isn't done secretly - we specify the exact version of whatever jar 
we're getting.  So nothing changes w/o our explicit change.




If everybody OK with network build let's have it, but please add a special
property, like George suggested:
-DIdontHappyWithNetworkBuildUseLocalCopies

Thanks,
Stepan


On 2/14/06, Geir Magnusson Jr geir atpobox.com wrote:



Stepan Mishura wrote:

And to detect whether it is stale or not you need network. Right?

If you have a network, then you get it.  If you don't have a network,
then it doesn't matter if it's stale or not, because there is nothing
you can do about it anyway.

The assumption is that you keep the whole tree up to date - therefore,
while a given dependency may be stale, it's no more stale than your
tree, so you can still work until you get back online.

If you update code, and don't update deps into the local repository,
it's your problem :)

geir







[jira] Updated: (HARMONY-92) Suggestion: Move com.ibm.platform from NIO to LUNI

2006-02-14 Thread Richard Liang (JIRA)
 [ http://issues.apache.org/jira/browse/HARMONY-92?page=all ]

Richard Liang updated HARMONY-92:
-

Attachment: refactor_platform.zip

Hello,
Here is the patch for this issue.

1. For java source, it's more convenient to use Eclipse's refact-move, rename 
(You can also copy files from the attachment)
2. For native source, please copy files from the attachment, then apply the 
patch file. 
(Though there are only some copy, paste, delete, and rename operations, we have 
done it for you.)

Thanks a lot.

 Suggestion: Move com.ibm.platform from NIO to LUNI
 --

  Key: HARMONY-92
  URL: http://issues.apache.org/jira/browse/HARMONY-92
  Project: Harmony
 Type: Improvement
   Components: Classlib
 Reporter: Richard Liang
  Attachments: refactor_platform.zip

 Hello Tim,
 As we discussed in JIRA 27 and JIRA 42, I suggest we move the packages 
 com.ibm.platform and com.ibm.platform.struct from NIO to LUNI component. As 
 these packages are used by java.net, as well as java.nio.channels. I will 
 post the proposed fix soon :-)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



[jira] Commented: (HARMONY-67) java.nio.charset.Charset.decode(ByteBuffer) throws unexpected BufferOverflowException for UTF-16BE, UTF-16LE, UTF-16 charsets.

2006-02-14 Thread Svetlana Samoilenko (JIRA)
[ 
http://issues.apache.org/jira/browse/HARMONY-67?page=comments#action_12366450 ] 

Svetlana Samoilenko commented on HARMONY-67:


Tim, I confirm that there is no exeption any more, but the result  of decode 
method  is wrong.
Harnony returns charbuf.length())==1 while BEA returns charbuf.length())==0.
If to set UTF-8 charset, the result is equal.


 java.nio.charset.Charset.decode(ByteBuffer) throws unexpected 
 BufferOverflowException  for UTF-16BE, UTF-16LE, UTF-16 charsets.
 ---

  Key: HARMONY-67
  URL: http://issues.apache.org/jira/browse/HARMONY-67
  Project: Harmony
 Type: Bug
   Components: Classlib
 Reporter: Svetlana Samoilenko
 Assignee: Tim Ellison


 According to j2se 1.4.2 specification for Charset.decode(ByteBuffer  b) the 
 method must not throw any exceptions.
 The test listed below shows that there is unexpected BufferOverflowException 
 thrown if charset name is one in the following:  UTF-16BE, UTF-16LE, UTF-16.
 BEA does not throw any exceptions.
 Code to reproduce: 
 import java.nio.charset.Charset; 
 import java.nio.ByteBuffer; 
 import java.nio.CharBuffer; 
 public class test2 {   
 public static void main(String[] args) throws Exception { 
 byte[] b = new byte[] {(byte)1}; 
 ByteBuffer buf= ByteBuffer.wrap(b); 
 CharBuffer charbuf=Charset.forName(UTF-16).decode(buf); 
 System.out.println(CharBuffer.length()=+ charbuf.length());
 } 
 }
 Steps to Reproduce: 
 1. Build Harmony (check-out on 2006-01-30) j2se subset as described in 
 README.txt. 
 2. Compile test2.java using BEA 1.4 javac 
  javac -d . test2.java 
 3. Run java using compatible VM (J9) 
  java -showversion test2 
 Output: 
 C:\tmpC:\jrockit-j2sdk1.4.2_04\bin\java.exe -showversion test2 
 java version 1.4.2_04 
 Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) 
 BEA WebLogic JRockit(TM) 1.4.2_04 JVM (build 
 ari-31788-20040616-1132-win-ia32, Native Threads, GC strategy: parallel) 
 CharBuffer.length()=0
 C:\tmpC:\harmony\trunk\deploy\jre\bin\java -showversion test2 
 (c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as 
 applicable. 
  java.nio.BufferOverflowException
 at java.nio.CharBuffer.put(CharBuffer.java:662) 
 at java.nio.CharBuffer.put(CharBuffer.java:629) 
 at java.nio.charset.CharsetDecoder.decode(CharsetDecoder.java:406) 
 at java.nio.charset.CharsetDecoder.decode(CharsetDecoder.java:243) 
 at java.nio.charset.Charset.decode(Charset.java:630) 
 at test2.main(test2.java:8)
 Suggested junit test case:
  CharsetTest.java 
 - 
 import java.nio.charset.Charset; 
 import java.nio.ByteBuffer; 
 import java.nio.CharBuffer; 
 import junit.framework.*; 
 public class CharsetTest extends TestCase { 
 public static void main(String[] args) { 
 junit.textui.TestRunner.run(CharsetTest.class); 
 } 
 public void test_decode() { 
 byte[] b = new byte[] {(byte)1}; 
 ByteBuffer buf= ByteBuffer.wrap(b); 
 CharBuffer charbuf=Charset.forName(UTF-16).decode(buf); 
 assertEquals(Assert 0: charset UTF-16,0,charbuf.length());
 
 charbuf=Charset.forName(UTF-16BE).decode(buf); 
 assertEquals(Assert 1: charset UTF-16BE,0, charbuf.length());   
  
 
 charbuf=Charset.forName(UTF-16LE).decode(buf); 
 assertEquals(Assert 2: charset UTF16LE,0, charbuf.length());
 
} 
 }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira



[jira] Created: (HARMONY-94) java.util.Collections.binarySearch(List, Object, Comparator c) throws NPE when c is null

2006-02-14 Thread Svetlana Samoilenko (JIRA)
java.util.Collections.binarySearch(List, Object, Comparator c) throws NPE when 
c is null


 Key: HARMONY-94
 URL: http://issues.apache.org/jira/browse/HARMONY-94
 Project: Harmony
Type: Bug
  Components: Classlib  
Reporter: Svetlana Samoilenko


According to j2se 1.4.2 and 1.5 specification for 
java.util.Collections.binarySearch(List, Object, Comparator c) method null 
value of Comparator c indicates, that the elements' natural ordering should be 
used.
Harmony throws NPE in this case that contradicts specification.

Code to reproduce: 
import java.util.*; 
public class test2 {  
public static void main(String args[]){ 
LinkedList lst = new LinkedList(); 
lst.add(new Integer(30)); 
Collections.sort(lst, null); 
int i = Collections.binarySearch(lst, new Integer(2), null); 
System.out.println(Index of search key = + i); 
} 
}
Steps to Reproduce: 
1. Build Harmony (check-out on 2006-01-30) j2se subset as described in 
README.txt. 
2. Compile test2.java using BEA 1.4 javac 
 javac -d . test2.java 
3. Run java using compatible VM (J9) 
 java -showversion test2

Output: 
C:\tmpC:\jrockit-j2sdk1.4.2_04\bin\java.exe -showversion test2 
java version 1.4.2_04 
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05) 
BEA WebLogic JRockit(TM) 1.4.2_04 JVM (build ari-31788-20040616-1132-win-ia32, 
Native Threads, GC strategy: parallel) 
Index of search key =-1

C:\tmpC:\harmony\trunk\deploy\jre\bin\java -showversion test2 
(c) Copyright 1991, 2005 The Apache Software Foundation or its licensors, as 
applicable. 
java.lang.NullPointerException
at java.util.Collections.binarySearch(Collections.java:1347)
at test2.main(test2.java:8)

 Suggected fix:

Index: trunk/modules/luni/src/main/java/java/util/Collections.java
===
---   trunk/modules/luni/src/main/java/java/util/Collections.java   
(revision 377385)
+++ trunk/modules/luni/src/main/java/java/util/Collections.java  (working 
copy)
@@ -1340,6 +1340,9 @@
 */
public static int binarySearch(List list, Object object,
Comparator comparator) {
+if ( comparator== null) {
+return Collections.binarySearch(list, object);
+}
if (!(list instanceof RandomAccess)) {
ListIterator it = list.listIterator();
while (it.hasNext()) {  
  

 Suggested junit test case:
 CollectionsTest.java 
- 
import junit.framework.*; 
import java.util.*; 

public class CollectionsTest extends TestCase { 
public static void main(String[] args) { 
junit.textui.TestRunner.run(CollectionsTest.class); 
} 
public void test_binarySearch () { 
LinkedList lst = new LinkedList(); 
lst.add(new Integer(30)); 
Collections.sort(lst, null); 
assertEquals(-1, Collections.binarySearch(lst, new Integer(2), null));
} 

}



-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira