Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!hao!ames!ucbcad!ucbvax!hplabs!hpcea!hpsrla!hpsrlc!darrylo From: darrylo@hpsrlc.HP.COM (Darryl Okahata) Newsgroups: comp.lang.c Subject: Re: TURBO C Linking Problem Message-ID: <3400009@hpsrlc.HP.COM> Date: Fri, 13-Nov-87 11:25:22 EST Article-I.D.: hpsrlc.3400009 Posted: Fri Nov 13 11:25:22 1987 Date-Received: Sun, 15-Nov-87 17:43:17 EST References: <2293@watcgl.waterloo.edu> Organization: HP Network Measurements Div - Santa Rosa, CA Lines: 36 In comp.lang.c, jsin@CS.UCLA.EDU writes: > I also have a problem linking under TC. I have one file with few procedures, > and the program compiles ok. But when I link the .OBJ file to get .EXE file, > the Linker gives me "module _main unresolved" or some such nonsense. > Of course, main() is in my file and it compiles and runs fine using other > compilers, such as Mark Williams C compiler(I can't afford MSC). > > I did get TC to link it using the TLINK (command line linker) finally. > Is this a known bug? Or did I do something wrong? > > Thanks to all who respond. > John > > > John (Jonghoon) Sin > UCLA SEASnet Facilities ARPA: jsin@seas.ucla.edu > 2567 Boelter Hall BITNET: jsin%seas.ucla.edu@wiscvm.wisc.edu > Los Angeles, CA. 90025 UUCP: ...!{ihnp4,ucbvax,{hao!cepu}}!ucla-cs!jsin > (213) 206-6864 > ---------- Did you tell Turbo C to NOT prepend an underscore ("_") to a name? Normally (i.e., the default action), the compiler prepends underscores to a name and stores these modified names in the .OBJ file. I can't remember the exact details, but, in the integrated environment, there is a compiler switch (and possibly also a linker switch) under the "Options" menu. Make sure that it (they?) are set correctly. -- Darryl Okahata {hplabs!hpccc!, hpfcla!} hpsrla!darrylo CompuServe: 75206,3074 Disclaimer: the above is the author's personal opinion and is not the opinion or policy of his employer or of the little green men that have been following him all day.