Click to See Complete Forum and Search --> : make and gcc


GeoHoffman49431
March 22nd, 2006, 10:03 PM
Ok I am really bad with linux and compiling my code - ie using make and gcc. This is for a project. I have to have a driver.c file for a program in c, a support.s file in assembly, and there is a support.h file in c.

driver.c -> contains main
support.h -> contains many function prototypes including is_negative(double)
support.s -> contains the implementation of is_negative and others

I cant seem to figure out how to make this project, so that means I cant really work on the main part of it.

Can someone give an example of what would go in each file and how I would create a makefile for it? The idea is how do I call an assembly function in support.s from the main function in driver.c?

The project is to implement a dozen or so functions in assembly but he wants the driver in c so I have no idea.

GeoHoffman49431
March 23rd, 2006, 10:16 AM
never mind - I was not putting .global is_negative in my assembly code so I was having problems. I fixed it now.