GithubHelp home page GithubHelp logo

templatepremakestaticlib's Introduction

Premake5 template project for multi-static library

This project is to combine several lib to one library. They will be collected inside the same library. Sometimes you need to collect several vendor libraries in one file. This was quite difficult and I couldn't find any info about that on the net. I even asked the question at
https://stackoverflow.com/questions/77756685/static-library-that-dependency-on-another-static-libray-linux-undefined but without any answer.

Project structure

1-There is a workspace lua file that will create the solution and is the head of the whole solution/make files

2-Application lua which generates an executable file. That project is depending on the library (PPCL) which depends on pathLib'

3-Pathlib is the library that is simulating vendor library. It will be incldued after compilation in the PPCL.lib or libPPCL.a

Compiling the project:

Create the project by running the following command :

premake5 gmake2  ---LINUX

Premake5 VS2022  ---Windows.

To remove previously generated make files and solutions , run the following command:

call premake5.exe clean

Feel free to contribute and suggest changes to this project. I hope you find it useful.

Notes:

There are certan formats that you MUST keep to allow this project work. For example when I used this filter:

filter "system::Unix"

    system "linux" 

This causes a problem. The generated make file get a configuration of "debug/" folder without your intention. Remember also, lua is not pythont language. Just having some spaces (indentation) doesn't mean that the filter will not be applied for that line or section. Keep those lines before the filters. There is a note inside one of the lua files about that.

Project Structure :

.
├── PPCL
│   ├── premake5.lua
│   ├── src
│   │   ├── ppcl_lib.cpp
│   │   └── ppcl_lib.h
│   └── vendor
│       └── pathLib
│           ├── premake5.lua
│           └── src
│               ├── fr_path.cpp
│               └── fr_path.h
├── TemplatePreemakeStaticLIB
│   ├── premake5.lua
│   └── src
│       ├── Application.cpp
│       └── Application.h
├── Resources
├── premake5.lua
├── BuildProjects.bat
└── README.md

Mariwan Jalal

templatepremakestaticlib's People

Contributors

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