Skip to main content

Compilation error due to change in OsMemory.cpp

2 replies [Last post]
Anonymous

In svn commit 12461 the following file was changed:
cldc/trunk/src/vm/share/runtime/OsMemory.cpp

The commit removed the #ifndef UNDER_CE around OsMemory_allocate and
OsMemory_allocate_chunk. When I compile pMEF for WinCE I get compilation
errors because these methods are also provided in OsMemory_wince.cpp,
resulting in linking errors later on. Adding the macro directives solves it
for me, but it is unclear to me why they were removed in the first place.
Patch to add them again is included in attach.

Revision 12461
2008-07-15 11:31:02+0000 (2 weeks ago) by dgomon
CR 6704368 : Perform WinCE buybacks to Bengal
merged -r11504:12456 from cldc-cr-6704368. Reviewed by Y.Diomidov.

Regards,
Davy
[OsMemory.diff]
---------------------------------------------------------------------
To unsubscribe, e-mail: feature-unsubscribe@phoneme.dev.java.net
For additional commands, e-mail: feature-help@phoneme.dev.java.net

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
danila
Offline
Joined: 2006-09-25

Hi Davy,

I would suggest to add #if !ENABLE_PCSL to cldc/src/vm/os/wince/OsMemory_wince.cpp
instead:

+++ OsMemory_wince.cpp (working copy)
@@ -31,6 +31,8 @@
#include "incls/_precompiled.incl"
#include "incls/_OsMemory_wince.cpp.incl"

+#if !ENABLE_PCSL
+
#ifdef __cplusplus
extern "C" {
#endif
@@ -46,3 +48,5 @@
#ifdef __cplusplus
}
#endif
+
+#endif // !ENABLE_PCSL

It would be more consistent with other platforms.
Could you check if this change works for you?

Thanks,
Danila

Davy Preuveneers

The fix that Dmitri committed in SVN seems to work.

Thanks,
Davy

On Wednesday 30 July 2008, danila wrote:
> Hi Davy,
>
> I would suggest to add #if !ENABLE_PCSL to
> cldc/src/vm/os/wince/OsMemory_wince.cpp instead:
>
> +++ OsMemory_wince.cpp (working copy)
> @@ -31,6 +31,8 @@
> #include "incls/_precompiled.incl"
> #include "incls/_OsMemory_wince.cpp.incl"
>
> +#if !ENABLE_PCSL
> +
> #ifdef __cplusplus
> extern "C" {
> #endif
> @@ -46,3 +48,5 @@
> #ifdef __cplusplus
> }
> #endif
> +
> +#endif // !ENABLE_PCSL
>
> It would be more consistent with other platforms.
> Could you check if this change works for you?
>
> Thanks,
> Danila
> [Message sent by forum member 'danila' (danila)]
>
> http://forums.java.net/jive/thread.jspa?messageID=290272
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: feature-unsubscribe@phoneme.dev.java.net
> For additional commands, e-mail: feature-help@phoneme.dev.java.net

---------------------------------------------------------------------
To unsubscribe, e-mail: feature-unsubscribe@phoneme.dev.java.net
For additional commands, e-mail: feature-help@phoneme.dev.java.net