FVS Installation instructions

Our Applications and Libraries
FVS

Prerequisites

NOTE: The packages being added are assuming that you're running Ubuntu. Some of these packages may not be available in your package manager repositories.

Useful Documentation (this page serves to fill in gaps)
FVS Unix Build Documentation (has some holes and innacuracies but may still prove useful)

General Software/packages

R Version 4 or greater:

sudo add-apt-repository 'deb https://cloud.r-project.org/bin/linux/ubuntu focal-cran40/'
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E298A3A825C0D65DFD57CBB651716619E084DAB9

Other packages:

sudo apt install gfortran cmake unixodbc-dev libcurl4-gnutls-dev libxml2-dev libgdal-dev libcairo2-dev r-base

R packages (in R cli)

neededPkgs = c("devtools", "shiny", "Cairo", "rhandsontable", "ggplot2", "parallel", "RSQLite", "plyr", "dplyr", "colourpicker", "rgl", "leaflet","zip", "openxlsx", "rgdal", "nlme")

install.packages(neededPkgs)

Building And Running

NOTE: This set of instructions will assume a path of ~/repositories/ for its directory root.

Clone And Build the Repositories:

cd ~/repositories
svn checkout https://svn.code.sf.net/p/open-fvs/code/trunk open-fvs-code
svn checkout svn://svn.code.sf.net/p/open-fvs/code/Rcode/fvsOLtrunk/fvsOL
svn checkout svn://svn.code.sf.net/p/open-fvs/code/Rcode/rFVS

cd open-fvs-code/FVSmodel/trunk/bin
edit the CMakeLists.txt file: Change line 13 from: file(GLOB tobuild FVSiec_sourceList.txt) to: file(GLOB tobuild FVS*sourceList.txt)
cmake -G"Unix Makefiles"

cd ~/repositories/rFVS
make
cd ../fvsOL
make

At this point, everything should be built, and you can launch FVS Online with this command:

R -e "require(fvsOL);fvsOL(fvsBin='~/repositories/open-fvs-code/FVSmodel/trunk/bin/')"