[petsc-dev] Experimental GNU make build system

Jed Brown jedbrown at mcs.anl.gov
Thu May 23 12:11:32 CDT 2013


Satish Balay <balay at mcs.anl.gov> writes:

> posted to cygwin list - but there is a prior similar post. Appears to
> be a windows process launcher issue. :(

If long command-line arguments are the problem, we can use response
files.

http://gcc.gnu.org/wiki/Response_Files

make-3.99.90 has a $file function that makes this convenient:

diff --git i/gmakefile w/gmakefile
index 1577acb..2dfdadd 100644
--- i/gmakefile
+++ w/gmakefile
@@ -56,7 +56,9 @@ allobj := $(foreach pkg, $(pkgs), $(call concatlang,$(pkg)))
 
 # with-single-library=1 (default)
 $(libpetsc_shared) : $(allobj) | $$(@D)/.DIR
-       $(call quiet,CLINKER) -shared -o $@ $^ $(PETSC_EXTERNAL_LIB_BASIC)
+       $(file > $@.args, $^ $(PETSC_EXTERNAL_LIB_BASIC))
+       $(call quiet,CLINKER) -shared -o $@ @$@.args
+       @rm $@.args
 
 # with-single-library=0
 libpkg = $(foreach pkg, $1, $(LIBDIR)/libpetsc$(pkg).so)



Now 'make-git -f gmakefile' works.

git://git.savannah.gnu.org/make.git

It looks like they'll ship make-4.0 soon and we can make this sequence
optional, so you would only need make-4.0 (--download-gmake) on Windows.



More information about the petsc-dev mailing list