Project source tree.

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
sandras
Member
Member
Posts: 146
Joined: Thu Nov 03, 2011 9:30 am

Project source tree.

Post by sandras »

My project is still very fresh so I'm thinking of how should the source tree be laid out. The directories should be logically placed and I don't think there should be too many levels, as it makes the navigation more difficult. I think I have to decide on the directory layout now, when there's still a small amount of files in the tree, as later, when there will be more files, it might be more difficult to change it.

So what does your project source tree look like?

For now, mine is like this.

build/
src/arch/x86-32/
src/include/
src/port/
tool/
Last edited by sandras on Sun Nov 06, 2011 11:33 pm, edited 3 times in total.
User avatar
thepowersgang
Member
Member
Posts: 734
Joined: Tue Dec 25, 2007 6:03 am
Libera.chat IRC: thePowersGang
Location: Perth, Western Australia
Contact:

Re: Project source tree.

Post by thepowersgang »

Mine is a little more complex

Code: Select all

Modules/<class>/<name>
 - Kernel modules (Where class is Filesystem, Storage, Input, etc)
Kernel/arch/<arch>
 - Per-architecture code (x86, x86_64, armv7)
Kernel/vfs/
 - VFS code
Kernel/include
 - Kernel-land includes
Kernel/bin
 - Binary formats
Kernel/
 - Common kernel code
Usermode/Applications
Usermode/Libraries
Usermode/include
Kernel Development, It's the brain surgery of programming.
Acess2 OS (c) | Tifflin OS (rust) | mrustc - Rust compiler
Currently Working on: mrustc
SDS
Member
Member
Posts: 64
Joined: Fri Oct 23, 2009 8:45 am
Location: Cambridge, UK

Re: Project source tree.

Post by SDS »

All of my projects have a similar layout

Code: Select all

proj_dir
  ├─  config               (Contains configuration details for different compilers etc.)
  ├─  doc                   
  ├─  dest                  (Built code ends up here)
  │    ├─  config 1
  │    └─ ...
  ├─  src
  │    ├─  include
  │    └─ ...
  ├─  tools                 (Tools for building/running the code etc.)
  └─  utils                  (Utilities for use in conjunction with the code).
Post Reply