-
Problem with makefile
Hi guys
I have been given some code for a GAs program. It has five main and its all make with just one makefile. The code was originally writtern in the Mac environment. My question is, is it possible in the window environment to use just one makefile to make all five program. If so, could someone please tell me how? I am currently using code::block, but also have access to VSC++ express. I am dying to get these code to compile, so please help
Regards
Grasshopper Esq.
-
So, do you want an explanation of how to change the makefile to produce .exe files for Windows, or an explanation of how you make Code::Blocks projects from a makefile?
--
Mats
-
Hi buddy
Sorry for not explaining properly, basiclly my teacher wants me to find a way to compile the programs using only one makefile, but they are 5 individual programs with 5 independent entry points (main). I was told the syntax and code are slightly different for the make in the window system. I know I can tell the IDE which makefile to use. Maybe i just need to change the details.
Should i post the makefile on the board
Many thanks
Grasshopper Esq.
-
Ok, so assuming these are independent executables, the normal way to do this to have a pseudo-target [which is called something else in Makefile terms] - usually called "all" so that you can type "make all" to get everything you'd expect:
Code:
all: app1 app2
app1: ... dependent files needed by app1
... do stuff to build app1
app2: ... dependent files needed by app2
... do stuff to build app2
I hope this helps.
--
Mats