Thanks, Ivan! Do you know of any good documentation on the use of Makevars.in with configure? The @VARNAME@ syntax is quite confusing and isn't explained in WRE from what I can tell.
On Fri, Nov 8, 2024 at 11:33 AM Ivan Krylov <ikry...@disroot.org> wrote: > В Fri, 8 Nov 2024 11:21:16 -0800 > Josiah Parry <josiah.pa...@gmail.com> пишет: > > > I want to conditionally set the value of CRAN_FLAGS like so in my > > Makevars files > > > > ifeq ($(NOT_CRAN), false) > > CRAN_FLAGS = -j 2 --offline > > else > > CRAN_FLAGS = > > endif > > Unless a better approach surfaces (detect the environment variable in > the configure script and generate src/Makevars from src/Makevars.in?), > you may be interested in the following movfuscator-like > POSIX-compatible trick: https://nullprogram.com/blog/2016/04/30/ > > EXTRA_FLAGS_true = > EXTRA_FLAGS_ = -j 2 --offline > EXTRA_FLAGS = $(EXTRA_FLAGS_$(NOT_CRAN)) > > (This one is untested, sorry.) > > -- > Best regards, > Ivan > [[alternative HTML version deleted]] ______________________________________________ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel