Hi
I have Fedora Core 5 2.6.17-1.2174_FC5 with gcc version: gcc (GCC) 4.1.1 200
60525 (Red Hat 4.1.1-1)
everything compiles well, and run smoothly on my machine. But the actual production machine is Linux 2.4.20-46.9.legacysmp
with gcc version gcc (GCC) 3.2.2 20030222 (Red Hat Linux 3.2.2-5)
on the production machine, I get errors like:warning #266: function declared implicitly while ((read = getline (&line, &len, sfile)) != -1) {
undefined reference to sem_init
undefined reference to sem_destroy
while I am using the correct headers
#define _GNU_SOURCE
#include <stdio.h>
for the getline
and#include <semaphore.h>
for the sem_init and sem_destroy
I receive the same warning #266: function declared implicitly
for my own defined functions as well, while my header is included,
any ideas where could be the problem,
sorry for asking a question that might be basic, but it is my first time to move code between different machines in linux and compilers versions,
I appreciate any help,
thanks,
Manal