Commit Graph

225 Commits

Author SHA1 Message Date
beard%netscape.com
c74304e962 made it compile on XP_MAC, still needs a user interface to choose multiple files. 1999-04-04 01:30:45 +00:00
beard%netscape.com
f0a852fade added interactive choosing of a file to dump on XP_MAC, worked around a crash in XPT_DumpInterfaceDescriptor. 1999-04-04 01:25:44 +00:00
beard%netscape.com
b4181be75d Added a strdup function for XP_MAC. 1999-04-04 01:20:34 +00:00
beard%netscape.com
b69769c250 First Checked In. 1999-04-04 00:13:40 +00:00
beard%netscape.com
32df35f453 added default args for XP_MAC. 1999-04-04 00:13:28 +00:00
beard%netscape.com
3024d12e09 First Checked In. 1999-04-03 23:36:11 +00:00
jband%netscape.com
462a32f671 fixed typo in doc 1999-04-02 19:51:05 +00:00
jband%netscape.com
7efd72beb7 added porting guide and README docs 1999-04-02 06:15:09 +00:00
rogerl%netscape.com
0378d86caf fixed .global label. 1999-04-02 01:07:59 +00:00
rogerl%netscape.com
58d0a91ecc New. (And, as yet, unbuilt & untested) 1999-04-02 00:47:17 +00:00
briano%netscape.com
a0880a3146 Only descend into tests if ENABLE_TESTS is set. 1999-03-31 22:58:07 +00:00
briano%netscape.com
e6c0eba0bb Only descend into the tests directory if ENABLE_TESTS is set. 1999-03-30 03:07:23 +00:00
jband%netscape.com
a2dfafc766 fix incorrect title comment (copied from another file) 1999-03-29 04:35:35 +00:00
jband%netscape.com
2f094e7206 add support for 'shared' flag in typelibs. This is available for use to indicate pointer type 'out' params which will not follow the xpcom rules of transfering ownership - i.e. they want to share a pointer rather than cloning the underlying data for the caller to delete when finished 1999-03-28 21:48:34 +00:00
jband%netscape.com
3bfd1f867e removing export of removed file 1999-03-27 08:36:20 +00:00
mccabe%netscape.com
a4aefc434d Consolidated xpt_cpp.h with xptinfo.h; removed xpt_cpp.h. Also
modified uses...
1999-03-27 08:02:15 +00:00
jband%netscape.com
1fe94e3b3f removing (yet another!) misplaced semi-colon 1999-03-27 06:20:40 +00:00
jband%netscape.com
4d4fa94952 removing misplaced semi-colonsthat break some platforms 1999-03-27 01:53:40 +00:00
mcafee%netscape.com
43d656ab19 Ignore generated files. 1999-03-27 00:08:06 +00:00
briano%netscape.com
8394a60939 Fixed the bug that was assuming Linux==x86 (only). 1999-03-26 23:06:38 +00:00
danm%netscape.com
9d90b52b72 removing glowcode. a:jband 1999-03-26 02:37:22 +00:00
mccabe%netscape.com
4450173143 Move xptinfo, xptcall from export phase (erroneously copied from libxpt Makefile.in) to libs and back out previous temporary fix.
Finishing checkin.  Hopefully all is OK.
1999-03-25 10:35:19 +00:00
mccabe%netscape.com
4d4e61a4dd Move xptinfo, xptcall from export phase (erroneously copied from libxpt Makefile.in) to libs and back out previous tree patch. 1999-03-25 10:28:39 +00:00
jband%netscape.com
e0c20dd684 fix build bustage due to use of nscore.h before it is exported - I don't understand why this stuff is being compiled in the export phase. We can that later. 1999-03-25 09:05:28 +00:00
mccabe%netscape.com
0d46aaa627 Adding libxpt and xpconnect to the build. 1999-03-25 07:50:11 +00:00
warren%netscape.com
9ed31cf894 Added GetMethodInfoForName 1999-03-25 07:30:47 +00:00
jband%netscape.com
1b72836b93 use nspr type 1999-03-25 03:37:40 +00:00
jband%netscape.com
9a923d2130 add implementation files for unsupported platforms to allow clean build on all platforms even though we'll have failure at runtime on unsupported platforms 1999-03-23 22:16:14 +00:00
jband%netscape.com
9adc279405 fix test Makefile.in 1999-03-23 07:19:15 +00:00
jband%netscape.com
de37f0faf5 fix test Makefile.in 1999-03-23 07:16:53 +00:00
jband%netscape.com
95bae7cba5 fix filename 1999-03-23 07:04:52 +00:00
jband%netscape.com
4b66e49f5a initial checking of xptcall code. This module allows arbitrary invocation of xpcom methods and also allows an object to impersonate an object of an arbitrary xpcom class. This code is used for XPConnect and will also be used for a scriptable interface to RDF. The build scheme for libxpt, xptinfo, and xpconnect may be a bit screwy on some platforms until this settles down. Luckily, none of these modules are part of the client build yet and very few people should even notice the change 1999-03-23 02:23:29 +00:00
leaf%mozilla.org
4ad9f70d5d Landing nspr library name change, and plevent function call change. 1999-03-17 21:32:03 +00:00
mccabe%netscape.com
44463b458c Another reworking of the loader -
- added a forward declaration of nsIInterfaceInfoManager to xptinfo.h

- reworked and cleaned up most aspects of the loader; typelib files now get associated typelib records, which have arrays of pointers to shared interface records; no hashtable lookup is necessary to resolve index pointers from params, etc to nsInterfaceInfo objects.

- moved to two hashtables in nsInterfaceInfoManager, mapping from name->interface record and iid->interface record.  Still unclear if I handle the different-iid, same-name case correctly.
1999-03-15 05:50:11 +00:00
jband%netscape.com
a6e22fd8aa more to fix assumption that interfaces don't have the pointer bit set 1999-03-13 09:09:26 +00:00
jband%netscape.com
95c5de89a9 made in params const, added some comments 1999-03-13 01:34:37 +00:00
jband%netscape.com
318cbab4df fix assumption that interfaces don't have the poointer bit set 1999-03-13 01:31:48 +00:00
mccabe%netscape.com
1f415231ec Fixed a place where I was missing an NS_RELEASE, thanks jband. 1999-03-13 00:56:47 +00:00
mccabe%netscape.com
25ebe42e73 Not part of seamonkey.
Removed awkward nsXPTParamInfo::GetInterface and friend, and als removed supporting nsXPTParamInfo.cpp file.  Replace by nsIInterfaceInfo::GetInfoForParam and friend.

Made the constructor for nsInterfaceInfo private, with nsInterfaceInfoManager as a friend class.
1999-03-12 06:49:01 +00:00
jband%netscape.com
41b9e6001a get xptinfo building on Win32 again 1999-03-11 02:21:23 +00:00
coop%netscape.com
c6c0714f4f NOT YET PART OF SEAMONKEY:
* added improved error message for IID collision.
1999-03-11 02:15:53 +00:00
coop%netscape.com
bec672cfc0 NOT YET PART OF SEAMONKEY:
* one character fix (D'oh!) to make InterfaceTypeDescriptor indices update properly.
1999-03-10 23:41:04 +00:00
coop%netscape.com
8d12155d19 NOT YET PART OF SEAMONKEY:
* first annotation indicates that resulting typelib was created by the linker.
* annotations from files being linked in are now preserved.
1999-03-10 20:40:17 +00:00
coop%netscape.com
3c25f1eef4 NOT YET PART OF SEAMONKEY:
* xpt_dump now checks num_methods and num_constants before trying to walk the arrays.
* xpt_link now actually links. It even updates interfaces indices. Tested using all the idl files in mozilla/xpcom/idl.
1999-03-10 19:44:36 +00:00
mccabe%netscape.com
b625b6aa37 Added tests of getting info assoc'd with params to TestInterfaceInfo.cpp, which uncovered an off-by-one problem due to magic typelib offsets for nsXPTParamInfo. Which makes me wonder if we shouldn't have just said #define XPT_INDEX_NO_PARENT 0xFFFF. 1999-03-10 10:36:13 +00:00
mccabe%netscape.com
1a1a2d5d23 Not yet part of the Monkey.
- Added magic comments to make the LXR browsing experience more pleasant.

- introduced the nsInterfaceRecord class (formerly less formally interface_record).

- changed the XPTInterfaceDirectoryEntry pointer in InterfaceInfoes into nsInterfaceRecord pointers, removing the need for a hash just to go from entries to records to support nsXPTParamInfo::GetInterface.

- made the destructor for InterfaceInfo objects remove null the pointer in the corresponding reference.
1999-03-10 09:30:48 +00:00
mccabe%netscape.com
c95fc2f4b8 Not part of seamonkey.
Added a comment saying preconditions the tests actually needs to
succeed.  (also simplified these some.)
1999-03-10 08:22:17 +00:00
mccabe%netscape.com
4f6e0a7c6e Not part of seamonkey.
Fixed bustage due to improper use of DEBUG_somehacker.
1999-03-10 06:59:53 +00:00
jband%netscape.com
122488c723 making it compile on Win32 1999-03-10 06:36:03 +00:00
mccabe%netscape.com
5a43e6a2dd Not part of seamonkey.
API change - changed nsXPTParamInfo from taking an InterfaceDirectoryEntry* (which really isn't part of the API I want to expose) to taking an nsIInterfaceInfo*, which is.
1999-03-10 06:06:19 +00:00
mccabe%netscape.com
a7a7b4f959 Not yet part of Seamonkey.
Progress on the nsInterfaceInfoManager typelib loader for xpconnect.
Now has complete (I think) functionality, though the implementation is
still probably rusty.

I punted on defining a directory for .xpt files at this point; the
implementation looks at the value of the XPTDIR environment variable
for this value.

Note that the nsXPTParaminfo interface (public/xpt_cpp) has changed
(possibly temporarily) to take an 'entry' parameter.
1999-03-10 04:26:15 +00:00
mccabe%netscape.com
9ad7c135d1 Chop xptinfo from the list of sub-Makes built by libxpt during coding
thrash.
1999-03-09 04:10:30 +00:00
coop%netscape.com
a356faf7da NOT YET PART OF SEAMONKEY:
* initial pass at handling the update of interface indices.
1999-03-09 02:51:22 +00:00
shaver%netscape.com
bf2718b64b ignore generated files 1999-03-08 21:27:03 +00:00
coop%netscape.com
244b59ee4f NOT YET PART OF SEAMONKEY:
* linker now sorts based on IIDs
* xpt_dump no longer complains about md->result if it is of the correct retval type
1999-03-08 21:13:58 +00:00
shaver%netscape.com
df77619c4a display method flags, handle bogus indices 1999-03-08 21:11:08 +00:00
shaver%netscape.com
2636f0fba1 Make params include the name of the interface referenced. 1999-03-08 20:33:35 +00:00
coop%netscape.com
23aac1de6d NOT YET PART OF SEAMONKEY:
* changing references to interfaces (within structs) to be indices rather than pointers
* updated xpt_dump and xpt_link code to reflect above change
1999-03-08 19:47:09 +00:00
shaver%netscape.com
d55deef772 fix remnant of 32-bit interface references 1999-03-08 03:56:14 +00:00
shaver%netscape.com
c31d863018 Add XPT_InterfaceDescriptorAddConsts to API. 1999-03-06 19:40:34 +00:00
jband%netscape.com
aae72939cf makefile fixups to get xptinfo working on Win32. Added xptinfo.h for public dll declarations 1999-03-02 07:59:53 +00:00
mccabe%netscape.com
8c24b0a7f5 Not yet part of Seamonkey.
Changed from using malloc to (much less, but still slightly) hacked
nsIAllocator service.
1999-03-02 05:38:27 +00:00
mccabe%netscape.com
40181d78ce Not yet part of the seamonkey build.
Moved nsInterfaceInfoManager files from the libxpt directory (where
they would have precipitated an unpleasant circular dependency between
xpidl and nsISupports.h) into a new subdirectory.

Added corresponding entries to allmakefiles.sh.

nsInterfaceInfoManager is intended to abstract the loading and
management of typelib information generated by xpidl, for use by
xpconnect.
1999-03-02 05:21:31 +00:00
mccabe%netscape.com
6674e1b86b Initial checkin of typelib loading service. 1999-02-25 22:56:43 +00:00
coop%netscape.com
bca65dbd8e NOT YET PART OF SEAMONKEY:
* first pass at typelib linker
* parent_interface modification is untested
* interface offset management is unimplemented
* what to do about annotations?
1999-02-25 17:45:11 +00:00
coop%netscape.com
0c1ab19c56 NOT YET PART OF SEAMONKEY:
* fixed casting problem in calls to Do8
1999-02-23 16:17:37 +00:00
alecf%netscape.com
544d9d773b make these libraries build during the export phase 1999-02-18 22:36:27 +00:00
coop%netscape.com
4a28ad0dc3 NOT YET PART OF SEAMONKEY:
* now close input file in all cases
* warn user about params with no in/out flag information
* more internal error checking
1999-02-18 22:29:59 +00:00
shaver%netscape.com
d96b4c6f50 fix InterfaceDescriptorAddMethods to not randomly overwrite memory, and fix
DoMethodDescriptor to not randomly overwrite md->result
1999-02-18 17:36:46 +00:00
shaver%netscape.com
7138211132 binary files are required (thanks, jband). also fix typo 1999-02-18 02:53:08 +00:00
shaver%netscape.com
950bd8bad9 Report read failure and short reads (should handle short reads better! RSN!).
File length is a size_t now, not an int.
1999-02-18 00:42:01 +00:00
coop%netscape.com
14a98b2ab8 NOT YET PART OF SEAMONKEY:
* replaces reference to unistd.h by stdlib.h
1999-02-17 17:36:01 +00:00
jband%netscape.com
40ef764595 get this code compiling in win32 1999-02-17 07:05:36 +00:00
coop%netscape.com
76bdfa96b3 NOT YET PART OF SEAMONKEY:
* eliminated compiler warnings on Linux
* added extra error checking for file manipulation in SimpleTypeLib and xpt_dump
* removed erroneous comment from xpt_struct.h
1999-02-16 18:41:30 +00:00
coop%netscape.com
434b53519d NOT YET PART OF SEAMONKEY:
* changed type descriptor tag defines into one big enum
* made corresponding changes to xpt_dump
1999-02-10 17:44:05 +00:00
coop%netscape.com
cc3262e0a5 NOT YET PART OF SEAMONKEY:
* added function XPT_GetInterfaceIndexByName
* replaced remaining occurences of 'namespace' with 'name_space' to keep C++ happy
* added xpt_dump display for param types (in/out/retval)
* changed xpt_dump handling for wchar_t strings
* use shaver's print_IID function when displaying type descriptors
* removed DoAnnotations (not used)
1999-02-09 00:14:38 +00:00
jband%netscape.com
7f234de162 NOT PART OF SEAMONKEY - a bunch of fixes to get it building on win32 1999-02-08 21:47:35 +00:00
shaver%netscape.com
e51cd01134 move includes outside #ifdef for precompiled-header love, also PR_EXTERN_C 1999-02-08 19:48:48 +00:00
shaver%netscape.com
886e0b74fd Windows make goop 1999-02-08 18:34:54 +00:00
shaver%netscape.com
22cd82efb2 Added XPT_InterfaceDescriptorAddMethods to grow the method table.
Removed unused XPT_ALLOC macro.
Move XPT_SetDataOffset calls into XPT_DoHeader so that the API consumer doesn't
need to know about header sizing and IDE layout guck.
Handle NULL namespaces and interface_directory bits snd idents better.
Made xpt_dump show the the IID for interfaces.
1999-02-08 16:30:22 +00:00
coop%netscape.com
daf6598bf9 NOT YET PART OF SEAMONKEY:
* added support for non-verbose mode as default for typelib dumper.
1999-02-04 03:16:07 +00:00
coop%netscape.com
5b67c2d922 NOT YET PART OF SEAMONKEY:
* add command-line flag for verbose mode, which will soon not be the default
* now outputs to stdout
* added output for int64, uint64, and wchar
1999-02-04 00:31:59 +00:00
shaver%netscape.com
7cc025f858 (NOT YET PART OF SEAMONKEY)
Update to use 16-bit IDE indices (one-based) instead of header-pool offsets.
Removed debugging cruft.
Added prototypes to get rid of warnings.
Fix many dumb mistakes WRT allocation and index checking.
1999-02-03 21:37:25 +00:00
mcafee%netscape.com
3ebf5bfd31 Ignore generated SimpleTypeLib, PrimitiveTestexecutables 1999-02-02 06:20:46 +00:00
mcafee%netscape.com
a9ba07971c Ignore generated xpt_dump executable 1999-02-02 06:19:50 +00:00
coop%netscape.com
ad630a62a1 NOT YET PART OF SEAMONKEY:
* fixed header pointer assignment problem
* removed useless defines
* added correct level of indirection for sub-structs of header
1999-02-02 01:26:36 +00:00
coop%netscape.com
072c9699f3 NOT YET PART OF SEAMONKEY:
* added directory libxpt/tools which currently only contains the typelib dumper
* removed dump code from tests dir
* added/modified appropriate Makefiles and configure scripts
1999-01-30 01:10:01 +00:00
coop%netscape.com
30a0f2ae51 NOT YET PART OF SEAMONKEY:
* committing fixes for shaver
* header pointer is now set XPT_DoHeader
* fixed assertion error in CHECK_COUNT macro
1999-01-30 01:03:54 +00:00
coop%netscape.com
98d8567a39 NOT YET PART OF SEAMONKEY:
* added macros for checking bitflag values
* dump code is complete, minus actually reading from disk.
1999-01-28 06:01:56 +00:00
shaver%netscape.com
ff139572c0 fix header.data_pool writing 1999-01-28 01:55:24 +00:00
coop%netscape.com
fc64b44984 NOT YET PART OF SEAMONKEY:
* fixed XPT_SizeOfHeader. It wasn't actually walking the annotations, but it does now.
* added some basic dumping code to SimpleTypeLib. Currently only the headers can be dumped. Once XDR read code is up and running, this dumping code will become a separate utility, most likely under a libxpt/tools subdir.
1999-01-27 06:32:57 +00:00
shaver%netscape.com
a64e54446d Fixed method and type descriptors, made const descriptors go. 1999-01-26 19:31:25 +00:00
shaver%netscape.com
9feb565d72 fixed fencepost in XPT_DoHeader, along with more error-checking 1999-01-26 01:34:21 +00:00
shaver%netscape.com
adc25a815d Fixed IID copying (duh -- all the bytes matter).
NewString and NewStringZ APIs.
No more bit-fields (nod to jband and fur, thanks).
Cleaned up Annotation structures.
On-disk offsets are 1-based.
Write annotations to disk, and account for them in header size, etc.
Fix sundry cursor-vs-&cursor bugs and don't-allocate-on-decode bugs.
Write MethodDescriptors and InterfaceDescriptors to disk!
Executive Summary: can now write very simple .xpt files!
1999-01-25 19:36:48 +00:00
mcafee%netscape.com
61a7675545 Switching to SIMPLE_PROGRAMS 1999-01-23 12:21:27 +00:00
shaver%netscape.com
aa1ebbaf5b Added prototypes for Header XDR functions.
Minor brace-placement tweaks.
Added SimpleTypeLib test program, although it doesn't build due to Makefile.in
suckage.
Fixed XPT_DoHeader to only write IDEs once (duh).
Added SizeOfHeaderBlock to API.
1999-01-22 17:53:35 +00:00
mcafee%netscape.com
ba84b098cf Yanked rules that are in rules.mk 1999-01-22 12:14:51 +00:00
shaver%netscape.com
3ffc120748 Added methods to create or fill headers, IDEs, interface descriptors,
method descriptors, param descriptors, const descriptors (partial)
and annotations.
Rejigged XPTAnnotation for proper struct nesting and linked-listed-ness.
Implemented SizeOfHeader (partially).
Fixed data_pool handling in XPT_DoHeader.
Implemented XPT_SeekTo and XPT_DoIID.
1999-01-22 09:13:02 +00:00
ramiro%netscape.com
127039e271 Ignore generated files. 1999-01-22 06:33:54 +00:00
shaver%netscape.com
a11e05cc3d test DoString 1999-01-21 20:05:58 +00:00
shaver%netscape.com
a7561e1c7c allocate memory for str->bytes in DoString decode, duh 1999-01-21 20:05:27 +00:00
shaver%netscape.com
fc992be11c fix dumb DBG thing 1999-01-21 19:21:58 +00:00
coop%netscape.com
cebd0d5f18 NOT YET PART OF SEAMONKEY:
* removed struct size #defines -> they were just silly anyway.
* replaced references to IDE file offsetsi with uint32 indices.
* first attempt at sorting out order of storage for XPTHeader and XPTInterfaceDirectoryEntry
1999-01-21 19:18:47 +00:00
shaver%netscape.com
ce42fc0851 Better cursor management stuff.
Mild macro renaming.
Debugging output from CHECK_COUNT.
Fixed primitives and PrimitiveTest: we now pass! (32, 16, 8 and CString)
Dynamically link PrimitiveTest.
1999-01-21 17:37:54 +00:00
shaver%netscape.com
5ee98f8ade added some tests (we don't pass yet =) ), wrote some primitives 1999-01-20 23:17:05 +00:00
coop%netscape.com
4fe4d500ab NOT YET PART OF SEAMONKEY:
* added looping to read/write InterfaceDirectoryEntrys
* InterfaceDescriptors are no longer DECODEd as part of the IDE DECODEing process
* added skeleton for XPT_GetDescriptorByOffset
1999-01-20 17:58:14 +00:00
coop%netscape.com
7d3c473417 NOT YET PART OF SEAMONKEY:
* added offset management code in the form of calls to shaver's macros
1999-01-19 23:46:20 +00:00
coop%netscape.com
f2d5cd7054 NOT YET PART OF SEAMONKEY:
* added #defines for is_pointer/tag combos used in TypeDescriptors to match table in typelib spec.
* now handle error case in xpt_struct.c using macro
* still must do offset management
1999-01-18 22:04:49 +00:00
coop%netscape.com
5fc06bfca5 NOT YET PART OF SEAMONKEY:
* modified in-memory structs slightly to get them to compile
* xpt_strcut.c now compiles, and with no warnings (at no extra charge)
* still must do offset management
1999-01-18 19:53:47 +00:00
shaver%netscape.com
10f4d40c79 Much XDR header whacking. Still need to figure out how the pool management
stuff looks.
Fixed XPT_PREAMBLE (again).
xpt_xdr.c now compiles!
1999-01-18 18:28:14 +00:00
shaver%netscape.com
00741083fe fix up XPT_PREAMBLE booboo 1999-01-18 17:58:34 +00:00
shaver%netscape.com
7c8b3fd275 make goop (Win and Unix) 1999-01-18 17:44:06 +00:00
shaver%netscape.com
4d0a0a61c3 make goop (Windows and Unix) and header fixes 1999-01-18 17:43:36 +00:00
coop%netscape.com
d557721c1f NOT YET PART OF SEAMONKEY:
* updated XPT_Do code to match in-memory structs
1999-01-18 17:26:04 +00:00
shaver%netscape.com
9836a9165b new API stuff, and start on primitive implementations 1999-01-18 16:54:57 +00:00
coop%netscape.com
95fe556feb NOT YET PART OF SEAMONKEY:
* Added at least basic comments for all structs.
* Added #defines for struct sizes.
1999-01-18 15:00:03 +00:00
shaver%netscape.com
1d651befd8 more primitives and over-complex macros. next stop: bit-handling (not yet part of seamonkey) 1999-01-15 21:14:48 +00:00
coop%netscape.com
851b2c9b09 NOT PART OF SEAMONKEY
- updated and streamlined in-memory structure to coincide with typelib specification.
- added comments for more obtuse structures
1999-01-15 19:23:40 +00:00
coop%netscape.com
8974b59b09 Fleshed out XDR code for in-memory structs.
To do:
- still need to track data pool offsets for most structs
1999-01-15 00:06:44 +00:00
coop%netscape.com
084afe2ada Made necessary modifications to in-memory structs after writing some of
the XDR code for them.
1999-01-15 00:04:56 +00:00
shaver%netscape.com
fe030ddb6e updated API example in XPT_DoIDE 1999-01-14 17:35:14 +00:00
shaver%netscape.com
ce7e4abb48 start of per-struct XDR code; a: leaf 1999-01-13 21:52:02 +00:00
shaver%netscape.com
82abed2f8f more header goo, xdr implementation stubs 1999-01-13 15:20:25 +00:00
shaver%netscape.com
73c8b0241d initial XDR primitives 1999-01-12 21:36:11 +00:00
shaver%netscape.com
840f5d9ec3 initial typelib structures 1999-01-12 19:17:25 +00:00