Giter Club home page Giter Club logo

sconsx's Introduction

https://travis-ci.org/openalea/sconsx.svg?branch=master https://ci.appveyor.com/api/projects/status/loch8jmjco4aagk5/branch/master?svg=true

SConsX

SConsX is a package of the OpenAlea project.

About

SConsX is an extension package of the famous SCons build tool. SConsX aims to simplify the build of complex multi-platform packages (i.e. using C++, Boost.Python and Python).

Like Boost.Jam or qmake, it knows about different types of compiler, and the different steps involved in compiling for Windows and Linux. This knowledge allows the user to describe what needs to be built in high-level terms, without concern for low-level details such as the compiler's specific flags, the way that the operating system handles dynamic libraries. The goal is to be able to write a single, simple, build description (SConsctruct and SConscript ) that is likely to work for several compilers on Linux and Windows. It also has built-in support for variant builds ( e.g.debug, release), options (e.g. include paths and threading options) and dependencies associated with the usage of particular libraries. The build objects are created in a separate build directory, not in the source directory.

SConsX extend SCons by adding knowledge to existing tools that are system dependent (e.g. default options and path, dependencies between tools). All the internal options can be overwited in an external configuration file (named option.py). For each tools, SConsX add also configuration capabilities that mimic autoconf functionalities.

SConsX is just a thin wrapper over SCons. It's easily extendible. You can add new tools as well as new high-level commands.

SConsX is under development. Lot of work have to be done for a better support of new compiler (e.g. Visual C++, mingw), new tools and new functionalities.

Description

SconsX provides a set of tools with default options, configurations and dependencies.

Each tool provides:
  • A set of options with default values dependeing on the OS.
  • A list of dependecies. For instance, Boost.Python depends on Python.
  • A configuration method that use SConf, the configuartion tool used by SCons.
  • An update method that update the SCons environment with specific flags.
Available tools are limited but can be easily extended :
  • compiler: Define a set of generic flags (e.g. debug or warning) for compilers on various OS.
  • builddir: Define a build directory for build objects and sub directories for header files, lib and bin files created during the build.
  • install: Define install directories used during the install stage, i.e. exec and exec_prefix, libdir, bindir and includedir as well as datadir.
  • Other tools: OpenGL, QT, bison, flex, Boost.Python, ...

Quick Example

This is a SConstruct file. See the Scons documentation for more information.

import sconsx
from sconsx import config

# Creation of a SCons object
# Set an option file as well as command line args.
option= Options("options.py", ARGUMENTS)

# Creation of a SConsX object
conf = config.Config([ 'install', 'boost.python', 'qt'])

# Update the SCons option with the default settings of each tools
conf.UpdateOptions( options )

# Creation of the Scons Environment
env= Environment( options= option )

# Update the environment with specific flags defined by SConsX and the user.
conf.Update( env )

SConscript(...)

Installation

Download

SConsX is available on github.

Requirements

There are two requirements:

Installation

Extract the tarball, jump into the created directory and run :

python setup.py install

For installation options, see :

python setup.py install --help

sconsx's People

Contributors

pradal avatar fredboudon avatar cokelaer avatar dbarbeau avatar gbaty avatar pfernique avatar christian34 avatar ethan13310 avatar ricomos avatar jpeyhardi 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.