- Timestamp:
- Jul 5, 2010, 3:44:51 PM (15 years ago)
- File:
-
- 1 edited
-
trunk/doc/Porting.txt (modified) (9 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/doc/Porting.txt
r3990 r21384 20 20 Keep in mind that Odin is still alpha software, so don't expect all apis to 21 21 work exactly like those in Windows NT. 22 If you find bugs, please contact the developers or send an email to the 22 If you find bugs, please contact the developers or send an email to the 23 23 Odin programmers mailinglist (win32os2-wai@egroups.com). 24 24 … … 26 26 ------------------------------------------------- 27 27 - IBM VisualAge C++ 3.08 28 - OS/2 Warp 4 Toolkit (project apparently doesn't compile with 28 - OS/2 Warp 4 Toolkit (project apparently doesn't compile with 29 29 VAC's OS/2 headers) 30 30 Might also work with EMX headers. (haven't tried this) … … 98 98 ----------------------------- 99 99 Usually you shouldn't have to make many changes to the existing win32 100 source code. 100 source code. 101 101 However, there might be a few differences between the MS SDK and Odin 102 102 headers. If you find such problems, please correct them and notify … … 105 105 Complex applications might be hard to port to OS/2 for several reasons: 106 106 - Compiler differences (i.e. VAC 3.08 doesn't support unnamed unions) 107 VAC 3.6.5 should be a better choice for compiling win32 sources, but 107 VAC 3.6.5 should be a better choice for compiling win32 sources, but 108 108 it has it's own share of problems (bugs). 109 109 - TLS (thread local storage) data; VAC has no facilities to support this, … … 112 112 You can recognize this type of data by the __declspec(thread) keyword. 113 113 Using the TLS apis (i.e. TlsAlloc) is no problem. 114 - OLE/COM objects. Wine headers aren't exactly built with C++ in mind, 114 - OLE/COM objects. Wine headers aren't exactly built with C++ in mind, 115 115 so you'll most likely run into a lot of problems if the app uses 116 116 these win32 features. … … 122 122 for Odin. This handler is used to support file mappings. 123 123 You must make sure that your code doesn't remove this handler from 124 the chain of exception handlers. 124 the chain of exception handlers. 125 125 To create a thread, use CreateThread; not _beginthread or DosCreateThread. 126 126 CreateThread takes care of setting up an exception handler, creates TLS 127 structures and calls dll entrypoints. 127 structures and calls dll entrypoints. 128 129 Starting with r21382, Odin also implements the compiler-level support for SEH 130 (structured exception handling) performed using the __try/__except statement in 131 MSVC. Note that this is not a real compiler statement, it is just an emulation 132 of the corresponding MSVC behavior and it has the following limitations: 133 - You should not use goto or longjmp() to jump into or out of the __try or 134 __except block -- this will most likely screw up the stack. 135 - __try/__finally/__leave functionality is not yet supported. 136 - Only the GCC compiler is supported ATM. 137 138 In order to enable proper handling of the __try/__except statement, you must 139 call EnableSEH() right before a call to RegisterLXDll() or RegisterLXExe() (as 140 described above). A failure to do so will break the filter expression 141 functionality. 142 143 Note that you normally don't need to chage the Windows sources that the 144 __try/__except statement themselves (except for the limitations mentioned above) 145 as they should already include <excpt.h> (which is normally provided by a 146 compiler for the windows platform) and the one included in Odin SDK provides 147 the source-level compatible definitions. 128 148 129 149 2.6 Sample makefile … … 145 165 146 166 # Define project specific macros 147 PROJ_OBJS = generic.obj 148 BASE_OBJS = resource.obj odinexe.obj 167 PROJ_OBJS = generic.obj 168 BASE_OBJS = resource.obj odinexe.obj 149 169 EXTRA_LIBS = $(PDWIN32_LIB)\version.lib 150 170 GLOBAL_DEP = generic.h resource.h … … 165 185 # Build rule for resource file 166 186 resource.asm: $(PROJ).rc $(RC_DEP) 167 $(RC) $(RCFLAGS) -o resource.asm $(PROJ).rc 187 $(RC) $(RCFLAGS) -o resource.asm $(PROJ).rc 168 188 169 189 # Build rule for EXE … … 184 204 ------------------------- 185 205 186 As ODIN became an open source project, everybody is kindly invited to 206 As ODIN became an open source project, everybody is kindly invited to 187 207 contribute his/her share to the progress of the project. May it be 188 active coding, fixing bugs or just providing detailed information about 208 active coding, fixing bugs or just providing detailed information about 189 209 examined problems. 190 210 191 211 We suggest you subscribe to win32os2-wai and the corresponsing mailing lists 192 212 on http://www.egroups.com. 193 In case you are interested in participating, every member of the project will 194 be happy to give you direction to the right places and to give a personal 213 In case you are interested in participating, every member of the project will 214 be happy to give you direction to the right places and to give a personal 195 215 introduction to further development of the particular modules. 196 216
Note:
See TracChangeset
for help on using the changeset viewer.
