Correct me if I'm wrong here, but using this solution would mean having to build two binaries, as #if blocks are compile time directives.

You'd need to build once as a Mach-O PPC binary, and in that case the calls to the plugin would be included. You'd then need to build as a UB binary, in which case the calls would not be included.

Or am I missing something here, and behind the scenes RB is actually building both of these binaries when you choose a UB target, and then rolling them into a single package, in which case this solution would be just fine.
Either that or #if blocks are actually runtime directives??

Please enlighten me.

Cheers,
- Tom

On 21/12/2006, at 10:18 AM, David Grogono wrote:

Something like this should do the trick:

  #if TargetMachO and TargetPowerPC
    //Make calls to Mach-O PPC plugin here
  #endif

- David

On Dec 20, 2006, at 3:59 PM, Tom Benson wrote:

Probably not, since these are compiler TARGET variables, not OPERATING ENVIRONMENT variables.

What is needed is an environmental gestalt that will let the application know what environment it is executing under, however this would only be useful for dynamically loaded libs, not plugins which the compiler will include anyway.

Hmmm.. a real tricky one, where I think the only option is to UB the plugin, or try and access it dynamically as a dylib.

- Tom

On 20/12/2006, at 9:29 PM, E. Tejkowski wrote:

Would this help?

Function TargetMacIntel() As boolean
  return (TargetMachO and TargetX86)
End Function

Erick

On Dec 19, 2006, at 10:20 PM, Dr Gerard Hammond wrote:

Why isn't there an option under the constants 'Platform' editor for 'Macho-Intel'

I need to build a UB that has a constant set to true for "Mac Macho Carbon' but false for "Mac Macho- Intel'

This is because I have a plugin that only works under Macho PPC machines, but I want a Single UB app to have the Macho-intel version not include calls to the plugin as well as a PPC macho binary that does have the plugin.

Could I build the app twice, setting the constant manually and then merge the two binaries together by hand to make a UB bundle that works on Intel Macs (without the plugin) and on PPC Macs (with the plugin)

The plugin doesn't have a MacIntel component as it was made with CodeWarrior.

_______________________________________________
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>

_______________________________________________
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>

_______________________________________________
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>

_______________________________________________
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>

Reply via email to