[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
ifeq and ifneq and/or help
From: |
PATTON, BILLY \(SBCSI\) |
Subject: |
ifeq and ifneq and/or help |
Date: |
Wed, 29 Mar 2006 07:47:00 -0600 |
I need to make some decision on how to load some files.
I have 6 flows: build, refresh, linktree, clean, depend and product
I have 6 files: make.<flow> that contain foreach loop that use evals to
create targets on the fly.
Loading the 6 files takes just a little more than 10 minutes. They
create 72k + targets. Not all these targets are necessary.
Examples of make and what they need
make < needs build linktree and product
make build < needs build
make refresh < needs build and refresh
make clean < needs clean
make depend < needs build linktree depend
make linktree < needs build linktree
make anything that doesn't begin with the named 6 needs build refresh
and product
it is possible to do a
make build+ldb+bb+topic < needs build
make ldb < needs build refresh and product
Since I have been unable to get the gmsl or to function as the examples
are I need to do the and/or in another method. This is where I need
help. I don't want to load the file multiple times.
So what I need is
ifneq (,$(findstring build,$(MAKECMDGOALS)))
include make.build
endif
ifneq (,$(MAKECMDGOALS) is empty)
include make.build
include make.refresh
include make.prod
endif
Or could I:
ifneq (,$(findstring build,$(MAKECMDGOALS)))
include make.build
else
ifneq (,$(findstring refresh,$(MAKECMDGOALS)))
include make.build
include make.refresh
else
ifneq (,$(findstring clean,$(MAKECMDGOALS)))
include make.clean
else
ifneq (,$(findstring depend,$(MAKECMDGOALS)))
include make.build
include make.linktree
include make.depend
else
ifneq (,$(findstring linktree,$(MAKECMDGOALS)))
include make.build
include make.linktree
else
include make.build
include make.linktree
include make.product
endif
endif
endif
endif
endif
As long as just one at a time is done I think this would work.
But if I told it to do a clean and refresh this would not work.
Just tried this before I emailed this. It does work, but would prefer
to bee able to have and/or type constructs to include files for
combinations on the make command line.
- ifeq and ifneq and/or help,
PATTON, BILLY \(SBCSI\) <=