Git Product home page Git Product logo

tiki_build's Introduction

tiki_build

Module Extension on top of Premake5 with support for external Git and SVN modules

Getting Started

Place the latest premake_tb executable in the root of your repository.

Now create a premake5.lua file as for Premake. But instead of Premake's functions use the tiki_build classes like in the following Example:

local project = Project:new( "project_name", ProjectTypes.ConsoleApplication )

project:add_files( "src/*.c" )

finalize_default_solution( project )

Modules

You can easily create multiple modules and tiki_build will resolve and combine them together:

  • modules/core/core.lua:
module:add_include_dir( "include" );
module:add_files( "include/**/*.h" )
module:add_files( "src/*.c" )
  • modules/io/io.lua:
module:add_include_dir( "include" );
module:add_files( "include/**/*.h" )
module:add_files( "src/*.c" )
module:add_dependency( "core" )
  • premake5.lua:
add_module_include_path( "modules" )

local project = Project:new( "module_sample", ProjectTypes.ConsoleApplication )
project:add_files( "src/main.c" )
project:add_dependency( "io" )

finalize_default_solution( project )

This sample Project will contain all include and source files from core and io module plus the main.c. The dependency tree will be resolved automatically. Also creates unity build files for every module to speed up build times.

Externals

To import external modules from Git use the add_external function. For Reprositories that already have a tiki.lua nothing more is todo. Otherwise create a import script in your repository with the following rule. Prepend externals/ and remove :/ from URL to get the path:

https://github.com/nlohmann/json.git goes to external/https/github.com/nlohmann/json.git/tiki.lua

An external module behaves like a normal module. You can get additional information about the external from a local variable called: tiki.external.

tiki_build provides some built-in externals:

tiki_build's People

Contributors

irenox avatar

Watchers

 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.