Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

C - Starting a big project. File/Directory structure and names. Good example required [closed]

Starting a new big C multiplatform project, what rules should one follow to avoid difficulties later? For example, as a new developer, I can have difficulties to navigate myself around Linux Kernel source code - which is a good example of highly evolvable but hard-to-step-in software structure with incosistent directory structure (e.g. sound directory and arch in the same directory level).

As a project-architect, what should I do to avoid later traps? Of course, I need very intuitive and self-consistent naming convention for C lexems and files. But what is the good style and what is not? Should I have one-only directory or tens of them? Should I place all header files in a common include directory?

Can you please give me a reference to a very good example? (any open source C project)

like image 988
psihodelia Avatar asked Mar 09 '10 15:03

psihodelia


1 Answers

You can probably refer to OpenSSL. Their file organization and distribution of functionalities across files is very good. So is their file naming convention which clearly indicates the functionalities. But, since it is based on SSL code, it might take some time to understand. Good Luck to you for your project! : )

like image 135
Jay Avatar answered Oct 27 '22 08:10

Jay