public inbox for java@gcc.gnu.org
 help / color / mirror / Atom feed
From: Andrew John Hughes <ahughes@redhat.com>
To: Keith <keith@rhsdplanning.com>
Cc: java@gcc.gnu.org
Subject: Re: 'java.lang.String' has no method
Date: Fri, 26 Mar 2010 16:55:00 -0000	[thread overview]
Message-ID: <17c6771e1003260954q21babf04v1f4f22139c692d94@mail.gmail.com> (raw)
In-Reply-To: <4BACE60D.9080103@rhsdplanning.com>

On 26 March 2010 16:51, Keith <keith@rhsdplanning.com> wrote:
> Thanks. That was it.I was using libgcj-4.3.0.jar rather than
> libgcj-4.4.0.jar
>
> Does libgcj-4.4.0.jar support Java 1.6? If so there are some 1.6 methods
> missing for java.util.ResourceBundle and java.net.NetworkInterface. If not,
> then never mind.
> Eventually, I will try and suggest some patches for the the missing methods,
> but right now
> I have code to get out so I am doing 1.5 work-a-rounds.
>

It supports bits of it:

http://builder.classpath.org/japi/openjdk6-libgcj.html

And yes, there are known holes in java.net and ResourceBundle.  I've
looked at implementing them a couple of times, but not yet got round
to it.

Knowing which methods should be prioritised for implementation (i.e.
because people actually use them in real-world code) would be very
useful.  And patches even more so!

> Thanks,
>
> Keith
>
>
> Keith wrote:
>>
>> From what I understand based on gcj e-mail and bug archives, I should not
>> be seeing this error in 4.4.0,
>> so what am I doing wrong?
>>
>> Keith
>>
>> When I compile Reports.class (compiled with java 1.6.0_10) using gcj under
>> MinGW
>> $ gcj -v
>> Using built-in specs.
>> Reading specs from c:/mingw/bin/../lib/gcc/mingw32/4.4.0/libgcj.spec
>> rename spec startfile to startfileorig
>> rename spec lib to liborig
>> Target: mingw32
>> Configured with: ../gcc-4.4.0/configure
>> --enable-languages=c,ada,c++,fortran,jav
>> a,objc,obj-c++ --disable-sjlj-exceptions --enable-shared --enable-libgcj
>> --enabl
>> e-libgomp --with-dwarf2 --disable-win32-registry --enable-libstdcxx-debug
>> --enab
>> le-version-specific-runtime-libs --prefix=/mingw
>> --with-gmp=/mingw/src/gmp/root
>> --with-mpfr=/mingw/src/mpfr/root --build=mingw32
>> Thread model: win32
>> gcc version 4.4.0 (GCC)
>>
>> with the command:
>> gcj
>> --classpath="/Croot/jprojects/pps/dist/lib/pps.jar:/Croot/jprojects/pps/dist/lib/pentium.jar:/Croot/jprojects/pps/dist/lib/org.eclipse.ui.workbench_3.5.0.I20090603-2000.jar:/Croot/jprojects/pps/dist/lib/org.eclipse.swt.win32.win32.x86_3.5.0.v3550b.jar:/Croot/jprojects/pps/dist/lib/org.eclipse.osgi_3.5.0.v20090520.jar:/Croot/jprojects/pps/dist/lib/org.eclipse.jface_3.5.0.I20090525-2000.jar:/Croot/jprojects/pps/dist/lib/org.eclipse.equinox.common_3.5.0.v20090520-1800.jar:/Croot/jprojects/pps/dist/lib/org.eclipse.core.runtime_3.5.0.v20090525.jar:/Croot/jprojects/pps/dist/lib/org.eclipse.core.commands_3.5.0.I20090525-2000.jar:/Croot/jprojects/pps/dist/lib/mail.jar:/Croot/jprojects/pps/dist/lib/jRegistryKey.jar:/Croot/jprojects/pps/dist/lib/ArciMathEval.jar:/Croot/jprojects/pps/dist/lib/activation.jar"
>> -Os -c -o obj/com_performanceplanningsystem_site_Reports.o
>> com/performanceplanningsystem/site/Reports.class
>>
>> I get:
>>
>> com/performanceplanningsystem/site/Reports.java:892: error: class
>> 'java.lang.String' has no method named 'format' matching signature
>> '(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;'
>> com/performanceplanningsystem/site/Reports.java: In method
>> 'com.performanceplanningsystem.site.Reports.startPoint(com.performanceplanningsystem.site.SiteElement,com.performanceplanningsystem.site.SiteElement,java.util.ArrayList)':
>> com/performanceplanningsystem/site/Reports.java:1329: error: class
>> 'java.lang.String' has no method named 'format' matching signature
>> '(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;'
>> com/performanceplanningsystem/site/Reports.java: In method
>> 'com.performanceplanningsystem.site.Reports.findShape(com.performanceplanningsystem.ui.PPS,java.util.Map)':
>> com/performanceplanningsystem/site/Reports.java:2129: error: class
>> 'java.lang.String' has no method named 'format' matching signature
>> '(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;'
>> com/performanceplanningsystem/site/Reports.java: In method
>> 'com.performanceplanningsystem.site.Reports.greenReport(com.performanceplanningsystem.ui.PPS,java.util.Map)':
>> com/performanceplanningsystem/site/Reports.java:2519: error: class
>> 'java.lang.String' has no method named 'format' matching signature
>> '(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;'
>>
>> Code:
>> int reportCount = 0;
>> String nameString = "daily";
>> // resource is  {"report.filename.fmt", "report%1$d.txt"},
>> Line 829:
>>       String reportName = String.format(nameString +
>> PPS.getPpsResources().getString("report.filename.fmt"), reportCount);
>> //$NON-NLS-1$
>>
>
>



-- 
Andrew :-)

Free Java Software Engineer
Red Hat, Inc. (http://www.redhat.com)

Support Free Java!
Contribute to GNU Classpath and the OpenJDK
http://www.gnu.org/software/classpath
http://openjdk.java.net

PGP Key: 94EFD9D8 (http://subkeys.pgp.net)
Fingerprint: F8EF F1EA 401E 2E60 15FA  7927 142C 2591 94EF D9D8

  reply	other threads:[~2010-03-26 16:55 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-25 18:08 Keith
2010-03-25 18:26 ` Andrew Haley
2010-03-26 16:51 ` Keith
2010-03-26 16:55   ` Andrew John Hughes [this message]
2010-03-30 18:27     ` link error: undefined reference Keith
2010-03-31  7:46       ` Andrew Haley
2010-04-01 20:08         ` Keith
2010-04-02  8:47           ` Andrew Haley
     [not found]     ` <4BB23C24.3030103@rhsdplanning.com>
2010-03-30 18:31       ` 'java.lang.String' has no method Andrew John Hughes
2010-03-30 18:41     ` Keith

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=17c6771e1003260954q21babf04v1f4f22139c692d94@mail.gmail.com \
    --to=ahughes@redhat.com \
    --cc=java@gcc.gnu.org \
    --cc=keith@rhsdplanning.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).