C++14 standard requested but CXX14 is not defined

Looks like CXX14 might need an additional flag. Can you try running:

cat(c("\n CXX14FLAGS += -mtune=native -O3 -mmmx -msse -msse2 -msse3 -mssse3 -msse4.1 -msse4.2",
      "CXX14 = $(BINPREF)g++ -std=c++1y"),
    file = "~/.R/Makevars.win", sep = "\n", append = FALSE)

Then restarting R and trying the RStan install again?

Hi. I was able to get stan to load and the example to run. For your notes, I got a warning message: In system(paste(CXX, ARGS), ignore.stdout = TRUE, ignore.stderr = TRUE) : ‘C:/Rtools/mingw_/bin/g++’ not found.

Really appreciate the help and quick support.

Is there a updated link for now? I have the same issue but the link does not work anymore.

Hi @andrjohns ,
I’ve tried a few of the suggested fixes, but the issue still occurs when I try to publish my rshiny app to the server. The error is as follows:

Here is some additional information after running the following commands in the R studio console:

image

Two things here. Firstly, you’ve configured your local installation using the steps in the R3.6 guide, not the R4.2 guide. Follow the steps here to remove your old configuration, then follow the steps here for rstan compatibility with R4.2.

However, those steps above will configure your local installation of R. Is your shiny server running from your local machine, or is this a remote server with its own installation of R?

Thank you for your swift reply.
I followed the steps and ran the commands. Here is the output:

My shiny app is on the local machine, and I want to push it to the R Connect server so people in the company can have access to it. The app runs smoothly on my computer.

Also when I press the publish button, when I get the following error when in the deploy panel
Here is a bigger picture of the error:

If your server is not on your local machine, then you should not be following the same instructions - you need to verify which version of R is installed on the R connect server, and then follow the instructions for that version of R on the remote server (that is, execute the commands on the remote server, not on your local machine)

The R Connect version is 1.8.6.2. How can I know what the R version is on the server?
What do you mean by executing the commands on the remote server?
Just briefly explaining my purpose: I have a shiny app which I want to push to the server.
When I just create a simple app using Shiny, I can publish it on the server without any problem. However, this problem arises when I want to publish the more complex shiny app (which used multiple libraries)

Is there any way to find a version of Rstan that does not depend on C++14?
@andrjohns