On 8/9/05, Brady Duga <duga at ljug dot com> wrote:
>
>
> On Aug 9, 2005, at 12:02 PM, Ken Mankoff wrote:
> >
> > If I try to compile the Windows version from the Mac I get the same
> > compile-time errors. ?!?!
>
> Weird. Maybe you have some platform-specific code nearby? Or maybe
> there is something wrong with the Windows constant - you might want
> to double check that. And I see from your next email that may be the
> case. Make sure the target is correct and that the "string" button is
> pushed for the constant.
Yes wierd. Wierd enough I think it is a bug. So my actual declare code is
this:
#If DebugBuild
soft declare function nc_inq_dim lib library_debug ( ncid as integer, dimid
as integer, namePtr as ptr, byref length as integer ) as integer
#else
soft declare function nc_inq_dim lib library ( ncid as integer, dimid as
integer, namePtr as ptr, byref length as integer ) as integer
#endif
Because RB allows constants specific to platforms, but *not* to builds, and
the relative location for the app changes on a debug v. real build.
So "libary" on the mac distribution build is:
@executable_path/../../lib/netCDF/libnetcdf.dylib
and "library_debug on the mac debug build is:
@executable_path/../../../lib/netCDF/libnetcdf.dylib (note extra ../ thrown
in there)
And if I comment out 4 of the above 5 lines (all the #'s and one of the
declare statements) it works.
Well, for the Mac it works always no matter what. But I can't compile for
windows if I have the #if #else #endif and the two declares. If I have only
1 declare then it works. Strange, but true.
What do you think? Bug report?
-k.
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>
|