As we know.. in the appliance when we use the command..
. make [file-name] ..
It automatically complied with some flag....-ggdb -O0 -std=c99 -Wall - Werror
But I need to know in which directory the CS50 edited Makefile is located???
Because I wanna configure my own Makefile for entire system by which I can make any .cpp file..
I am greatly in need of that ..
Please suggest some suggestions...
Becuase when I compile c++ file with make it automatically compiles with g++ but I want to compile .cpp file with clang++ compiler...adding some essential fiag.. such for -g for debugging -O0 for assembly code..
..So I know to create a Makefile for that specific reason if possible..
1 Answer
make
is a utility that finds a specified file on the disk, and then executes the commands in it. The default behaviour can be altered by creating your own file, say qwerty
. Now go the corresponding directory and run
make -f qwerty
on terminal to override the default file execution with the one explicitly provided.