realbasic-plugins
[Top] [All Lists]

XCode 1.2 problem?

To: realbasic-plugins at lists dot realsoftware dot com
Subject: XCode 1.2 problem?
From: Jason Swaine <jmswaine at mac dot com>
Date: Mon, 27 Sep 2004 00:56:08 +0100
Delivered-to: realbasic-plugins at lists dot realsoftware dot com
Hello everyone!

It's my first posting to this list, so here goes... I've been following the discussions on Mach-O and have attempted to build a simple plug-in using XCode 1.2 and the Plug-in SDK downloaded yesterday. I followed the procedures for XCode and Plug-in Converter as outlined in the readme files to build TestPlugin.rbx. I had inserted the following test code into TestPlugin.cpp file:-

#include "rb_plugin.h"

static int add5func(int v)
{
        return v + 5;
}

REALmethodDefinition add5defn = {
        (REALproc) add5func,
        REALnoImplementation,
        "add5(v as integer) as integer"
};

void PluginEntry(void)
{
        REALRegisterMethod(&add5defn);
}

In RB, I created a simple button to test the plug-in:-

Sub Action()

msgbox "Result = "+Str(add5(10)) //Note: add5 recognized by IDE (auto-completed ok)

End Sub

When I ran it, I got the "expected" CollectRuntime.cpp:1196 error but after clicking the OK button once, I got the unexpected error:-

Cannot load Mac OS version of plugin "Macintosh HD:Developer:RealBasic 5.5.3:Plugins:TestPlugin.rbx:0"

When I clicked the OK button, I was returned to the IDE immediately (without being able to run the RB executable).

Do I need to upgrade to XCode 1.5 or have I cocked up something along the way?


Many thanks!

Jason Swaine.
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://www.realsoftware.com/listarchives/lists.html>

<Prev in Thread] Current Thread [Next in Thread>