Skip to content

Instantly share code, notes, and snippets.

@aykutbulut
Last active January 10, 2017 13:39
Show Gist options
  • Save aykutbulut/c51ecc902f42a7b804e704ed925e93ba to your computer and use it in GitHub Desktop.
Save aykutbulut/c51ecc902f42a7b804e704ed925e93ba to your computer and use it in GitHub Desktop.
basic makefile
CC=g++
PROGNAME=c_solver
INCLUDES=
CFLAGS=-g -Wall
LDFLAGS=
LIBS=
OBJECTS=solverA.o\
solverB.o\
solverC.o
all: $(PROGNAME)
$(PROGNAME): $(OBJECTS)
$(CC) -o $(PROGNAME) $(OBJECTS) $(LDFLAGS) $(LIBS)
$(OBJECTS): Makefile
.cpp.o:
$(CC) -c $(CFLAGS) $(INCLUDES) -o $@ $<
clean:
rm *.o $(PROGNAME)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment