delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2005/08/13/20:16:42

X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f
Message-ID: <BAYC1-PASMTP0265DA8988815A0C8BFDBFEFBE0@cez.ice>
X-Originating-IP: [70.50.143.121]
X-Originating-Email: [april_white AT sympatico DOT ca]
Message-ID: <42FE8D52.8010808@sympatico.ca>
Date: Sat, 13 Aug 2005 20:16:18 -0400
From: April White <april_white AT sympatico DOT ca>
User-Agent: Mozilla Thunderbird 1.0.2 (Windows/20050317)
X-Accept-Language: en-us, en
MIME-Version: 1.0
To: djgpp AT delorie DOT com
Subject: Re: help with a makefile
References: <BAYC1-PASMTP04FFD175CA69D34F67F6B1EFBF0 AT cez DOT ice>
In-Reply-To: <BAYC1-PASMTP04FFD175CA69D34F67F6B1EFBF0@cez.ice>
X-OriginalArrivalTime: 14 Aug 2005 00:16:20.0107 (UTC) FILETIME=[6544B5B0:01C5A065]
Reply-To: djgpp AT delorie DOT com

April White wrote:

> I am trying to set up a Makefile so that I may compile my c++ code 
> using DJGPP and MingW into sub-folders, using the environment variable 
> ENV to hold the target name
> ...
> Can someone give me assistance with this?

I'm not sure if it is a standard environment, but I found a solution 
that works for me.

The parent folder Makefile detects if the MAKELEVEL is zero and defines:
    all:
        make -C $(ENV)
When MAKELEVEL is greater than zero, I have the usual targets.

Then in each sub-folder I created a Makefile:
    include ../Makefile

And viola., everything works like I want. 

April

-- 
There are certain things men must do to remain men.
James T. Kirk, 'The Ultimate Computer', stardate 4929.4

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019