header file
-
Can anyone who have or know where i can get the header file of help me with it. I tried to search it but the search was fruitless -oam-
-
Are you developing on UNIX? .. I Tlooks like it's a UNIX specific header file see: [^] for my google results... I also found this http://aegis.sourceforge.net/doxygen-html/unistd_8h-source.html[^] which is *A* uninstd.h file .. but i have doubts that it's the one specific to the application you are trying to compile .... IF you can provide details about the application / source / where it was obtained from / what platform your working on etc... I will do my bes to help you out ... Regards qcha0s
-
What do you intend to do with it ? Christian I have several lifelong friends that are New Yorkers but I have always gravitated toward the weirdo's. - Richard Stringer
-
Are you developing on UNIX? .. I Tlooks like it's a UNIX specific header file see: [^] for my google results... I also found this http://aegis.sourceforge.net/doxygen-html/unistd_8h-source.html[^] which is *A* uninstd.h file .. but i have doubts that it's the one specific to the application you are trying to compile .... IF you can provide details about the application / source / where it was obtained from / what platform your working on etc... I will do my bes to help you out ... Regards qcha0s
Question is, what good is a header file to him anyhow ? I suspect he's got code that includes it, and he has no idea that the header file needs at least a lib file to link to before it's worth anything. Christian I have several lifelong friends that are New Yorkers but I have always gravitated toward the weirdo's. - Richard Stringer
-
What do you intend to do with it ? Christian I have several lifelong friends that are New Yorkers but I have always gravitated toward the weirdo's. - Richard Stringer
-
I am running an application on windows from a unix machine and it was looking for this header but then i didn't want to go to the unix machine -oam-
OK - as I thought. You're more than a little lost here. A header file describes functionality that needs to be provided either in matching .cpp files, or in a library file. The compiler is asking for the header file now, but if you provide it, you will get linker errors from here to sundown, because you will have a file that promises the compiler that you'll tell it how to impliment functions you're describing now, sometime later. You will not meet that promise, and so your code will still not work ( unless this is an inline class that's all in the .h file, implimentation as well as interface, but that seems unlikely ). Christian I have several lifelong friends that are New Yorkers but I have always gravitated toward the weirdo's. - Richard Stringer
-
Are you developing on UNIX? .. I Tlooks like it's a UNIX specific header file see: [^] for my google results... I also found this http://aegis.sourceforge.net/doxygen-html/unistd_8h-source.html[^] which is *A* uninstd.h file .. but i have doubts that it's the one specific to the application you are trying to compile .... IF you can provide details about the application / source / where it was obtained from / what platform your working on etc... I will do my bes to help you out ... Regards qcha0s
infact i wanted to compile this code below but now i am working hand in hand with unix machines. But now i wanted to try this application on windows
#include /* has definitions of printf, fprintf, fopen, fscanf, fclose, fflush, perror, rename and BUFSIZ */ #include /* has definitions of getenv and exit */ #include /* has definition of sleep */ #include /* has definitions of strcpy and strcat */ main() { char *restart_name, *restart, old_restart_name[BUFSIZ]; FILE *restart_file; int n; /* Is this a continued job or a new one? */ if (! (restart = getenv ("RSAVE_RESTART"))) { printf ("Starting a new run.\n"); n = 0; } else { if (! (restart_name = getenv ("RSAVE_CHECKFILE"))) { fprintf (stderr, "error: no checkpoint file for the restart job\n"); exit (1); } else { printf ("Restarting the job from %s.\n", restart_name); if (! (restart_file = fopen(restart_name, "r"))) { perror (restart_name); exit (2); } else { if (! (fscanf (restart_file, "%d", &n) > 0)) { fprintf (stderr, "%s: input file format error\n", restart_name); exit (3); } else { fclose (restart_file); } } } } printf ("n = %d\n", n); printf ("\tcomputing ... "); fflush (stdout); sleep (5); n++; printf ("done.\n"); printf ("n = %d\n", n); if (! (restart_name = getenv ("RSAVE_CHECKFILE"))) { printf ("checkpointing not requested, exiting...\n"); exit (0); } else { if (restart) { strcpy (old_restart_name, restart_name); strcat (old_restart_name, ".old"); printf ("renaming old restart file to %s\n", old_restart_name); if (0 > rename (restart_name, old_restart_name)) { perror (old_restart_name); exit (4); } } printf ("saving data on %s\n", restart_name); if (! (restart_file = fopen (restart_name, "w"))) { perror (restart_name); exit (5); } else { fprintf (restart_file, "%d\n", n); fclose (restart_file); } } exit (0); }
-oam- -
OK - as I thought. You're more than a little lost here. A header file describes functionality that needs to be provided either in matching .cpp files, or in a library file. The compiler is asking for the header file now, but if you provide it, you will get linker errors from here to sundown, because you will have a file that promises the compiler that you'll tell it how to impliment functions you're describing now, sometime later. You will not meet that promise, and so your code will still not work ( unless this is an inline class that's all in the .h file, implimentation as well as interface, but that seems unlikely ). Christian I have several lifelong friends that are New Yorkers but I have always gravitated toward the weirdo's. - Richard Stringer
Did you check the code i sent there headers are #include /* has definitions of printf, fprintf, fopen, fscanf, fclose, fflush, perror, rename and BUFSIZ */ #include /* has definitions of getenv and exit */ #include /* has definition of sleep */ #include /* has definitions of strcpy and strcat */ therefore i thought the header file will take care of the definition of sleep and that there header file is standard like some headers files that you can get them from somewhere and use them -oam-
-
Did you check the code i sent there headers are #include /* has definitions of printf, fprintf, fopen, fscanf, fclose, fflush, perror, rename and BUFSIZ */ #include /* has definitions of getenv and exit */ #include /* has definition of sleep */ #include /* has definitions of strcpy and strcat */ therefore i thought the header file will take care of the definition of sleep and that there header file is standard like some headers files that you can get them from somewhere and use them -oam-
mpapeo wrote: Did you check the code i sent there No, you need to check 'Do not treat <'s as HTML tags' so I can see this code, for what it's worth mpapeo wrote: therefore i thought the header file will take care of the definition of sleep It will take care of the 'definition', that is, it will define the interface, the functions/structs/classes provided elsewhere. It won't give you the code you need to make those things work. The standard library headers, such as iostream, define exactly that, and have corresponding .cpp files which are in directories that your compiler includes in it's searches by default. So they get compiled and linked into your project, no problem. You can't just add other header files to do the same thing, without making sure you are linking to a library, or have the implimentation files available to the compiler also. Christian I have several lifelong friends that are New Yorkers but I have always gravitated toward the weirdo's. - Richard Stringer
-
Did you check the code i sent there headers are #include /* has definitions of printf, fprintf, fopen, fscanf, fclose, fflush, perror, rename and BUFSIZ */ #include /* has definitions of getenv and exit */ #include /* has definition of sleep */ #include /* has definitions of strcpy and strcat */ therefore i thought the header file will take care of the definition of sleep and that there header file is standard like some headers files that you can get them from somewhere and use them -oam-
Are you just looking for a header file that will support Sleep? /* Just a Human Trying to Live in a Computers World. */
-
OK - as I thought. You're more than a little lost here. A header file describes functionality that needs to be provided either in matching .cpp files, or in a library file. The compiler is asking for the header file now, but if you provide it, you will get linker errors from here to sundown, because you will have a file that promises the compiler that you'll tell it how to impliment functions you're describing now, sometime later. You will not meet that promise, and so your code will still not work ( unless this is an inline class that's all in the .h file, implimentation as well as interface, but that seems unlikely ). Christian I have several lifelong friends that are New Yorkers but I have always gravitated toward the weirdo's. - Richard Stringer
Christian Graus wrote: A header file describes functionality that needs to be provided either in matching .cpp files, or in a library file. True, but not always. Some of them have
typedef
andstruct
declarations only. I've no idea what mpapeo is looking for, however.
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
-
Christian Graus wrote: A header file describes functionality that needs to be provided either in matching .cpp files, or in a library file. True, but not always. Some of them have
typedef
andstruct
declarations only. I've no idea what mpapeo is looking for, however.
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
DavidCrow wrote: Some of them have typedef and struct declarations only Yeah, and some contain the entire class ( can't they ? ). I said as much before, but in restating it, I was less careful :-) Christian I have several lifelong friends that are New Yorkers but I have always gravitated toward the weirdo's. - Richard Stringer
-
Did you check the code i sent there headers are #include /* has definitions of printf, fprintf, fopen, fscanf, fclose, fflush, perror, rename and BUFSIZ */ #include /* has definitions of getenv and exit */ #include /* has definition of sleep */ #include /* has definitions of strcpy and strcat */ therefore i thought the header file will take care of the definition of sleep and that there header file is standard like some headers files that you can get them from somewhere and use them -oam-
My collegue have ported some Project from Unix enviornment to windows enviornment. Here is What i found in unistd.h
/*
* This file is part of the Mingw32 package.
*
* unistd.h maps (roughly) to io.h
*/#ifndef _UNISTD_H
#define _UNISTD_H#include <io.h>
#include <process.h>#endif /* _UNISTD_H */
[Vote One Here, Complete my Survey....] Alok Gupta
visit me at http://www.thisisalok.tk "I Think Believe this Will Help" -
I've generally found that you can just delete this line and it will work under Windows. Don't quote me on that though, it may not work at all.
Ryan
"Punctuality is only a virtue for those who aren't smart enough to think of good excuses for being late" John Nichol "Point Of Impact"
-
My collegue have ported some Project from Unix enviornment to windows enviornment. Here is What i found in unistd.h
/*
* This file is part of the Mingw32 package.
*
* unistd.h maps (roughly) to io.h
*/#ifndef _UNISTD_H
#define _UNISTD_H#include <io.h>
#include <process.h>#endif /* _UNISTD_H */
[Vote One Here, Complete my Survey....] Alok Gupta
visit me at http://www.thisisalok.tk "I Think Believe this Will Help"