I need to include a header in condition if it is present and if not i need to make the necessary steps for my code to work
I need to do something like...
// check if the header is present(may be .h files)
#include"required_header"
{
block-1
}
//if the header is not present
{
block-2
}
If I use like ....
#ifdef required_header
#include<required_header>
Block-1
#else
Block-2
The above case is redirected to Block-2 always because i have included the header file only inside the condition of ifdef and its never included
Hoping for a method to do it.
Thanks in Advance :}
P.S: I have defined the header but assuming i have not done the work of the required header but i want someone else to write that file and I am not sure if he has written it.
Precisely speaking I want the code replacement way in the place of comments in the first given code.