mirror of
https://github.com/kanjitalk755/macemu.git
synced 2024-11-29 14:49:44 +00:00
Add Passteboard Manager implementation of Mac OS X clipboard code.
Enabled by default for 64-bit Xcode build. (configure changes forthcoming) Based on patch by Jean-Pierre Stierlin <chombier@free.fr>.
This commit is contained in:
parent
8c9f1475d5
commit
99e8914019
313
BasiliskII/src/MacOSX/clip_macosx64.cpp
Normal file
313
BasiliskII/src/MacOSX/clip_macosx64.cpp
Normal file
@ -0,0 +1,313 @@
|
||||
/*
|
||||
* clip_macosx64.cpp - Clipboard handling, MacOS X (Pasteboard Manager) implementation
|
||||
*
|
||||
* (C) 2012 Jean-Pierre Stierlin
|
||||
* (C) 2012 Alexei Svitkine
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#include "sysdeps.h"
|
||||
#define _UINT64
|
||||
#include <Carbon/Carbon.h>
|
||||
|
||||
#include "clip.h"
|
||||
#include "main.h"
|
||||
#include "cpu_emulation.h"
|
||||
#include "emul_op.h"
|
||||
|
||||
#define DEBUG 0
|
||||
#include "debug.h"
|
||||
|
||||
#ifndef FOURCC
|
||||
#define FOURCC(a,b,c,d) (((uint32)(a) << 24) | ((uint32)(b) << 16) | ((uint32)(c) << 8) | (uint32)(d))
|
||||
#endif
|
||||
|
||||
#define TYPE_PICT FOURCC('P','I','C','T')
|
||||
#define TYPE_TEXT FOURCC('T','E','X','T')
|
||||
|
||||
static PasteboardRef g_pbref;
|
||||
|
||||
// Flag for PutScrap(): the data was put by GetScrap(), don't bounce it back to the MacOS X side
|
||||
static bool we_put_this_data = false;
|
||||
|
||||
static CFStringRef GetUTIFromFlavor(uint32 type)
|
||||
{
|
||||
switch (type) {
|
||||
case TYPE_PICT: return kUTTypePICT;
|
||||
case TYPE_TEXT: return CFSTR("com.apple.traditional-mac-plain-text");
|
||||
//case TYPE_TEXT: return CFSTR("public.utf16-plain-text");
|
||||
//case FOURCC('s','t','y','l'): return CFSTR("????");
|
||||
case FOURCC('m','o','o','v'): return kUTTypeQuickTimeMovie;
|
||||
case FOURCC('s','n','d',' '): return kUTTypeAudio;
|
||||
//case FOURCC('u','t','x','t'): return CFSTR("public.utf16-plain-text");
|
||||
case FOURCC('u','t','1','6'): return CFSTR("public.utf16-plain-text");
|
||||
//case FOURCC('u','s','t','l'): return CFSTR("????");
|
||||
case FOURCC('i','c','n','s'): return kUTTypeAppleICNS;
|
||||
default: return NULL;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* Get current system script encoding on Mac
|
||||
*/
|
||||
|
||||
#define smMacSysScript 18
|
||||
#define smMacRegionCode 40
|
||||
|
||||
static int GetMacScriptManagerVariable(uint16 id)
|
||||
{
|
||||
int ret = -1;
|
||||
M68kRegisters r;
|
||||
static uint8 proc[] = {
|
||||
0x59, 0x4f, // subq.w #4,sp
|
||||
0x3f, 0x3c, 0x00, 0x00, // move.w #id,-(sp)
|
||||
0x2f, 0x3c, 0x84, 0x02, 0x00, 0x08, // move.l #-2080243704,-(sp)
|
||||
0xa8, 0xb5, // ScriptUtil()
|
||||
0x20, 0x1f, // move.l (a7)+,d0
|
||||
M68K_RTS >> 8, M68K_RTS
|
||||
};
|
||||
r.d[0] = sizeof(proc);
|
||||
Execute68kTrap(0xa71e, &r); // NewPtrSysClear()
|
||||
uint32 proc_area = r.a[0];
|
||||
if (proc_area) {
|
||||
Host2Mac_memcpy(proc_area, proc, sizeof(proc));
|
||||
WriteMacInt16(proc_area + 4, id);
|
||||
Execute68k(proc_area, &r);
|
||||
ret = r.d[0];
|
||||
r.a[0] = proc_area;
|
||||
Execute68kTrap(0xa01f, &r); // DisposePtr
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
/*
|
||||
* Convert utf-16 from/to system script encoding on Mac
|
||||
*/
|
||||
|
||||
CFDataRef ConvertMacTextEncoding(CFDataRef pbData, int from_host)
|
||||
{
|
||||
static TextEncoding g_textEncodingHint = kTextEncodingUnknown;
|
||||
static UnicodeMapping uMapping;
|
||||
static UnicodeToTextInfo utInfo;
|
||||
static TextToUnicodeInfo tuInfo;
|
||||
static int ready;
|
||||
|
||||
// should we check this only once ?
|
||||
if (g_textEncodingHint == kTextEncodingUnknown) {
|
||||
int script = GetMacScriptManagerVariable(smMacSysScript);
|
||||
int region = GetMacScriptManagerVariable(smMacRegionCode);
|
||||
if (UpgradeScriptInfoToTextEncoding(script, kTextLanguageDontCare, region, NULL, &g_textEncodingHint))
|
||||
g_textEncodingHint = kTextEncodingMacRoman;
|
||||
uMapping.unicodeEncoding = CreateTextEncoding(kTextEncodingUnicodeV2_0, kTextEncodingDefaultVariant, kUnicode16BitFormat);
|
||||
uMapping.otherEncoding = GetTextEncodingBase(g_textEncodingHint);
|
||||
uMapping.mappingVersion = kUnicodeUseLatestMapping;
|
||||
ready = !CreateUnicodeToTextInfo(&uMapping, &utInfo) && !CreateTextToUnicodeInfo(&uMapping, &tuInfo);
|
||||
}
|
||||
if (!ready)
|
||||
return pbData;
|
||||
|
||||
ByteCount byteCount = CFDataGetLength(pbData);
|
||||
ByteCount outBytesLength = byteCount * 2;
|
||||
LogicalAddress outBytesPtr = malloc(byteCount * 2);
|
||||
if (!outBytesPtr)
|
||||
return pbData;
|
||||
|
||||
ByteCount outBytesConverted;
|
||||
OSStatus err;
|
||||
if (from_host) {
|
||||
err = ConvertFromUnicodeToText(utInfo, byteCount, (UniChar *)CFDataGetBytePtr(pbData),
|
||||
kUnicodeLooseMappingsMask,
|
||||
0, NULL, 0, NULL,
|
||||
outBytesLength,
|
||||
&outBytesConverted, &outBytesLength, outBytesPtr);
|
||||
} else {
|
||||
err = ConvertFromTextToUnicode(tuInfo, byteCount, CFDataGetBytePtr(pbData),
|
||||
kUnicodeLooseMappingsMask,
|
||||
0, NULL, 0, NULL,
|
||||
outBytesLength,
|
||||
&outBytesConverted, &outBytesLength, (UniChar *)outBytesPtr);
|
||||
}
|
||||
|
||||
if (err == noErr && outBytesConverted == byteCount) {
|
||||
CFDataRef pbDataConverted = CFDataCreate(kCFAllocatorDefault, (UInt8*)outBytesPtr, outBytesLength);
|
||||
if (pbDataConverted) {
|
||||
CFRelease(pbData);
|
||||
pbData = pbDataConverted;
|
||||
}
|
||||
}
|
||||
free(outBytesPtr);
|
||||
|
||||
return pbData;
|
||||
}
|
||||
|
||||
/*
|
||||
* Initialization
|
||||
*/
|
||||
|
||||
void ClipInit(void)
|
||||
{
|
||||
OSStatus err = PasteboardCreate(kPasteboardClipboard, &g_pbref);
|
||||
if (err) {
|
||||
D(bug("could not create Pasteboard\n"));
|
||||
g_pbref = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Deinitialization
|
||||
*/
|
||||
|
||||
void ClipExit(void)
|
||||
{
|
||||
if (g_pbref) {
|
||||
CFRelease(g_pbref);
|
||||
g_pbref = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Mac application reads clipboard
|
||||
*/
|
||||
|
||||
void GetScrap(void **handle, uint32 type, int32 offset)
|
||||
{
|
||||
D(bug("GetScrap handle %p, type %4.4s, offset %d\n", handle, &type, offset));
|
||||
|
||||
CFStringRef typeStr;
|
||||
PasteboardSyncFlags syncFlags;
|
||||
ItemCount itemCount;
|
||||
|
||||
if (!g_pbref)
|
||||
return;
|
||||
|
||||
syncFlags = PasteboardSynchronize(g_pbref);
|
||||
if (syncFlags & kPasteboardModified)
|
||||
return;
|
||||
|
||||
if (PasteboardGetItemCount(g_pbref, &itemCount))
|
||||
return;
|
||||
|
||||
if (!(typeStr = GetUTIFromFlavor(type)))
|
||||
return;
|
||||
|
||||
for (UInt32 itemIndex = 1; itemIndex <= itemCount; itemIndex++) {
|
||||
PasteboardItemID itemID;
|
||||
CFDataRef pbData;
|
||||
|
||||
if (PasteboardGetItemIdentifier(g_pbref, itemIndex, &itemID))
|
||||
break;
|
||||
|
||||
if (!PasteboardCopyItemFlavorData(g_pbref, itemID, typeStr, &pbData)) {
|
||||
if (type == TYPE_TEXT)
|
||||
pbData = ConvertMacTextEncoding(pbData, TRUE);
|
||||
if (pbData) {
|
||||
// Allocate space for new scrap in MacOS side
|
||||
M68kRegisters r;
|
||||
r.d[0] = CFDataGetLength(pbData);
|
||||
Execute68kTrap(0xa71e, &r); // NewPtrSysClear()
|
||||
uint32 scrap_area = r.a[0];
|
||||
|
||||
// Get the native clipboard data
|
||||
if (scrap_area) {
|
||||
uint8 * const data = Mac2HostAddr(scrap_area);
|
||||
|
||||
memcpy(data, CFDataGetBytePtr(pbData), CFDataGetLength(pbData));
|
||||
|
||||
// Add new data to clipboard
|
||||
static uint8 proc[] = {
|
||||
0x59, 0x8f, // subq.l #4,sp
|
||||
0xa9, 0xfc, // ZeroScrap()
|
||||
0x2f, 0x3c, 0, 0, 0, 0, // move.l #length,-(sp)
|
||||
0x2f, 0x3c, 0, 0, 0, 0, // move.l #type,-(sp)
|
||||
0x2f, 0x3c, 0, 0, 0, 0, // move.l #outbuf,-(sp)
|
||||
0xa9, 0xfe, // PutScrap()
|
||||
0x58, 0x8f, // addq.l #4,sp
|
||||
M68K_RTS >> 8, M68K_RTS & 0xff
|
||||
};
|
||||
r.d[0] = sizeof(proc);
|
||||
Execute68kTrap(0xa71e, &r); // NewPtrSysClear()
|
||||
uint32 proc_area = r.a[0];
|
||||
|
||||
if (proc_area) {
|
||||
Host2Mac_memcpy(proc_area, proc, sizeof(proc));
|
||||
WriteMacInt32(proc_area + 6, CFDataGetLength(pbData));
|
||||
WriteMacInt32(proc_area + 12, type);
|
||||
WriteMacInt32(proc_area + 18, scrap_area);
|
||||
we_put_this_data = true;
|
||||
Execute68k(proc_area, &r);
|
||||
|
||||
r.a[0] = proc_area;
|
||||
Execute68kTrap(0xa01f, &r); // DisposePtr
|
||||
}
|
||||
|
||||
r.a[0] = scrap_area;
|
||||
Execute68kTrap(0xa01f, &r); // DisposePtr
|
||||
}
|
||||
}
|
||||
|
||||
CFRelease(pbData);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Mac application wrote to clipboard
|
||||
*/
|
||||
|
||||
void PutScrap(uint32 type, void *scrap, int32 length)
|
||||
{
|
||||
static bool clear = true;
|
||||
D(bug("PutScrap type %4.4s, data %08lx, length %ld\n", &type, scrap, length));
|
||||
|
||||
PasteboardSyncFlags syncFlags;
|
||||
CFStringRef typeStr;
|
||||
|
||||
if (!g_pbref)
|
||||
return;
|
||||
|
||||
if (!(typeStr = GetUTIFromFlavor(type)))
|
||||
return;
|
||||
|
||||
if (we_put_this_data) {
|
||||
we_put_this_data = false;
|
||||
clear = true;
|
||||
return;
|
||||
}
|
||||
if (length <= 0)
|
||||
return;
|
||||
|
||||
if (clear && PasteboardClear(g_pbref))
|
||||
return;
|
||||
syncFlags = PasteboardSynchronize(g_pbref);
|
||||
if ((syncFlags & kPasteboardModified) || !(syncFlags & kPasteboardClientIsOwner))
|
||||
return;
|
||||
|
||||
CFDataRef pbData = CFDataCreate(kCFAllocatorDefault, (UInt8*)scrap, length);
|
||||
if (!pbData)
|
||||
return;
|
||||
|
||||
if (type == TYPE_TEXT)
|
||||
pbData = ConvertMacTextEncoding(pbData, FALSE);
|
||||
|
||||
if (pbData) {
|
||||
PasteboardPutItemFlavor(g_pbref, (PasteboardItemID)1, typeStr, pbData, 0);
|
||||
CFRelease(pbData);
|
||||
}
|
||||
}
|
@ -73,7 +73,7 @@ links:
|
||||
Unix/Darwin/lowmem.c Unix/Darwin/pagezero.c Unix/Darwin/testlmem.sh \
|
||||
dummy/audio_dummy.cpp dummy/clip_dummy.cpp dummy/serial_dummy.cpp \
|
||||
dummy/prefs_editor_dummy.cpp dummy/scsi_dummy.cpp SDL slirp \
|
||||
MacOSX/sys_darwin.cpp MacOSX/clip_macosx.cpp \
|
||||
MacOSX/sys_darwin.cpp MacOSX/clip_macosx.cpp MacOSX/clip_macosx64.cpp \
|
||||
MacOSX/macos_util_macosx.h Unix/cpr.sh \
|
||||
MacOSX/extfs_macosx.cpp Windows/clip_windows.cpp \
|
||||
MacOSX/MacOSX_sound_if.cpp MacOSX/MacOSX_sound_if.h \
|
||||
|
@ -50,7 +50,6 @@
|
||||
0856CFF314A99EF0000B1711 /* extfs.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0856CD8C14A99EEF000B1711 /* extfs.cpp */; };
|
||||
0856CFF414A99EF0000B1711 /* gfxaccel.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0856CD8D14A99EEF000B1711 /* gfxaccel.cpp */; };
|
||||
0856D00914A99EF0000B1711 /* macos_util.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0856CE0514A99EEF000B1711 /* macos_util.cpp */; };
|
||||
0856D02414A99EF0000B1711 /* clip_macosx.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0856CE2C14A99EF0000B1711 /* clip_macosx.cpp */; };
|
||||
0856D02514A99EF0000B1711 /* extfs_macosx.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0856CE2D14A99EF0000B1711 /* extfs_macosx.cpp */; };
|
||||
0856D05014A99EF1000B1711 /* prefs_macosx.mm in Sources */ = {isa = PBXBuildFile; fileRef = 0856CE7014A99EF0000B1711 /* prefs_macosx.mm */; };
|
||||
0856D05914A99EF1000B1711 /* SheepShaver.icns in Resources */ = {isa = PBXBuildFile; fileRef = 0856CE8314A99EF0000B1711 /* SheepShaver.icns */; };
|
||||
@ -119,6 +118,8 @@
|
||||
0873A76A14ABD151004F12B7 /* config-macosx-x86_64.h in Headers */ = {isa = PBXBuildFile; fileRef = 0873A76614ABD151004F12B7 /* config-macosx-x86_64.h */; };
|
||||
0873A76B14ABD151004F12B7 /* config.h in Headers */ = {isa = PBXBuildFile; fileRef = 0873A76714ABD151004F12B7 /* config.h */; };
|
||||
0873A80214AC515D004F12B7 /* utils_macosx.mm in Sources */ = {isa = PBXBuildFile; fileRef = 0873A80114AC515D004F12B7 /* utils_macosx.mm */; };
|
||||
0885A52F1593E47F005C4F7B /* clip_macosx64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0851E9561593E22B00EE3FAD /* clip_macosx64.cpp */; };
|
||||
08C99DA11593E79F00898E41 /* clip_macosx.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0856CE2C14A99EF0000B1711 /* clip_macosx.cpp */; };
|
||||
08CD42DC14B7B85B009CA2A2 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 08CD42DB14B7B85B009CA2A2 /* Cocoa.framework */; };
|
||||
08CD42E814B7B8AA009CA2A2 /* Carbon.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 08CD42E714B7B8AA009CA2A2 /* Carbon.framework */; };
|
||||
/* End PBXBuildFile section */
|
||||
@ -173,6 +174,20 @@
|
||||
remoteGlobalIDString = 0873A53114AAF05A004F12B7;
|
||||
remoteInfo = dyngen;
|
||||
};
|
||||
0885A5391593E4BC005C4F7B /* PBXContainerItemProxy */ = {
|
||||
isa = PBXContainerItemProxy;
|
||||
containerPortal = 0856CCAE14A99DE0000B1711 /* Project object */;
|
||||
proxyType = 1;
|
||||
remoteGlobalIDString = 0885A5201593E3B6005C4F7B;
|
||||
remoteInfo = clip;
|
||||
};
|
||||
0885A53B1593E4BC005C4F7B /* PBXContainerItemProxy */ = {
|
||||
isa = PBXContainerItemProxy;
|
||||
containerPortal = 0856CCAE14A99DE0000B1711 /* Project object */;
|
||||
proxyType = 1;
|
||||
remoteGlobalIDString = 0885A52B1593E47F005C4F7B;
|
||||
remoteInfo = clip64;
|
||||
};
|
||||
/* End PBXContainerItemProxy section */
|
||||
|
||||
/* Begin PBXCopyFilesBuildPhase section */
|
||||
@ -199,6 +214,7 @@
|
||||
0846E52314B129DA00574779 /* ppc_asm.S */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.asm; path = ppc_asm.S; sourceTree = "<group>"; };
|
||||
0846E52814B129EE00574779 /* libppc_asm.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libppc_asm.a; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
0846E55214B12B0D00574779 /* paranoia.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = paranoia.cpp; sourceTree = "<group>"; };
|
||||
0851E9561593E22B00EE3FAD /* clip_macosx64.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = clip_macosx64.cpp; sourceTree = "<group>"; };
|
||||
0856CCC114A99E1C000B1711 /* SheepShaver.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = SheepShaver.app; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
0856CD4B14A99EEF000B1711 /* adb.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = adb.cpp; path = ../adb.cpp; sourceTree = SOURCE_ROOT; };
|
||||
0856CD4C14A99EEF000B1711 /* audio.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = audio.cpp; path = ../audio.cpp; sourceTree = SOURCE_ROOT; };
|
||||
@ -412,6 +428,8 @@
|
||||
0873A76714ABD151004F12B7 /* config.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = config.h; sourceTree = "<group>"; };
|
||||
0873A80014AC515D004F12B7 /* utils_macosx.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = utils_macosx.h; sourceTree = "<group>"; };
|
||||
0873A80114AC515D004F12B7 /* utils_macosx.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = utils_macosx.mm; sourceTree = "<group>"; };
|
||||
0885A5211593E3B6005C4F7B /* libclip.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libclip.a; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
0885A5341593E47F005C4F7B /* libclip64.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libclip64.a; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
08CD42DB14B7B85B009CA2A2 /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = /System/Library/Frameworks/Cocoa.framework; sourceTree = "<absolute>"; };
|
||||
08CD42E714B7B8AA009CA2A2 /* Carbon.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Carbon.framework; path = /System/Library/Frameworks/Carbon.framework; sourceTree = "<absolute>"; };
|
||||
/* End PBXFileReference section */
|
||||
@ -470,6 +488,20 @@
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
0885A51F1593E3B6005C4F7B /* Frameworks */ = {
|
||||
isa = PBXFrameworksBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
0885A5301593E47F005C4F7B /* Frameworks */ = {
|
||||
isa = PBXFrameworksBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
/* End PBXFrameworksBuildPhase section */
|
||||
|
||||
/* Begin PBXGroup section */
|
||||
@ -500,6 +532,8 @@
|
||||
0873A5CC14AB806D004F12B7 /* libppc-dyngen-ops.a */,
|
||||
0846E49A14B124DE00574779 /* libkpx_cpu.a */,
|
||||
0846E52814B129EE00574779 /* libppc_asm.a */,
|
||||
0885A5211593E3B6005C4F7B /* libclip.a */,
|
||||
0885A5341593E47F005C4F7B /* libclip64.a */,
|
||||
);
|
||||
name = Products;
|
||||
sourceTree = "<group>";
|
||||
@ -767,6 +801,7 @@
|
||||
0873A76514ABD151004F12B7 /* config */,
|
||||
0856D2D614A9A704000B1711 /* Launcher */,
|
||||
0856CE2C14A99EF0000B1711 /* clip_macosx.cpp */,
|
||||
0851E9561593E22B00EE3FAD /* clip_macosx64.cpp */,
|
||||
0856CE2D14A99EF0000B1711 /* extfs_macosx.cpp */,
|
||||
0856CE6D14A99EF0000B1711 /* macos_util_macosx.h */,
|
||||
0856CE7014A99EF0000B1711 /* prefs_macosx.mm */,
|
||||
@ -945,6 +980,20 @@
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
0885A51D1593E3B6005C4F7B /* Headers */ = {
|
||||
isa = PBXHeadersBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
0885A52C1593E47F005C4F7B /* Headers */ = {
|
||||
isa = PBXHeadersBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
/* End PBXHeadersBuildPhase section */
|
||||
|
||||
/* Begin PBXNativeTarget section */
|
||||
@ -1018,6 +1067,8 @@
|
||||
0846E52E14B12A2E00574779 /* PBXTargetDependency */,
|
||||
0846E4A714B1253500574779 /* PBXTargetDependency */,
|
||||
082AC26814AA5A4800071F5E /* PBXTargetDependency */,
|
||||
0885A53A1593E4BC005C4F7B /* PBXTargetDependency */,
|
||||
0885A53C1593E4BC005C4F7B /* PBXTargetDependency */,
|
||||
);
|
||||
name = SheepShaver;
|
||||
productName = SheepShaver;
|
||||
@ -1078,6 +1129,40 @@
|
||||
productReference = 0873A5CC14AB806D004F12B7 /* libppc-dyngen-ops.a */;
|
||||
productType = "com.apple.product-type.library.static";
|
||||
};
|
||||
0885A5201593E3B6005C4F7B /* clip */ = {
|
||||
isa = PBXNativeTarget;
|
||||
buildConfigurationList = 0885A5241593E450005C4F7B /* Build configuration list for PBXNativeTarget "clip" */;
|
||||
buildPhases = (
|
||||
0885A51D1593E3B6005C4F7B /* Headers */,
|
||||
0885A51E1593E3B6005C4F7B /* Sources */,
|
||||
0885A51F1593E3B6005C4F7B /* Frameworks */,
|
||||
);
|
||||
buildRules = (
|
||||
);
|
||||
dependencies = (
|
||||
);
|
||||
name = clip;
|
||||
productName = clipboard;
|
||||
productReference = 0885A5211593E3B6005C4F7B /* libclip.a */;
|
||||
productType = "com.apple.product-type.library.static";
|
||||
};
|
||||
0885A52B1593E47F005C4F7B /* clip64 */ = {
|
||||
isa = PBXNativeTarget;
|
||||
buildConfigurationList = 0885A5311593E47F005C4F7B /* Build configuration list for PBXNativeTarget "clip64" */;
|
||||
buildPhases = (
|
||||
0885A52C1593E47F005C4F7B /* Headers */,
|
||||
0885A52D1593E47F005C4F7B /* Sources */,
|
||||
0885A5301593E47F005C4F7B /* Frameworks */,
|
||||
);
|
||||
buildRules = (
|
||||
);
|
||||
dependencies = (
|
||||
);
|
||||
name = clip64;
|
||||
productName = clipboard;
|
||||
productReference = 0885A5341593E47F005C4F7B /* libclip64.a */;
|
||||
productType = "com.apple.product-type.library.static";
|
||||
};
|
||||
/* End PBXNativeTarget section */
|
||||
|
||||
/* Begin PBXProject section */
|
||||
@ -1106,6 +1191,8 @@
|
||||
0873A67314AB8AE9004F12B7 /* ppc-execute-impl */,
|
||||
0846E49914B124DE00574779 /* kpx_cpu */,
|
||||
0846E52714B129EE00574779 /* ppc_asm */,
|
||||
0885A5201593E3B6005C4F7B /* clip */,
|
||||
0885A52B1593E47F005C4F7B /* clip64 */,
|
||||
);
|
||||
};
|
||||
/* End PBXProject section */
|
||||
@ -1277,7 +1364,6 @@
|
||||
0856CFF314A99EF0000B1711 /* extfs.cpp in Sources */,
|
||||
0856CFF414A99EF0000B1711 /* gfxaccel.cpp in Sources */,
|
||||
0856D00914A99EF0000B1711 /* macos_util.cpp in Sources */,
|
||||
0856D02414A99EF0000B1711 /* clip_macosx.cpp in Sources */,
|
||||
0856D02514A99EF0000B1711 /* extfs_macosx.cpp in Sources */,
|
||||
0856D05014A99EF1000B1711 /* prefs_macosx.mm in Sources */,
|
||||
0856D05A14A99EF1000B1711 /* sys_darwin.cpp in Sources */,
|
||||
@ -1363,6 +1449,22 @@
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
0885A51E1593E3B6005C4F7B /* Sources */ = {
|
||||
isa = PBXSourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
08C99DA11593E79F00898E41 /* clip_macosx.cpp in Sources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
0885A52D1593E47F005C4F7B /* Sources */ = {
|
||||
isa = PBXSourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
0885A52F1593E47F005C4F7B /* clip_macosx64.cpp in Sources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
/* End PBXSourcesBuildPhase section */
|
||||
|
||||
/* Begin PBXTargetDependency section */
|
||||
@ -1401,6 +1503,16 @@
|
||||
target = 0873A53114AAF05A004F12B7 /* dyngen */;
|
||||
targetProxy = 0873A62614AB869A004F12B7 /* PBXContainerItemProxy */;
|
||||
};
|
||||
0885A53A1593E4BC005C4F7B /* PBXTargetDependency */ = {
|
||||
isa = PBXTargetDependency;
|
||||
target = 0885A5201593E3B6005C4F7B /* clip */;
|
||||
targetProxy = 0885A5391593E4BC005C4F7B /* PBXContainerItemProxy */;
|
||||
};
|
||||
0885A53C1593E4BC005C4F7B /* PBXTargetDependency */ = {
|
||||
isa = PBXTargetDependency;
|
||||
target = 0885A52B1593E47F005C4F7B /* clip64 */;
|
||||
targetProxy = 0885A53B1593E4BC005C4F7B /* PBXContainerItemProxy */;
|
||||
};
|
||||
/* End PBXTargetDependency section */
|
||||
|
||||
/* Begin PBXVariantGroup section */
|
||||
@ -1504,8 +1616,8 @@
|
||||
INSTALL_PATH = /usr/local/lib;
|
||||
PREBINDING = NO;
|
||||
PRODUCT_NAME = kpx_cpu;
|
||||
SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.5.sdk";
|
||||
"SDKROOT[arch=i386]" = "$(DEVELOPER_SDK_DIR)/MacOSX10.4u.sdk";
|
||||
SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.4u.sdk";
|
||||
"SDKROOT[arch=x86_64]" = "$(DEVELOPER_SDK_DIR)/MacOSX10.5.sdk";
|
||||
};
|
||||
name = Debug;
|
||||
};
|
||||
@ -1673,12 +1785,21 @@
|
||||
0x3000,
|
||||
"-Wl,-seg1addr,0x78048000",
|
||||
"-lkpx_cpu",
|
||||
"-lclip",
|
||||
);
|
||||
"OTHER_LDFLAGS[arch=ppc]" = (
|
||||
"-pagezero_size",
|
||||
0x3000,
|
||||
"-Wl,-seg1addr,0x78048000",
|
||||
"-lppc_asm",
|
||||
"-lclip",
|
||||
);
|
||||
"OTHER_LDFLAGS[arch=x86_64]" = (
|
||||
"-pagezero_size",
|
||||
0x3000,
|
||||
"-Wl,-seg1addr,0x78048000",
|
||||
"-lkpx_cpu",
|
||||
"-lclip64",
|
||||
);
|
||||
PREBINDING = NO;
|
||||
PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
|
||||
@ -1744,7 +1865,7 @@
|
||||
INFOPLIST_PREPROCESS = NO;
|
||||
INSTALL_PATH = "$(HOME)/Applications";
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.4;
|
||||
"MACOSX_DEPLOYMENT_TARGET[arch=x86_64]" = 10.6;
|
||||
"MACOSX_DEPLOYMENT_TARGET[arch=x86_64]" = 10.5;
|
||||
OTHER_CFLAGS = "";
|
||||
OTHER_CPLUSPLUSFLAGS = "$(OTHER_CFLAGS)";
|
||||
OTHER_LDFLAGS = (
|
||||
@ -1752,18 +1873,27 @@
|
||||
0x3000,
|
||||
"-Wl,-seg1addr,0x78048000",
|
||||
"-lkpx_cpu",
|
||||
"-lclip",
|
||||
);
|
||||
"OTHER_LDFLAGS[arch=ppc]" = (
|
||||
"-pagezero_size",
|
||||
0x3000,
|
||||
"-Wl,-seg1addr,0x78048000",
|
||||
"-lppc_asm",
|
||||
"-lclip",
|
||||
);
|
||||
"OTHER_LDFLAGS[arch=x86_64]" = (
|
||||
"-pagezero_size",
|
||||
0x3000,
|
||||
"-Wl,-seg1addr,0x78048000",
|
||||
"-lkpx_cpu",
|
||||
"-lclip64",
|
||||
);
|
||||
PREBINDING = NO;
|
||||
PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
|
||||
PRODUCT_NAME = SheepShaver;
|
||||
SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.4u.sdk";
|
||||
"SDKROOT[arch=x86_64]" = "$(DEVELOPER_SDK_DIR)/MacOSX10.6.sdk";
|
||||
"SDKROOT[arch=x86_64]" = "$(DEVELOPER_SDK_DIR)/MacOSX10.5.sdk";
|
||||
ZERO_LINK = NO;
|
||||
};
|
||||
name = Release;
|
||||
@ -2034,6 +2164,130 @@
|
||||
};
|
||||
name = Release;
|
||||
};
|
||||
0885A5221593E3B6005C4F7B /* Debug */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||
ARCHS = (
|
||||
ppc,
|
||||
i386,
|
||||
);
|
||||
COPY_PHASE_STRIP = NO;
|
||||
GCC_DYNAMIC_NO_PIC = NO;
|
||||
GCC_ENABLE_FIX_AND_CONTINUE = YES;
|
||||
GCC_MODEL_TUNING = G5;
|
||||
GCC_OPTIMIZATION_LEVEL = 0;
|
||||
GCC_VERSION = 4.0;
|
||||
HEADER_SEARCH_PATHS = (
|
||||
/Library/Frameworks/SDL.framework/Versions/A/Headers/,
|
||||
./config/,
|
||||
../Unix,
|
||||
../MacOSX/Launcher,
|
||||
../slirp,
|
||||
../kpx_cpu/src,
|
||||
../kpx_cpu/include,
|
||||
../include,
|
||||
);
|
||||
INSTALL_PATH = /usr/local/lib;
|
||||
PREBINDING = NO;
|
||||
PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
|
||||
PRODUCT_NAME = clip;
|
||||
SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.4u.sdk";
|
||||
};
|
||||
name = Debug;
|
||||
};
|
||||
0885A5231593E3B6005C4F7B /* Release */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||
ARCHS = (
|
||||
ppc,
|
||||
i386,
|
||||
);
|
||||
COPY_PHASE_STRIP = YES;
|
||||
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
|
||||
GCC_ENABLE_FIX_AND_CONTINUE = NO;
|
||||
GCC_MODEL_TUNING = G5;
|
||||
GCC_VERSION = 4.0;
|
||||
HEADER_SEARCH_PATHS = (
|
||||
/Library/Frameworks/SDL.framework/Versions/A/Headers/,
|
||||
./config/,
|
||||
../Unix,
|
||||
../MacOSX/Launcher,
|
||||
../slirp,
|
||||
../kpx_cpu/src,
|
||||
../kpx_cpu/include,
|
||||
../include,
|
||||
);
|
||||
INSTALL_PATH = /usr/local/lib;
|
||||
PREBINDING = NO;
|
||||
PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
|
||||
PRODUCT_NAME = clip;
|
||||
SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.4u.sdk";
|
||||
ZERO_LINK = NO;
|
||||
};
|
||||
name = Release;
|
||||
};
|
||||
0885A5321593E47F005C4F7B /* Debug */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||
ARCHS = "$(ARCHS_STANDARD_64_BIT_PRE_XCODE_3_1)";
|
||||
ARCHS_STANDARD_64_BIT_PRE_XCODE_3_1 = x86_64;
|
||||
COPY_PHASE_STRIP = NO;
|
||||
GCC_DYNAMIC_NO_PIC = NO;
|
||||
GCC_ENABLE_FIX_AND_CONTINUE = YES;
|
||||
GCC_MODEL_TUNING = G5;
|
||||
GCC_OPTIMIZATION_LEVEL = 0;
|
||||
GCC_VERSION = 4.0;
|
||||
HEADER_SEARCH_PATHS = (
|
||||
/Library/Frameworks/SDL.framework/Versions/A/Headers/,
|
||||
./config/,
|
||||
../Unix,
|
||||
../MacOSX/Launcher,
|
||||
../slirp,
|
||||
../kpx_cpu/src,
|
||||
../kpx_cpu/include,
|
||||
../include,
|
||||
);
|
||||
INSTALL_PATH = /usr/local/lib;
|
||||
PREBINDING = NO;
|
||||
PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
|
||||
PRODUCT_NAME = clip64;
|
||||
SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.5.sdk";
|
||||
};
|
||||
name = Debug;
|
||||
};
|
||||
0885A5331593E47F005C4F7B /* Release */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||
ARCHS = "$(ARCHS_STANDARD_64_BIT_PRE_XCODE_3_1)";
|
||||
ARCHS_STANDARD_64_BIT_PRE_XCODE_3_1 = x86_64;
|
||||
COPY_PHASE_STRIP = YES;
|
||||
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
|
||||
GCC_ENABLE_FIX_AND_CONTINUE = NO;
|
||||
GCC_MODEL_TUNING = G5;
|
||||
GCC_VERSION = 4.0;
|
||||
HEADER_SEARCH_PATHS = (
|
||||
/Library/Frameworks/SDL.framework/Versions/A/Headers/,
|
||||
./config/,
|
||||
../Unix,
|
||||
../MacOSX/Launcher,
|
||||
../slirp,
|
||||
../kpx_cpu/src,
|
||||
../kpx_cpu/include,
|
||||
../include,
|
||||
);
|
||||
INSTALL_PATH = /usr/local/lib;
|
||||
PREBINDING = NO;
|
||||
PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
|
||||
PRODUCT_NAME = clip64;
|
||||
SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.5.sdk";
|
||||
ZERO_LINK = NO;
|
||||
};
|
||||
name = Release;
|
||||
};
|
||||
/* End XCBuildConfiguration section */
|
||||
|
||||
/* Begin XCConfigurationList section */
|
||||
@ -2118,6 +2372,24 @@
|
||||
defaultConfigurationIsVisible = 0;
|
||||
defaultConfigurationName = Release;
|
||||
};
|
||||
0885A5241593E450005C4F7B /* Build configuration list for PBXNativeTarget "clip" */ = {
|
||||
isa = XCConfigurationList;
|
||||
buildConfigurations = (
|
||||
0885A5221593E3B6005C4F7B /* Debug */,
|
||||
0885A5231593E3B6005C4F7B /* Release */,
|
||||
);
|
||||
defaultConfigurationIsVisible = 0;
|
||||
defaultConfigurationName = Release;
|
||||
};
|
||||
0885A5311593E47F005C4F7B /* Build configuration list for PBXNativeTarget "clip64" */ = {
|
||||
isa = XCConfigurationList;
|
||||
buildConfigurations = (
|
||||
0885A5321593E47F005C4F7B /* Debug */,
|
||||
0885A5331593E47F005C4F7B /* Release */,
|
||||
);
|
||||
defaultConfigurationIsVisible = 0;
|
||||
defaultConfigurationName = Release;
|
||||
};
|
||||
/* End XCConfigurationList section */
|
||||
};
|
||||
rootObject = 0856CCAE14A99DE0000B1711 /* Project object */;
|
||||
|
1
SheepShaver/src/MacOSX/clip_macosx64.cpp
Symbolic link
1
SheepShaver/src/MacOSX/clip_macosx64.cpp
Symbolic link
@ -0,0 +1 @@
|
||||
../../../BasiliskII/src/MacOSX/clip_macosx64.cpp
|
Loading…
Reference in New Issue
Block a user