OhNoNotAgain
Programmer
Hello All,
I have to write a C program that will work on AIX, HP-UX, Solaris and Linux boxes. The program will simply list files in a given directory that start with the word install_ and will display the found files in a menu for the user to select.
So far I have only done some testing on HP-UX, to get the list of files in the dir I am using opendir and readdir.
Q1. What calls would you recommend that will work across platforms to do the same as opendir, readdir or are these two OK.
Q2. This also needs to work across machines. For eg box1 has a mount point /mnt that points to box2:/usr/local/scriptdir, my program will be run on box1 doing a search for files starting with install_ in /mnt
Any advice or useful webpages would be very welcome. I can program but am new to C.
Thanks.
I have to write a C program that will work on AIX, HP-UX, Solaris and Linux boxes. The program will simply list files in a given directory that start with the word install_ and will display the found files in a menu for the user to select.
So far I have only done some testing on HP-UX, to get the list of files in the dir I am using opendir and readdir.
Q1. What calls would you recommend that will work across platforms to do the same as opendir, readdir or are these two OK.
Q2. This also needs to work across machines. For eg box1 has a mount point /mnt that points to box2:/usr/local/scriptdir, my program will be run on box1 doing a search for files starting with install_ in /mnt
Any advice or useful webpages would be very welcome. I can program but am new to C.
Thanks.