[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Recognition of Gzipped files
From: |
Noel Yap |
Subject: |
Re: Recognition of Gzipped files |
Date: |
Thu, 09 Oct 2003 14:55:25 -0400 |
How about:
$(firstword $(wildcard a.file.gz) a.file): b
HTH,
Noel
"Bhatt, Milan C" wrote:
>
> Hi,
>
> I'm looking for a way for make to recognize that a gzipped version of
> the target exists even when the non-zipped version doesn't exist. I
> think the abstract problem I'm trying to solve is in getting make to
> recognize multiple target names as being synonymous.
>
> Here's an example:
>
> a.file.gz a.file : b
> @ some_command
>
> I'd like the behavior of the above rule to be like this:
>
> 1. If the .gz file exists, then a.file.gz becomes the target name.
> 2. If the .gz does NOT exist, then a.file becomes the target name.
>
> The reason I want to have this functionality is to handle the case where
> someone unzips the target file and the .gz file no longer exists.
> Instead of having gmake try to recreate the .gz target, I'd like to have
> it recognize that the unzipped version exists and simply say that the
> target is up to date.
>
> Any ideas on the best way to achieve this?
>
> Thanks,
> Milan
>
> _______________________________________________
> Help-make mailing list
> address@hidden
> http://mail.gnu.org/mailman/listinfo/help-make
--
NOTICE: If received in error, please destroy and notify sender. Sender does
not waive confidentiality or privilege, and use is prohibited.