diff options
author | Norbert Thiebaud <nthiebaud@gmail.com> | 2012-03-25 12:45:24 -0500 |
---|---|---|
committer | Norbert Thiebaud <nthiebaud@gmail.com> | 2012-03-25 12:45:24 -0500 |
commit | e00cb3336f3f6ad802173f90fd93a120b8c95b52 (patch) | |
tree | ae17fec93406e704fbc01d4a9a9b6b77a22a3c7c /solenv/gbuild/Tempfile.mk | |
parent | fd83e6cb19bf20bee89759ca7d70ed667ccd334e (diff) |
use $(file in gbuild when available
Diffstat (limited to 'solenv/gbuild/Tempfile.mk')
-rw-r--r-- | solenv/gbuild/Tempfile.mk | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/solenv/gbuild/Tempfile.mk b/solenv/gbuild/Tempfile.mk index e7e927986298..87f582b6981b 100644 --- a/solenv/gbuild/Tempfile.mk +++ b/solenv/gbuild/Tempfile.mk @@ -1,4 +1,10 @@ # -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*- + +ifeq ($(HAVE_GNUMAKE_FILE_FUNC),YES) +define var2file +$(file >$(1),$(3)) +endef +else # Write string to temporary file by chopping into pieces that # fit the commandline # parameters: filename, maxitems (for one write), string @@ -16,5 +22,6 @@ $(foreach item,$(3),$(eval gb_var2file_curblock += $(item) gb_var2file_curblock := )) endef +endif # vim: set noet sw=4 ts=4: |