Closed
Bug 123651
Opened 24 years ago
Closed 20 years ago
Java code produced doesn't work with current Java to XPCOM Bridge
Categories
(Core Graveyard :: Java to XPCOM Bridge, defect)
Tracking
(Not tracked)
RESOLVED
WONTFIX
People
(Reporter: marcus, Assigned: blackconnect)
References
Details
Attachments
(7 files)
|
2.12 KB,
patch
|
Details | Diff | Splinter Review | |
|
2.86 KB,
patch
|
Details | Diff | Splinter Review | |
|
8.06 KB,
patch
|
Details | Diff | Splinter Review | |
|
10.66 KB,
patch
|
Details | Diff | Splinter Review | |
|
11.24 KB,
patch
|
Details | Diff | Splinter Review | |
|
11.61 KB,
patch
|
Details | Diff | Splinter Review | |
|
13.35 KB,
patch
|
Details | Diff | Splinter Review |
Check out xpidl from the mozilla trunk.
Check out the Java to XPCOM bridge.
Build xpidl.
Build the Java to XPCOM bridge using the previously build xpidl version.
Result:
The build fails, because nsID is undefined.
Problem:
nsID has been removed from the Java to XPCOM Bridge last year, and replaced with
ID, CID and IID. There is a version of xpidl on the Blackwood branch, that does
generate the correct code. But this doesn't get build, because it has the same
executable name as the one from the trunk. So the version on the trunk is used,
which besides using nsID, has a few other bugs, which were fixed on the
Blackwood branch (Bug #71951, 74511, 74525, 67457, 74742, 94186, 94192).
Possible solutions:
1. Integrate the Java to XPCOM version into the trunk
2. Use a different executable name for the Java to XPCOM version
Comment 1•24 years ago
|
||
Formally confirming bug for consideration; cc'ing jband -
Status: UNCONFIRMED → NEW
Ever confirmed: true
Comment 2•24 years ago
|
||
A one-time merge to the trunk is not helpful if the code owner is not willing to
maintain it there.
I'd say the realistic options are:
0) ignore the problem
1) remove xpidl_java.c form the trunk build
2) reassign to the owner of the "Java to XPCOM Bridge" component and see if he
wants to do anything about the problem.
| Reporter | ||
Comment 3•24 years ago
|
||
This patch will replace generate of nsID-code in xpidl_java.c with ID, IID or
CID, depending on which ID is required. Compare with
java/xpcom/java/xpidl/xpidl_java.c
| Reporter | ||
Comment 4•24 years ago
|
||
I added a patch for xpcom/typelib/xpidl/xpidl_java.c. This patch replaces the
code that generates nsID with code that generates ID, IID or CID, depending on
the type of ID requested.
Keywords: patch
| Reporter | ||
Comment 5•24 years ago
|
||
I think there should only be one version of xpidl_java.c. Either on the trunk,
or on the Java to XPCOM bridge. In both cases, some bugs were only fixed in one
of both versions, so these bugfixes would have to be integrated into a single
version.
If we put xpidl_java.c in the Java to XPCOM bridge, it should be renamed, to (a)
clearly indicate that is only for java, and (b) allow people to use both in the
same Makefile, one to generate C++, the other to generate java code.
| Reporter | ||
Comment 6•24 years ago
|
||
Updated the patch. It now puts out package and import specifications in the
java_prolog.
| Reporter | ||
Comment 7•24 years ago
|
||
This version of the patch generates a separate java-file for each interface,
escapes methods that clash with java keywords or Object methods with an _, and
converts PRTime to long.
We should get rid of all the %{C++ } declarations in idl-files that are to be
accesible from java. Converting PRTime this way is a hack. The right solution
would be not to use prtime.h, but to declare PRTime using the basic IDL types.
| Reporter | ||
Comment 8•24 years ago
|
||
This patch fixes the following problems:
1. Typedefs from #includes are converted to the underlying native types (Bug
#94192)
2. Identifiers that match java keywords or Object methods are escaped
3. Maps nsID->ID, nsIID->IID, nsCID->CID.
4. Map PRTime->long.
| Reporter | ||
Comment 9•24 years ago
|
||
Method names now start with a lowercase letter
| Reporter | ||
Comment 10•24 years ago
|
||
Fixed a memory leak in xpidl_java.c.
This patch fixes the following:
1. Maps ns[IC]ID to [IC]ID.
2. Adds package the necessary package and import specifications;
3. Generates a separate java file for each interface
4. Converts method-names to start with a lowercase letter
5. Adds an underscore (_) to method- and parameter names that collide with
reserved words.
6. Maps idl typedefs to their native types
7. Maps PRTime->long (that's defined in a %{C++ } section in nsroot.idl)
Could someone please review this patch and tell me what you think about it?
| Reporter | ||
Comment 11•24 years ago
|
||
Fixed Segmentation fault
Comment 12•24 years ago
|
||
Marcus: thank you for all your work on this!!!
As jband mentioned in Comment #2 above, this should be taken
up by the owner of the Java to XPCom Bridge component, so I am
reassigning it there for consideration -
Assignee: dbradley → idk
Component: xpidl → Java to XPCOM Bridge
QA Contact: pschwartau → avm
| Reporter | ||
Comment 13•24 years ago
|
||
Well Igor, what do you think about merging xpidl_java.c back into the trunk?
I am currently working on a fix for Bug #55384, but that would require first
fixing this one.
I intend to have Blackwood working with Mozilla 1.0 the day Mozilla 1.0 is released.
| Reporter | ||
Comment 14•24 years ago
|
||
Igor, could you please review this patch?
| Reporter | ||
Comment 15•24 years ago
|
||
CC'ing ashuk@eng.sun.com and joe.chou@eng.sun.com, as they are working on
blackwood and might be able to review the bug.
Comment 16•23 years ago
|
||
Just posted a significant patch on bug 189098 addressing these issues.
Comment 17•20 years ago
|
||
Blackconnect no longer builds and hasn't been worked on since 2001. -> WONTFIX
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → WONTFIX
Updated•12 years ago
|
Product: Core → Core Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•