GithubHelp home page GithubHelp logo

changgang / gridlab-d Goto Github PK

View Code? Open in Web Editor NEW

This project forked from gridlab-d/gridlab-d

0.0 0.0 0.0 422.79 MB

Source Code for GridLAB-D

License: Other

Shell 0.14% JavaScript 0.33% C++ 51.33% Python 5.56% Perl 0.19% C 3.24% PHP 0.04% Java 1.75% R 0.01% MATLAB 27.74% PowerShell 0.01% Awk 0.06% XSLT 2.90% CSS 0.13% Gnuplot 0.01% Mathematica 1.05% Hack 0.01% Makefile 0.57% HTML 4.55% CMake 0.40%

gridlab-d's Introduction

Building GridLAB-D

Prerequisites

CMake
CCMake or CMake-gui (optional)
g++ or Clang

Installation

Git

Clone the git repository for GridLAB-D and update submodules:

git clone https://github.com/gridlab-d/gridlab-d.git
cd gridlab-d
git submodule update --init

Prepare out-of-source build directory

Create build directory and move into it:

mkdir cmake-build
cd cmake-build

Generate the build system

CMake flags can be added using the -D prefix, and different build systems can be selected using -G.

Below is a general format guide, and an actual viable build command for most platforms.

# Format:
cmake <flags> ..

# Full Example: 
cmake -DCMAKE_INSTALL_PREFIX=~/software/GridLAB-D -DCMAKE_BUILD_TYPE=Release -G "CodeBlocks - Unix Makefiles" ..

Build and install the application

CMake can directly invoke the build and install process by running the below command. Multiprocess build is enabled through the -j# flag (-j8 in the included example).

# Run the build system and install the application
cmake --build . -j8 --target install

CMake Variables

The following variables affect the build process and can be changed using the -D flag at build generation or by updating the cache using ccmake or cmake-gui (default values are shown).

Variable Valid Values Description Linux/Mac Default Windows Default
CMAKE_BUILD_TYPE 'Debug', 'RelWithDebInfo', 'MinSizeRel', 'Release' Compiler optimizer configuration Debug Debug
CMAKE_INSTALL_PREFIX Any path Install location /usr/local %ProgramFiles%
GLD_USE_HELICS ON/OFF Enables detection and use of HELICS OFF OFF
GLD_HELICS_DIR Any path Hint indicating HELICS install directory
GLD_USE_MYSQL ON/OFF Enables detection and use of MySQL OFF OFF
GLD_MYSQL_DIR Any path Hint indicating MySQL install directory
GLD_DO_CLEANUP ON/OFF Remove files from old GridLAB-D build processes OFF OFF

Enable building with HELICS

To enable HELICS set the GLD_USE_HELICS flag to ON if HELICS is in a custom path set GLD_HELICS_DIR to the install location in CMake or as an environmental variable

Enable building with MySQL

To enable MySQL support set the GLD_USE_MYSQL flag to ON if MySQL is in a custom path set GLD_MYSQL_DIR to the install location in CMake or as an environmental variable

Enable build debugging

To output all build commands during build, set following flag to ON

CMAKE_VERBOSE_MAKEFILE=OFF 

gridlab-d's People

Contributors

dchassin avatar ftuffner avatar afisher1 avatar jcfuller1 avatar eberleim avatar ntenney avatar temcdrm avatar trevorhardy avatar kevinpschneider avatar kevinatkinson-pnnl avatar d3j331 avatar nikhilgupta10 avatar sjinpnnl avatar priyatm62 avatar huangrenke avatar bilalahmad-bhatti avatar jacobhansens avatar chenyousu avatar blthayer avatar weidu276 avatar laurmarinovici avatar lauraleist avatar kadecornelison avatar areiman avatar phlptp avatar xcosmos6 avatar mumonish avatar sarmad-hanif avatar singha42 avatar d3k205 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.