I am having a real bad hair day today! Nothing works!
Anyway, enough ranting:
main.cc
Code:
#include <iostream>
#include <global.h>
...
int main(int argc,char *argv[])
{
...
if(load_params(argv[1]))
return RET_ERR;
...
return RET_OK;
}
global.h
Code:
#ifndef _GLOBAL_H
#define _GLOBAL_H
#ifdef __cplusplus
extern "C"
{
#endif
...
int load_params(char *fname);
...
#ifdef __cplusplus
}
#endif
#endif /* _GLOBAL_H */
param.cc
Code:
#include <global.h>
...
inline int load_params(char *fname)
{ return param_scenario.init(fname);
}
...
All files compile but I get an "undefined reference to load_parameters" error. I note that load_parameters does not have () after it in the error message.
All help appreciated. Thank you.