How to generate .H file from the .lib file ? i have created .lib file and i have the .c file for the .lib file itself.
I have generated the .H file and it works perfectly, but i was unaware that .H file can be created manually only, i thought it can be generated by some tools while creating .lib file.
is there any literature/article regarding how to use the syntax of the .H file like #ifndef __ ,#endif and all others.
Thank You sir for your valuable response.
If header files could be generated automatically, then there would be no need for header files in the first place, since the compiler would then be able to compile code without any header files by instead just deducing the corresponding information.
Yes, it's common to add guards against multiple-inclusion. For documentation about best practices - how about you google for "c coding best practices" and pick it up from there.
There is nothing special or magic about so-called "header" files - they just follow the standard syntax of the 'C' programming language.
So the literature you're looking for is just standard 'C' literature - textbooks, etc.
Here's some to get you started:
blog.antronics.co.uk/.../