Code Monkey home page Code Monkey logo

ahundt / cmake-basis Goto Github PK

View Code? Open in Web Editor NEW

This project forked from cmake-basis/legacy

0.0 3.0 0.0 15.11 MB

The CMake Build system And Software Implementation Standard (BASIS) documents and implements a standard for project organization, software build using CMake, and software implementation and documentation. This standard was founded and established 2011 at the Section of Biomedical Image Analysis, Department of Radiology, University of Pennsylvania.

Home Page: http://opensource.andreasschuh.com/cmake-basis/

License: Other

C++ 49.71% Objective-C 0.04% Python 22.63% Shell 2.98% MATLAB 0.03% Perl 7.96% C 15.58% CSS 0.48% PHP 0.26% Java 0.33%

cmake-basis's Introduction

Section of Biomedical Image Analysis
Department of Radiology
University of Pennsylvania
3600 Market Street, Suite 380
Philadelphia, PA 19104

Web: http://www.rad.upenn.edu/sbia/
Email: sbia-software at uphs.upenn.edu

Copyright (c) 2011, 2012, University of Pennsylvania. All rights reserved.
See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file.

INTRODUCTION

The Build system And Software Implementation Standard (BASIS) software package documents and implements the lab's standard for project organization, software build, and software implementation and documentation. The BASIS project was started in February 2011. The initial idea was only to provide a project template based on CMake which would standardize the project directory structure as well as the software build. Besides, this project template would allow the developers to concentrate on the actual software rather than on deciding upon the directory structure, the directory names, and the basic CMake configuration. To provide an even more comprehensive basis for the software development at SBIA, the BASIS project goes, however, two steps further.

In first place, BASIS has to be considered as a standard regarding the software development at SBIA which is documented as part of the Software Manual. Based on this standard, a project template is provided which implements the Filesystem Hierarchy Standard. This template is further accompanied by CMake modules which not only follow the Filesystem Hierarchy Standard, but also implement the build system standard as well as the standard on testing and packaging software developed at SBIA.

The BASIS package moreover provides basic utility functions for each supported programming language which implement certain aspects of the software implementation standard such as, for example, the calling conventions on how to execute subprocesses and the parsing of command-line arguments. Where possible, these utility implementations were adopted from other open source software projects and integrated with BASIS. For a more detailed overview of the BASIS package, see sections COMPONENTS and PACKAGE OVERVIEW.

Every SBIA software project which was started after the first release of BASIS in November 2011 is required to built on top of BASIS, i.e., to instantiate the project template, utilize the provided CMake implementations and follow the software implementation standard. An extensive documentation is provided with BASIS to ease this task as much as possible. See section DOCUMENTATION for a summary of the available documentation.

The BASIS package, when built and installed once on a target system on which other SBIA software is to be built, is used for the build of these dependent SBIA projects. Alternatively, if the package is not found, each SBIA project which is built on top of BASIS and implements the super-build feature, retrieves and builds a local copy using CMake's ExternalProject.cmake module This super-build methodology, which gains more and more attraction in the CMake community, is further utilized by BASIS to not only ease the development and maintenance of separately managed software projects, but also enable the fusion of these more or less independently developed software packages into so-called superprojects. In this context, the separately managed software packages are considered components of the superproject. TODO: The super-build methodology is not yet implemented as part of BASIS!

Besides the super-build of BASIS projects, BASIS provides an implementation of a tighter coupling of software components. Here, the top-level project (i.e., the superproject) contains other BASIS projects as modules, and these modules define the dependencies to other modules of the project. When the superproject is configured, a subset of these modules can be selected and only these will be build and installed. This type of modularization closely follows the modularization approach of the ITK 4 project.

COMPONENTS

Project Template

Every project that wants to follow BASIS has to be derived from the Software Project Template. For convenience, the command-line tool basisproject for the creation of a new project and the modification of such created BASIS project is provided. This tool automates and thus simplifies the instantiation of the project template for new projects. See this how-to guide for details on how to use the basisproject command-line tool to create or modify a project.

CMake Modules

The CMake modules and corresponding auxiliary files are not only used by the BASIS package itself, but also any SBIA project which follows BASIS for the configuration of the CMake-based build system. These CMake modules in particular define many functions which are used as replacement of CMake's built-in functions. For example, the function basis_add_executable() is used by BASIS projects as replacement for CMake's add_executable() command. The BASIS CMake functions are convenient to use, extend the functionality of CMake's built-in functions, and enable BASIS to impose its standard on the configured build system.

The main CMake modules are:

A comprehensive documentation of these modules and the functions and macros defined by them is available as part of the reference documentation.

Tools

In order to ease certain tasks, the BASIS package also includes the following command-line tools:

  • basisproject: Creates a new project or modifies an already previously created project in order to add or remove certain components of the project template or to upgrade to a newer BASIS template. See this how-to guide for more information.
  • basistest: Implements automated software tests. See this how-to guide on how to setup automated software test using these command-line tools.
  • doxyfilter: Doxygen filters for the supported programming languages.

Utilities

For each supported programming language, BASIS provides a library of utility functions. Some of these utility functions are project independent and thus built and installed as part of BASIS itself. Other utility implementations are project dependent. Therefore, the BASIS package provides only template files which are customized and built during the configuration and build, respectively, of the particular BASIS project. This customization is done by the functions implemented by the UtilitiesTools.cmake module which is included and utilized by the main BasisTools.cmake module.

The BASIS utilities address the following aspects of the software implementation standard:

PACKAGE OVERVIEW

Source Package

  • BasisProject.cmake: Meta-data used by BASIS to configure the project.
  • CMakeLists.txt: Root CMake configuration file.
  • config/: Package configuration files.
  • data/template-<version>/ Project template(s).
  • doc/: Documentation source files of BASIS.
  • include/: Public header files.
  • src/: Source code files.
  • src/cmake/: CMake implementations and corresponding auxiliary files.
  • src/geshi/: A language file written in PHP for the use with GeSHi, a source code highlighting extension for MediaWiki.
  • src/sphinx/: Themes and extensions for the Sphinx documentation tool.
  • src/tools/: Source code of command-line tools.
  • src/utilities/: Source code of utility functions.
  • test/: Tests of the implementations in src/.
  • AUTHORS: A list of the people who contributed to this sofware.
  • COPYING: The copyright and license notices.
  • INSTALL: Build and installation instructions.
  • README: This readme file.

Binary Package

Please refer to the INSTALL file for details on where the built executables and libraries, the auxiliary data, and the documentation files are installed.

LICENSING

See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file.

INSTALLATION

See build and installation instructions given in the INSTALL file.

DOCUMENTATION

The PowerPoint 2007 presentation named BASIS Tutorial - 01 Introduction.pptx gives a more detailed and in parts visual introduction of the BASIS project. It can be found in the doc/tutorials/ directory of the BASIS package. Further tutorials can be found here as well.

See the BASIS Web Site for details on the build system and implementation standard. How-to guides found on this page further help to comply with BASIS.

The API documentation here, on the other side, is a great reference of the CMake implementations, whereas a reference of the utility functions available for the different supported programming languages can be found on this page.

cmake-basis's People

Contributors

schuhschuh avatar

Watchers

 avatar  avatar  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.