POV-Ray : Newsgroups : povray.programming : Atempting MPW Compile ? : Re: Atempting MPW Compile ? Server Time
28 Jul 2024 22:22:27 EDT (-0400)
  Re: Atempting MPW Compile ?  
From: Y Tanabe
Date: 10 May 2000 03:09:35
Message: <39190B32.69B72E3A@kh.rim.or.jp>
Mr. Ryan Mooney or Moon47

If you use my arranging SysMacPict.h and SysMacPict.c,so this may help I
think.
But if you use old SysmacPict.h,c, then you have to modify config.h for
GET_SYS_FILE_HANDLE().
The old SysMacPict can not work continue rendering well.
Would you please understand difference with MacSource and Source folder,
MacSource files are defined by config.h and Source files are defined by
frame.h.

Y.Tanabe
Kobe,Japan

//START

1.)
Replace and add
 sysMacPict.c
 sysMacPict.h

2.)
Add  Boolean  flag to struct file_handle_struct in "FRAME.H"

struct file_handle_struct
{
 char  *filename;
 int  mode;
 int  width, height;
 int  buffer_size;
 char  *buffer;
 FILE  *file;
 int  file_type;  /* What format the output file is */
 int   (*Open_File_p) (struct file_handle_struct *handle,char *name, int
*width, int *height, int buffer_size, int mode);
 void   (*Write_Line_p) (struct file_handle_struct *handle,COLOUR
*line_data, int line_number);
 int   (*Read_Line_p) (struct file_handle_struct *handle,COLOUR
*line_data, int *line_number);
 void   (*Read_Image_p) (IMAGE *Image, char *filename);
 void   (*Close_File_p) (struct file_handle_struct *handle);
//TFC ADD
 Boolean  flag;
};

3.)
File ":MacSource:config.h"; line 379
File ":MacSource:PovMac.h"; line 71
change
#include <MacTypes.h>
 to
#include <Types.h>

File ":MacSource:PovMac.h"; line 88
change
#include <ControlDefinitions.h>
to
//#include <ControlDefinitions.h>

File ":MacSource:DialogUtils.c"; line 901
change
#ifdef __UseNavEventData
 switch(callBackParms->eventData.eventDataParms.event->what)
#else
  switch(callBackParms->eventData.event->what)
#endif
to
//#ifdef __UseNavEventData
// switch(callBackParms->eventData.eventDataParms.event->what)
//#else
  switch(callBackParms->eventData.event->what)
//#endif


File ":MacSource:DialogUtils.c"; line 911
change
#ifdef __UseNavEventData
    pWindow =
(WindowPtr)(callBackParms->eventData.eventDataParms.event->message);
#else
    pWindow = (WindowPtr)(callBackParms->eventData.event->message);
#endif
to
//#ifdef __UseNavEventData
//    pWindow =
(WindowPtr)(callBackParms->eventData.eventDataParms.event->message);
//#else
    pWindow = (WindowPtr)(callBackParms->eventData.event->message);
//#endif

File ":SOURCE:OPTIN.c"; line 1653
add top
#include "sysMacPict.h"
change
 Histogram_File_Handle = GET_SYS_FILE_HANDLE ();
to
 Histogram_File_Handle = Get_MacPICT_File_Handle();

File ":SOURCE:POVRAY.c"; line 1043
add top
#include "sysMacPict.h"
change
 case 'S' : Output_File_Handle = GET_SYS_FILE_HANDLE();
def_ext=SYS_DEF_EXT; break;
to
case 'S' : Output_File_Handle = Get_MacPICT_File_Handle();
def_ext=SYS_DEF_EXT; break;

File ":SOURCE:PARSTXTR.c"; line 162
add top
#include "sysMacPict.h"
change
READ_SYS_IMAGE(Image, Name);
to
Read_MacPICT_Image(Image, Name);

File ":MacSource:DialogUtils.h"; line 116
change
// We don't need prototypes here, they are in Controls.h!
/*
pascal OSErr GetBevelButtonMenuValue(ControlHandle inButton, SInt16
*outValue);
pascal OSErr SetBevelButtonMenuValue(ControlHandle inButton, SInt16
inValue);
pascal OSErr GetBevelButtonMenuHandle(ControlHandle inButton, MenuHandle
*outHandle);
pascal OSErr SetBevelButtonGraphicAlignment(ControlHandle inButton,
ControlButtonGraphicAlignment inAlign, SInt16 inHOffset, SInt16
inVOffset);
pascal OSErr GetImageWellContentInfo(ControlHandle inButton,
ControlButtonContentInfoPtr info);
pascal OSErr SetImageWellContentInfo(ControlHandle inButton,
ControlButtonContentInfoPtr info);
*/
to
// We don't need prototypes here, they are in Controls.h!
pascal OSErr GetBevelButtonMenuValue(ControlHandle inButton, SInt16
*outValue);
pascal OSErr SetBevelButtonMenuValue(ControlHandle inButton, SInt16
inValue);
pascal OSErr GetBevelButtonMenuHandle(ControlHandle inButton, MenuHandle
*outHandle);
pascal OSErr SetBevelButtonGraphicAlignment(ControlHandle inButton,
ControlButtonGraphicAlignment inAlign, SInt16 inHOffset, SInt16
inVOffset);
pascal OSErr GetImageWellContentInfo(ControlHandle inButton,
ControlButtonContentInfoPtr info);
pascal OSErr SetImageWellContentInfo(ControlHandle inButton,
ControlButtonContentInfoPtr info);

File ":MacSource:DialogUtils.c"; line 1048
change
#if !defined(powerc) && !defined (__powerc)
to
//#if !defined(powerc) && !defined (__powerc)

File ":MacSource:DialogUtils.c"; line 1119
change
#endif
to
//#endif

4.)
POV-Ray.make
change

{PovRayMacDir}mpwRsrcs.r
  # Make an XSym (debugging) file
#  {ShowMakeSymProgress}
#  MakeSym {MakeSymOptions} {AppName}.xcoff
  {ShowRezProgress}
  {RezTool} {PovRayMacDir}mpwRsrcs.r -o {Targ} -append
  # Call Thorsten's tool to fix up the application's stack size
  set StackSize 600000
  Echo "# `date -s` ----- Setting App stack size to {StackSize}"
  ChangeAppStack {AppName} -appstack StackSize
  # Set file's creator type, turn on bundle bit, turn off inited bit
  SetFile {Targ} -t APPL -c {AppSignature} -a Bi

to

{PovRayMacDir}mpwRsrcs.r
  # Make an XSym (debugging) file
#  {ShowMakeSymProgress}
#  MakeSym {MakeSymOptions} {AppName}.xcoff
  {ShowRezProgress}
  {RezTool} {PovRayMacDir}mpwRsrcs.r -o {Targ} -append
  # Call Thorsten's tool to fix up the application's stack size
#  set StackSize 600000
#  Echo "# `date -s` ----- Setting App stack size to {StackSize}"
#  ChangeAppStack {AppName} -appstack StackSize
  # Set file's creator type, turn on bundle bit, turn off inited bit
  SetFile {Targ} -t APPL -c {AppSignature} -a Bi

5.)
mpwRsrcs.r
add top
#include "CodeFragmentTypes.r"
#define kDefaultStackSize 307200
add bottom
resource 'cfrg' (0)
{
 {
  kPowerPC,
  kFullLib,
  kNoVersionNum,
  kNoVersionNum,
  kDefaultStackSize,
  kNoAppSubFolder,
  kIsApp,
  kOnDiskFlat,
  kZeroOffset,
  kWholeFork,
  "POV-Ray"
 }
};

//END



Moon47 wrote:

> Last one i hope i almost thought i was done...
> Well only 30 or so more files to go out of a couple hundred...
> Any idea... Why is it trying to "convert" int to what looks like a call
> to some funct? File OPTIN.c.o:
>
> # 5/8/00 11:53:02 PM ----- Building :mpwobj:OPTIN.c.o
> MrC C Compiler 4.1.0f1c1
> Copyright (C) 1994-1999 by Apple Computer, Inc.
>
>              Histogram_File_Handle = GET_SYS_FILE_HANDLE () ;
>                                                             ^
> File ":SOURCE:OPTIN.c"; line 1653 #Error: cannot implicitly convert
> from: (int)
> to  : (struct file_handle_struct *)
> #-----------------------
> ### MPW Shell - Execution of Pov-Ray.makeout terminated.
> ### MPW Shell - Execution of BuildProgram terminated.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.