Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: utzoo!mnetor!uunet!seismo!ut-sally!husc6!bloom-beacon!gatech!emory!platt
From: platt@emory.uucp (Dan Platt)
Newsgroups: comp.lang.c
Subject: Re: Assembly langauge subroutines for use with C
Message-ID: <2182@emory.uucp>
Date: Tue, 21-Jul-87 17:01:58 EDT
Article-I.D.: emory.2182
Posted: Tue Jul 21 17:01:58 1987
Date-Received: Thu, 23-Jul-87 04:37:40 EDT
References: <3647@watdcsu.waterloo.edu>
Reply-To: platt@emory.UUCP (Dan Platt)
Distribution: na
Organization: Math & Computer Science, Emory University, Atlanta
Lines: 23
Keywords: assembly function

In article <3647@watdcsu.waterloo.edu> ryders@watdcsu.UUCP writes:
>How does one go about writing an assembly function that can be linked
>and used by a C program? I have tried several times to get my modules
>to link properly but with the end result of "Unresolved external".
>I have prefaced the function name with an underscore and I still can't
>manage to get my C code to realize that yes, there is an assembly function
>by that name in one of the linked modules. HELP!
>I'm using MSC 4.0 on an IBM-PC AT.
>


From what I can see,  the symbol is unsresolved because it is not
available to the linker.  To make the symbol available to the linker
the symbol must be declared as public.  The examples in the user's
guide show a correct format for making the symbol public.

If you missed the 'public', did you make sure that the memory
model was correct? How about the calling sequence (saving bp,di
and si?) and all the other niggling details?

Hope this is a help...

Dan