Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re^5: Defining the C environment for "inline::c"

by syphilis (Archbishop)
on Jul 23, 2014 at 03:30 UTC ( [id://1094718]=note: print w/replies, xml ) Need Help??


in reply to Re^4: Defining the C environment for "inline::c"
in thread Defining the C environment for "inline::c"



I just downloaded the Inline-C tar.gz


As Anonymous Monk said, that's not the correct way.
However, because Inline::C is, itself, a pure perl module that approach will work - but you didn't do it correctly. As well as copying the "C" folder to perl/site/lib/Inline, you should also copy C.pm and C.pod to the same location.

Most people would install Inline::C by running something like cpan -i Inline::C
Alternatively, having already downloaded and extracted Inline-C-0.62.tar.gz you could 'cd' to the extracted Inline-C-0.62 folder and run 'perl Makefile.PL', 'dmake test', then 'dmake install'.
If you go down either of those 2 paths, expect to see lots of warnings (with I::C-0.62) during the 'dmake test' phase - and expect t/26fork.t and t/27inline_maker.t to fail. (But just do the 'dmake install' anyway.)
Nearly forgot - for running dmake test you'll need Test::Warn (and its preprequisites) and File::Copy::Recursive installed.

Cheers,
Rob

Replies are listed 'Best First'.
Re^6: Defining the C environment for "inline::c"
by murrayn (Sexton) on Jul 23, 2014 at 06:18 UTC
    I've been a good novice and done as the wise ones said (or sort of anyway). I went back and ran "cpan install Inline::C" and got a nice clean result. C.pm and C.pod are also in my Inline directory now and my "Hello world" application runs from the command line but not from my Eclipse environment where it's stored in the "...\Perl<space>Code\..." directory path. If I try to run a Perl script with Inline C code from inside that directory path the build function tries to copy resources into the C: root directory and fails as described above. If I move my script into something with properly named directories everything seems to be happy. Clearly, Bill Gates is not the Messiah!, he's a very naughty boy for allowing silly file and directory names! Thanks for all the help. Time for an attempt at a real project!

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1094718]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others taking refuge in the Monastery: (5)
As of 2025-06-13 06:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.