I have an executable file written in C++/MacOS takes a clips command and run it using clips.h
functions. The executable works perfect on my Mac but once I try to run the same clips
command I'm facing an error.
I've searched for any thing could help but I couldn't find a really helpful things.
The commands are simple and the functions should be builtin clips
already.
here is the file I'm loading.
(defrule QPain
=>
(printout t "Are You In Pain? ")
(bind ?answer (read))
(if (eq ?answer y)
then
(bind ?*symcount* (+ ?*symcount* 1))))
and here is my c++ code,
#ifdef __cplusplus
extern "C" {
#endif
#include "clips.h"
#ifdef __cplusplus
}
#endif
#include <string>
#include <iostream>
using namespace std;
int main() {
Environment* env = NULL;
env = CreateEnvironment();
SetConserveMemory(env, true);
ReleaseMem(env, 0);
Load(env, "/path/to/clp/file/above");
Reset(env);
Run(env, -1);
return 0;
}
For the above code I'm facing theses two errors:
[EXPRNPSR3] Missing function declaration for 'printout'.
What I'm missing ? is there any libs I need to install on Linux for running such commands even I'm using clips.h
functions ??
clip
. Hard to believeopen()
is not found. Good luck. – shellter