From GridLAB-D Wiki
(Redirected from Build)
Jump to: navigation, search

Current GridLAB-D Builds

Stable Release - McNary (Version 4.2) 
https://github.com/gridlab-d/gridlab-d/tree/RC4.1
Release Candidate - Navajo (Version 4.3) 
https://github.com/gridlab-d/gridlab-d/tree/RC4.1
Next Release - McNary (Version 4.2) 
https://github.com/gridlab-d/gridlab-d/tree/develop
Trunk - McNary (trunk) 
https://github.com/gridlab-d/gridlab-d/tree/master

Windows

The Windows version should be installed from the latest download build.

MSYS2
The current recommended build process for Windows uses MSYS2.

Linux/Unix

Redhat and MacOSX builds should be downloaded from the latest download build.

Most Linux and Unix system can be built using the standard automake process. If you just want to build the code, it is recommended that you only check out the trunk or one of the branches, as the full repository is very large (over 6GB). The first time you must checkout the source code from the Subversion repository:

cd work
git clone https://github.com/gridlab-d/gridlab-d.git gridlab-d
   ...lots of output...
cd gridlab-d

If you want to checkout a branch instead, you'll need to check out that appropriate branch first. If we wanted to swap to the development branch, use:

git checkout develop

Once you have a working copy checked out, you can build it with the following process (not this will install it as a super-user):

./configure CCFLAGS='-w -O2' CXXFLAGS='-w -O2'
'make -j8'
   ...lots of output...
sudo make install
Password: your password
   ...lots of output...

If you want to check your build, run the validate process

gridlabd.sh -T 0 --validate
   ...lots of output...

Any failures will be reported. Note that the latest version almost always has some validation problems because, almost by definition, a build with validation problems is not released.

Mac OS X

Before you download source code and build, you need to setup your build environment.

The code download procedure is the same as for standard Linux systems:

git clone https://github.com/gridlab-d/gridlab-d.git

This will download the source code of the "master" branch from Github into your current folder.

The build procedure is very similar as for standard Linux systems, but with different CXXFLAGS required (shown in bold below):

cd gridlab-d
git checkout develop
autoreconf -isf
./configure CCFLAGS='-w -O2' CXXFLAGS='-w -O2 -std=c++14 -stdlib=libc++'
make -j8
sudo make install

To run GridLAB-D there are two approaches:

1. Execute the GridlLAB-D binary directly (/usr/local/bin/gridlabd) after setting-up two environment variables:

 export GLPATH=/usr/local/lib/gridlabd:/usr/local/share/gridlabd
 export CXXFLAGS=-I/usr/local/share/gridlabd

2. Call GridLAB-D via the supplied shell script (/usr/local/bin/gridlabd.sh) which sets up the environment for you

Validate the GridLAB-D installation by running

 gridlabd.sh -T 0 --validate

Known Issues

Consult the bug tracker for the current list of known issues.