You are viewing a plain text version of this content. The canonical link for it is here.
Posted to embperl@perl.apache.org by open sourcer <op...@gmail.com> on 2005/02/10 07:22:19 UTC
Calling c functions from perl w/o using c wrappers
hi
I have a embedded perl into a c class file,
assume
emb_perl.c
/*-------------------- ****------------------------- */
#include <EXTERN.h>
#include <perl.h>
class <class_name>
{
code ..
}
int function_name
{
code
}
/*--------------- end ---------------*/
this hole thing is build into exe <emb_perl.exe>, remember now
emb_perl is exe no source is available.
now i want to use <function_name> in my pl files
sample.pl
------------------------
#!/usr/bin/perl -w
$get_data = function_name (1,2);
print $get_data;
say
c:\emb_perl sample.pl
thanks
opensourcer
---------------------------------------------------------------------
To unsubscribe, e-mail: embperl-unsubscribe@perl.apache.org
For additional commands, e-mail: embperl-help@perl.apache.org