Re: gar pitfall
- From: "Joseph E. Sacco, Ph.D." <joseph_sacco comcast net>
- To: garnome-list <garnome-list gnome org>
- Cc: Michael Hohn <mhhohn lbl gov>
- Subject: Re: gar pitfall
- Date: Mon, 09 Oct 2006 20:18:48 -0400
Michael,
Kindly submit your posts to the GARNOME mailing list so you can share
your findings with other GARNOME users.
As for your suggested workaround... If you had removed the question
marks, the problem would have gone away.
-Joseph
======================================================
On Mon, 2006-10-09 at 15:57 -0700, Michael Hohn wrote:
> Hi,
>
> I've been using the gar build system (garnome), and ran into a very
> nasty trap:
> my officemate had WORKDIR set in his environment, and a
>
> make clean
>
> wiped a lot of his data...
>
> The problem is in gar.mk, namely the lines
>
> GARDIR ?= ../..
> FILEDIR ?= files
> DOWNLOADDIR ?= download
> PARTIALDIR ?= $(DOWNLOADDIR)/partial
> COOKIEROOTDIR ?= cookies
> COOKIEDIR ?= $(COOKIEROOTDIR)/$(DESTIMG).d
> WORKROOTDIR ?= work
> WORKDIR ?= $(WORKROOTDIR)/$(DESTIMG).d
> WORKSRC ?= $(WORKDIR)/$(DISTNAME)
> EXTRACTDIR ?= $(WORKDIR)
> SCRATCHDIR ?= tmp
> CHECKSUM_FILE ?= checksums
> MANIFEST_FILE ?= manifest
> LOGDIR ?= log
>
> which I have replaced with (the rather tedious)
>
> #
> # Suppress environment variables, especially those used in clean:
> #
> ifeq ($(origin GARDIR), environment)
> GARDIR = ../..
> else
> GARDIR ?= ../..
> endif
>
> ifeq ($(origin FILEDIR), environment)
> FILEDIR = files
> else
> FILEDIR ?= files
> endif
>
> ifeq ($(origin DOWNLOADDIR), environment)
> DOWNLOADDIR = download
> else
> DOWNLOADDIR ?= download
> endif
>
> ifeq ($(origin PARTIALDIR), environment)
> PARTIALDIR = $(DOWNLOADDIR)/partial
> else
> PARTIALDIR ?= $(DOWNLOADDIR)/partial
> endif
>
> ifeq ($(origin COOKIEROOTDIR), environment)
> COOKIEROOTDIR = cookies
> else
> COOKIEROOTDIR ?= cookies
> endif
>
> ifeq ($(origin COOKIEDIR), environment)
> COOKIEDIR = $(COOKIEROOTDIR)/$(DESTIMG).d
> else
> COOKIEDIR ?= $(COOKIEROOTDIR)/$(DESTIMG).d
> endif
>
> ifeq ($(origin WORKROOTDIR), environment)
> WORKROOTDIR = work
> else
> WORKROOTDIR ?= work
> endif
>
> ifeq ($(origin WORKDIR), environment)
> WORKDIR = $(WORKROOTDIR)/$(DESTIMG).d
> else
> WORKDIR ?= $(WORKROOTDIR)/$(DESTIMG).d
> endif
>
> ifeq ($(origin WORKSRC), environment)
> WORKSRC = $(WORKDIR)/$(DISTNAME)
> else
> WORKSRC ?= $(WORKDIR)/$(DISTNAME)
> endif
>
> ifeq ($(origin EXTRACTDIR), environment)
> EXTRACTDIR = $(WORKDIR)
> else
> EXTRACTDIR ?= $(WORKDIR)
> endif
>
> ifeq ($(origin SCRATCHDIR), environment)
> SCRATCHDIR = tmp
> else
> SCRATCHDIR ?= tmp
> endif
>
> ifeq ($(origin CHECKSUM_FILE), environment)
> CHECKSUM_FILE ?= checksums
> else
> CHECKSUM_FILE ?= checksums
> endif
>
> ifeq ($(origin MANIFEST_FILE), environment)
> MANIFEST_FILE ?= manifest
> else
> MANIFEST_FILE ?= manifest
> endif
>
> ifeq ($(origin LOGDIR), environment)
> LOGDIR = log
> else
> LOGDIR ?= log
> endif
>
> You may want to make a similar adjustment.
>
> Cheers,
> Mike
--
joseph_sacco [at] comcast [dot] net
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]