Skip to content

CMake for everything that is not an IDE by Cmake's definition.

Notifications You must be signed in to change notification settings

kyrylo-sovailo/retromake

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RetroMake

CMake-like for your favorite text editor!

I love CMake. Unfortunately, it only works with "true" IDEs like Visual Studio, fully ignoring the existence of fancy text editors and not-quite-abandoning other IDEs. RetroMake is here to change that!

Command-line interface

RetroMake has the same command-line interface as CMake except for the -G argument. RetroMake accepts not one entity, but many, and these many entities occupy multiple slots. The standard slots include:

  • Compiler -- compiler and linker (essential)
  • Build system -- build automation system (essential)
  • Text editor -- basic text editor
  • IntelliSense -- syntax highlighting, autocomplete and friends for the text editor
  • Debugger -- debugger for the test editor All slots need to be occupied for a full IDE-like experience. RetroMake's -G parameter is also case-invariant.

RetroMake is aware has following modules built-in:

  1. GCC ✅
  • Occupied slots: compiler
  • Dependencies: none
  1. Clang (alias: llvm) ✅
  • Occupied slots: compiler
  • Dependencies: none
  1. Make (alias: Makefile, Makefiles, Unix makefile, Unix Makefiles) ✅
  • Occupied slots: build system
  • Dependencies: none
  1. Ninja ❌
  • Occupied slots: build system
  • Dependencies: none
  1. VS Code (alias: VSCode, Code, VS Code, Visual Studio Code) ✅
  • Occupied slots: text editor
  • Dependencies: none
  1. VS Codium (alias: VSCodium, Codium, VSCode OSS, VS Code OSS) ✅
  • Occupied slots: text editor
  • Dependencies: none
  1. Clangd ❌
  • Occupied slots: intellisense
  • Dependencies: VS Code or VS Codium
  1. Native Debug (alias: WebFreak, Web Freak) ✅
  • Occupied slots: debugger
  • Dependencies: VS Code or VS Codium
  1. Visual Studio (alias: VS) ❌
  • Occupied slots: compiler, build system, text editor, intellisense, debugger
  • Dependencies: none
  1. Code::Blocks (alias: CodeBlocks) ✅
  • Occupied slots: build system, text editor, intellisense, debugger
  • Dependencies: none When creating a project, you need to specify all desired functionality in the -G parameter, comma-separated. For example:
retromake .. -G 'GCC, Make, Codium, Native Debug'

Dependencies

RetroMake is built with CMake and uses CMake to parse CMakeLists.txt. Right now RetroMake is a mere wrapper around CMake, that hoverer will change with new modules. RetroMake also depends on RapidJSON and RapidXML.

Configuration

RetroMake determines the list of requested modules by going through following priority list:

  1. -G argument
  2. RETROMAKE_REQUESTED_MODULES environmental variable
  3. RETROMAKE_REQUESTED_MODULES entry in ~/.retromake
  4. RETROMAKE_REQUESTED_MODULES entry in /etc/retromake

Contribution

You want to implement your own module? No problem! RetroMake is highly modularized, the new module can be implemented in a fork or added into existing RetroMake installation as a file. In the latter case, your module needs to end with .so and to expose a factory function with the following signature:

extern "C" rm::Module *create_module(const std::string &requested_module);

It also needs to be said that current architecture is not scalable and flexible enough. I don't plan on providing any backwards compatibility for modules for now.

About

CMake for everything that is not an IDE by Cmake's definition.

Resources

Stars

Watchers

Forks