I have an assembly function like so
rfact: pushl %ebp movl %esp, %ebp pushl %ebx subl $4, %esp movl 8(%ebp), %ebx movl $1, %eax cmpl $1, %ebx jle .L53 leal -1(%ebx), %eax movl %eax, (%esp) call rfact imull %ebx, %eax .L53: addl $4, %esp popl %ebx popl %ebp ret I understand I can't just save this as rfact.s and compile it. There has to be certain items (such as .text) appended to the top of the assembly. What are these for a linux system? And I'd like to call this function from a main function written in normal c file called rfactmain.c