Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!timbuk!cs.umn.edu!quest!orbit!kksys!jhereg!andrew From: andrew@jhereg.osa.com (Andrew C. Esh) Newsgroups: comp.sys.mac.programmer Subject: Re: undefined __MAIN (MacApp 2.0, C++ 3.1, MPW 3.2b8) Message-ID: <1991Feb18.002215.16373@jhereg.osa.com> Date: 18 Feb 91 00:22:15 GMT References: Distribution: na Organization: Open Systems Architects, Inc., Mpls, MN Lines: 34 In article scotth@rocco.labs.tek.com (Scott Herzinger) writes: ... > >I've just gotten back into a MacApp/C++ project. MABuild has started >to terminate due to a linker error, complaining that I haven't provided >an entry point and that __MAIN isn't defined. This started after I first >used MPW Shell 3.2b8 and the interfaces on the System 6.0 beta CD. But >the problem doesn't go away when I switch back to MPW 3.1. > ... > >Any clues as to what I've broken? > >Scott Herzinger scotth%crl.labs.tek.com@relay.cs.net > Computer Research Lab, Tektronix, Inc. > PO Box 500 MS 50-662, Beaverton, OR 97077 I ran into this problem about a year ago. It had to do with an interaction between the C++ compiler, and the MPW Linker. I don't happen to remember the exact cause, but I do remember that you can see it happen very plainly if you turn on all the Symbol table dumping in the Linker and the compiler. The symbol table entry for "main" is being overwritten. As I remember it, I either did some massive rearrangement of the amount of memory allocated for MPW under Multifinder, and within MPW I changed the amont of stack space, and such. I also turned off some of the symbol file preloading. I may also have backed up to the previous version of the compiler, or linker. Sorry I can't be more specific, but it was a year ago, and there were so many problems going on at the time that we were reconfiguring the entire development environment on a daily basis. -- Andrew C. Esh Open Systems Architects, Inc. (612)525-0000 andrew@osa.com previously: andrew!drum!gong!bangyerdead