On 6/3/2018 21:53, druck wrote:
> On 06/03/18 11:20, Mr. Man-wai Chang wrote:
>> On 6/3/2018 00:23, Ilias Abrams wrote:
>>> Hi guys, can a kindly soul explain to me how I can compile a .c file
>>> with an .asm file together on a RPI 2? I have an assembly file that
>>> I am calling a function through a C code. What I need to do now so I
>>> can combine and compile both files togethe
>>
>> You talking about inline Assembly? You could the ASM compiler directive?
>>
>> Or a makefile including an external ASM source file? The latter
>> scenario needs an external assembly compiler.
>
> The easiest way to do the latter, is to write a C stub for the function
> which you wish to write in assembler, then compile this with gcc -S to
> produce a template asm file with the correct register bindings which you
> can then fill out.
>
> ---druck
I could remember Turbo C for DOS has inline assembly directives. I think
Micro$oft C for DOS had it as well. Not sure about modern Visual C, C++,
C#. Um.. I think you could not do that anymore given the complexities of
Window$.
Anyway, the post mentioned that it's an external file.
--
@~@ Remain silent! Drink, Blink, Stretch! Live long and prosper!!
/ v \ Simplicity is Beauty!
/( _ )\ May the Force and farces be with you!
^ ^ (x86_64 Ubuntu 9.10) Linux 2.6.39.3
借貸!
詐騙!
賭錢!
援交!
打交!
打劫!
自殺!
求神! 請考慮綜援
(CSSA):
http://www.swd.gov.hk/tc/index/site_pubsvc/page_socsecu/sub_addressesa
--- SoupGate-Win32 v1.05
* Origin: Agency HUB, Dunedin - New Zealand | FidoUsenet Gateway (3:770/3)
|