What would be the general structure of a App/Project based in C Programming language. libs, includes, header files. etc etc.
What would be the class structure. (in OOps) need to be scalable and other features. Something like main.cpp main.h
does any one have any good links or images or pdf?
Most of the projects follow a single hierarchy as follows:
project
\_ conf\ --> configuration files (Unix/Linux projects might prefer an 'etc' folder)
\_ src\ --> main source (for C++ projects, headers and sources go along, but if
your project is a library then separating include files for others
is a better practice)
\_ src\module1\ --> for each sub module (for multiple files having related contents,
it is better to separate them to their own subfolders)
\_ doc\ --> documentation
\_ include\ --> (for library projects, the distributable include files)
\_ os\ --> OS (platform dependent) files (uch as makefiles, package building
scripts..)
\_ res\ --> resources required for compilation but not source files (icons, etc.)
\_ MAKEFILE --> makefile script for building the project
\_ README --> introductory document (might refer to doc\README)
\_ INSTALL --> Installation document (might refer to doc\INSTALL)
For the directory layout/class structure I suggest reading this
http://www.javapractices.com/topic/TopicAction.do?Id=205
The link talks about Java but it applies to any Language (even non- OOP)
You might also find this interesting
http://www.gnu.org/prep/standards/html_node/index.html
What you could do is find an open-source project in the same domain and study their project structure and adapt it as needed.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With