Join Amazon Prime and ship Two-Day for free and Overnight for $3.99. Already a member? Sign in.

 

or
Sign in to turn on 1-Click ordering.
 
 
More Buying Choices
25 used & new from $18.99

Have one to sell? Sell yours here
 
   
Extending and Embedding Perl
 
 
Tell the Publisher!
I’d like to read this book on Kindle

Don’t have a Kindle? Get yours here.
 
  

Extending and Embedding Perl (Paperback)

by Tim Jenness (Author), Simon Cozens (Author)
4.6 out of 5 stars See all reviews (8 customer reviews)

List Price: $44.95
Price: $34.16 & this item ships for FREE with Super Saver Shipping. Details
You Save: $10.79 (24%)
In Stock.
Ships from and sold by Amazon.com. Gift-wrap available.

Only 3 left in stock--order soon (more on the way).

Want it delivered Tuesday, July 14? Choose One-Day Shipping at checkout. Details
16 new from $18.99 9 used from $24.00

Frequently Bought Together

Extending and Embedding Perl + Perl Hacks: Tips & Tools for Programming, Debugging, and Surviving + Mastering Perl
Price For All Three: $80.34

Show availability and shipping details


Customers Who Bought This Item Also Bought

Advanced Perl Programming

Advanced Perl Programming

by Simon Cozens
3.4 out of 5 stars (13)  $26.37
Mastering Perl

Mastering Perl

by brian d foy
4.4 out of 5 stars (9)  $26.39
Perl Best Practices

Perl Best Practices

by Damian Conway
4.5 out of 5 stars (34)  $26.37
Programming Perl (3rd Edition)

Programming Perl (3rd Edition)

by Larry Wall
4.0 out of 5 stars (111)  $32.97
Object Oriented Perl: A Comprehensive Guide to Concepts and Programming Techniques

Object Oriented Perl: A Comprehensive Guide to Concepts and Programming Techniques

by Damian Conway
Explore similar items

Editorial Reviews

Review
"A masterpiece that will keep its value for years." -- The Perl Journal

"Everything related to Perl internals is found here . . . organized well, and is fine as a reference work." -- The Perl Review

"Great for learning and great for reference, which is a combination other books often fail to achieve." -- Perlmonks

"Indispensable in gaining a good foothold on using Perl in, from, and around C." -- Slashdot.org

Product Description
An explanation of how to expand the functionality and usefulness of the Perl programming language, this guide delves into the complex issues of using real code examples from the Perl source. Detailed is how to use Perl from C programs, such as writing interfaces to C libraries, techniques on implementing Perl callbacks for C libraries, passing Perl hashes and arrays between Perl and C. Additionally, developers are provided with an API reference for the internal C interface to Perl and a reference on the typemap system.

See all Editorial Reviews

Product Details

  • Paperback: 384 pages
  • Publisher: Manning Publications; illustrated edition edition (August 2002)
  • Language: English
  • ISBN-10: 1930110820
  • ISBN-13: 978-1930110823
  • Product Dimensions: 9.1 x 7.4 x 0.7 inches
  • Shipping Weight: 1.4 pounds (View shipping rates and policies)
  • Average Customer Review: 4.6 out of 5 stars See all reviews (8 customer reviews)
  • Amazon.com Sales Rank: #497,774 in Books (See Bestsellers in Books)

Look Inside This Book
Browse Sample Pages:
Table of Contents | First Pages


Tags Customers Associate with This Product

 (What's this?)
Click on a tag to find related items, discussions, and people.
Check the boxes next to the tags you consider relevant or enter your own tags in the field below.
(3)

Your tags: Add your first tag
 
Help others find this product — tag it for Amazon search
No one has tagged this product for Amazon search yet. Why not be the first to suggest a search for which it should appear?

Sell a Digital Version of This Book in the Kindle Store

If you are a publisher or author and hold the digital rights to a book, you can sell a digital version of it in our Kindle Store. Learn more

 

Customer Reviews

8 Reviews
5 star:
 (6)
4 star:
 (1)
3 star:
 (1)
2 star:    (0)
1 star:    (0)
 
 
 
 
 
Average Customer Review
4.6 out of 5 stars (8 customer reviews)
 
 
 
 
Share your thoughts with other customers:
Most Helpful Customer Reviews

 
14 of 14 people found the following review helpful:
5.0 out of 5 stars Finally - all in one place, November 20, 2002
I got a copy of this book in one of the Israel Perl Mongers meetings (www.perl.org.il), to read and review it.

The topic is useful as this subject was considered as voodoo done by Perl hackers and "mappers of the Perl internals". I suppose you can say this claim is not true anymore, because this book collects the know-how from the perldocs, the newsgroups, the camel book (and other resources) and the personal experience of authors of the book.

Finally, you don't have to pick up small pieces of information about this subject in many places as people did prior to this book. What one would do, if one wanted to learn how to extend Perl or embed Perl before this book was available was doing one or more of the following:

* Read relevant small parts of the Camel book (preferably the recent edition rather than the 1st or 2nd) and "Advanced Perl Programming" (which is rather old, and only touches this matters).
This would give you some idea about Perl internals and perhaps some clues about XS, but that's about it.
* browse through newsgroups, mail archives and mailing lists to look for clues, and ask expert users, which usually, are not polite to answer newbies questions about such matters.
* figure out some cryptic (though, personally, I like them) incomplete (examples-wise) perldocs such as:
perlembed, perldebguts, perlxstut, perlxs,
perlclib, perlguts, perlcall, perlapi,
perlintern, perliol, perlapio, perlhack
* locate and dig into available CPAN module using this technology.

I think reading one book, with common terminology and many examples, is better than doing one or more of the above.

The book starts with an introduction of C for Perl programmers. It is very short and in my opinion not so accurate (due to its shortness), but since this should be a short introduction - it lives up to the promise. You can write a lot more than a "hello world" program after reading this short chapter, and you get a bonus, how to compile on gcc (gcc is ANSI-C and is available for all platforms), which is a wise idea. Perl programmers might be a bit disappointed to discover how much code and how complicated code you need to write in C to produce something that does the same as any Perl oneliner. The third chapter about Advanced C is a very good continuation to this introduction, especially, becuase the authors can assume you know some Perl (although I'm not sure they do). As someone giving lectures in "introduction to Computer Science, C language", I was tempted to borrow several very nice examples and explenations from this chapter. And I might also do that :-)

The next chapter explains how C code can be incorporated into a Perl Module and more generally into a CPAN package of a Perl module. This is very useful. Many resources (including books), focus on writing C/Perl code, and they say nothing or next to nothing about packaging (what you should do in order to make sure others can use your code, what you can and can't assume about the target system, etc.)

The fourth chapter is a useful cover of Perl variable types. This is somehting you could find in the "camel book", you can also find this in the (rather old) "Advanced Perl Programming", and of course in perldocs - but having it in one place, in order with examples and explenations is a real joy. Now you can figure it our reading one thing, and if you feel you want more, go to the perldocs.

Explaining Perl API, XS and advanced XS, alternatives to XS explain how you can add to your Perl programs some code (or programs or libraries) in C. I, personally wanted to have a module in Perl that gives interface to a data structure. Since the implementation I had is in C and it is tested and verified, I wanted to have a Perl module which exports the functionality, and offers a perl-oriented interface, without needing to reimplement the data structure in Perl. These book chapters made all the difference, and with the knowlede in chapter 2, I can now finish this, and after doing my testing, put it on CPAN. Isn't that great?!

If you are interested in doing the opposite, write Perl in C code, you can learn it in chapter 8. And if theory does not meet practice, you can read chapter 9 (and also try it out yourself) which presents a case study. Pretty useful stuff.

For people who are taking their first steps, the material so far is more than enough. But once you go deeper you want to know more about how to do more complicated stuff, and how stuff actually works. Chapter 10 which introduces you to the Perl internals is just what you would be looking for. Chapter 11 will be the tour into the depts, teaching you some perl hacking, i.e. how to alter Perl's behaviour.

The indices are useful, though can be found (though, not in similar format) elsewhere.

To sum this review, I loved the book. I wish I could take more time to practice what I read there thoroughly. I will surely get a copy of this book to have it on my bookshelf, and when the need comes, on my desk.

Comment Comment | Permalink | Was this review helpful to you? Yes No (Report this)



 
15 of 16 people found the following review helpful:
5.0 out of 5 stars The Book I Wanted For Christmas - Four Months Early! :-), September 15, 2002
The Short Review: This is a marvellous book, and if you want to learn about how to embed or extend C with Perl, then this is the book. Go buy. The Long Review: I used to be a commercial C programmer more years ago than I care to remember, but I never ever really "got" all those asterisks, and ampersands and all that other funny stuff. I was still really a LISP programmer at heart, and in 1991 when I first started learning C, I wondered why anyone would want to learn all those hieroglyphics when wonderful languages like LISP were around. Of course, the answers are speed, efficiency and power. But when I discovered Perl a few years later, which had all of this in buckets, it was with a very great relief that I threw off the millstone of C. But as I've got more into Perl, eventually even coming to teach and occasionally write about it, there have been many times when I've needed to drill down back into the demon of C. This has mainly been to increase the efficiency and speed of database code I've written for various companies. Alas, all those perlguts and perlembed manual documents were more cryptic and painful, to my mind, than the economic theories of the Keynesians; I got there in the end, but usually in a battered, bruised and bloodied state. But then I had the good fortune to go to a Damian Conway talk on Perl6, where I had the great privilege of meeting Hugo van der Sanden, who revealed the future appearance of Inline C in Perl 5.10. The beast would be outed, and I decided to try to master it. But how to figure it all out? Fortunately, a kind clever person at the bar afterwards pointed me towards this book, and all has since become clear. Well, clearer! :-) The dreaded malloc word appears on p.64, and the ... phrase "linked lists" appears on p.83, but somehow I survived. This book is well written, concise, and an absolute must for all those, such as myself, who need to work with C and Perl, but who've been putting off the ... day. With this superb book, we cowards no longer have any excuses. Magic! :-)
Comment Comment | Permalink | Was this review helpful to you? Yes No (Report this)



 
9 of 11 people found the following review helpful:
5.0 out of 5 stars There and Back Again, March 23, 2003
By C. Garrett Goebel (Mission, KS USA) - See all my reviews
(REAL NAME)   
Extending and Embedding Perl is as it boldly states on the cover: "The definitive guide to XS, embedding, and the Perl internals". This book is well organized and information dense. One could spend days sifting through the available perlapi, perlcall, perlembed, perlguts perlxs, perlxstut, and h2xs documentation. After which you'll probably understand very well references to nethack's "You are in a maze of twisty little passages all alike". Or you could get yourself a copy of this book and find your way out of the maze.

Most of the available documentation on extending and embedding perl is written from the prospective of the core perl developers for core perl developers. This book is written for advanced Perl programmers who for whatever reason need or wish to peer into that netherworld between Perl, C, and the glue that interface Perl with other languages. It is a deliberate thorough guide led by authors that are both extremely knowledgeable and also capable of communicating that knowledge.

While it would greatly reduce the learning curve, no prior knowledge of C is required to read this book. This is a surprising claim and while it won't be easy, this reader is proof that someone with little true knowledge of C can in fact read and for the most part comprehend what the authors wish to convey.

There are clearly areas for improvement. Things like NULL being used throughout chapter 3, only to finally be defined later in a footnote in chapter 4. And other cases of terms being used before they are explained. Things that leave the reader juggling unnecessarily until the information is provided that lets understanding fall into place. But for the most part, if you are a competent juggler and are patient your questions will eventually be answered. You won't walk away a C programmer, but you will learn enough to solve the problems which led you to consider reading this book in the first place.

One thing I liked very much about the layout of the book is how it switches back between presenting sections on C programming and Perl. The authors revisit C each time it is necessary to understand the next Perl internals topic. Those that are learning C or need the review receive the relevant information just before it is required.

Over the course of the book, you'll learn about interfacing from Perl to C and C back to Perl. For those that must plug references to Tolkien in things Perl... you can go back and rephase that into an appropriate reference to Bilbo's book "There and Back Again". You'll also learn the perl api, data structures for core variable types, and how to work with scalars, arrays, hashes, strings, regular expressions, file handles, typeglobs, objects, callbacks and PDL with C and C++. And there is even mention of working with Fortran, Java, and more esoteric alternatives.

The book finishes with an in depth look at Perl internals: the parser, tokenizer, op code trees, execution, and compiler. And closes with a discussion of the Perl development process: How it may be monitored and participated in.

What's missing? Detailed coverage of the I/O subsystem and the regular expression engine. I.e., topics which might themselves make for a good book. There was also light coverage on things like scratchpads. There were times while reading when I didn't know whether the issue being discussed was fully covered or curtailed. But you will certainly find better coverage of the issues in this book than elsewhere. This is an impressive book. I hope it will greatly influence the way Perl6 internals are documented.

Comment Comment | Permalink | Was this review helpful to you? Yes No (Report this)


Share your thoughts with other customers: Create your own review
 
 
 
Most Recent Customer Reviews

5.0 out of 5 stars Beyond using Perl
After being a Perl programmer for a while, you'll probably want to go deeper than that and perhaps enable some features that can not be done through the pure Perl code. Read more
Published 10 months ago by Burak Gürsoy

5.0 out of 5 stars Want to dive deep into perl? Get this book
The most concise book ever on demistfying the dreaded XS. The information found in the book is not a collection from PODs or from the Tiger, Camel books. Read more
Published on December 31, 2004 by Mustang

3.0 out of 5 stars A good book, but leaves windows programmers short
We bought this book as part of a project we were doing in windows. We were trying to integrate perl scripting as a macro language in an existing application. Read more
Published on August 28, 2003 by Geoff Woodcock

4.0 out of 5 stars This book belongs on your bookshelf
I really fell in love with this book as I read through it. It does an excellent job of explaining the hairy details of working with Perl at the C level, whether etending Perl... Read more
Published on January 29, 2003 by Patrick Eyler

5.0 out of 5 stars Exellent straight forward and complete.
The C world is so multifaceted, that it is a chore just to get through selecting the correct documentation to read, let alone actually reading and comprehending it. Read more
Published on October 17, 2002

Only search this product's reviews



Customer Discussions

 Beta (What's this?)
New! See all customer communities, and bookmark your communities to keep track of them.
This product's forum (0 discussions)
  Discussion Replies Latest Post
  No discussions yet

Ask questions, Share opinions, Gain insight
Start a new discussion
Topic:
First post:
Prompts for sign-in
  [Cancel]


Active discussions in related forums
  Discussion Replies Latest Post
C# or Java? 32 6 days ago
   


Product Information from the Amapedia Community

Beta (What's this?)



Look for Similar Items by Category


Great Deals on Magazines

Visit our huge selection of magazine subscriptions often to see the latest special offers and bonuses. Check out magazines like The New Yorker, Wired, and Vanity Fair.
 

Big Savings in Books

Bargain Books
Find great titles at fantastic prices in our Bargain Books Store.
 

Buy Three Books, Get a Fourth Free

4-for-3 Books
Order any four eligible books under $10 and get the lowest-price book free in our 4-for-3 Books Store. See more details.
 

Suck Up the Mess

Shop for Vacuums and Accessories
Keep your home and shop clean with a Shop-Vac or vacuum from the Home Improvement Store.

Shop more vacuums and dust collectors

 

 

Feedback

If you need help or have a question for Customer Service, contact us.
 Would you like to update product info or give feedback on images?
Is there any other feedback you would like to provide?

Your comments can help make our site better for everyone.


Where's My Stuff?

Shipping & Returns

Need Help?

Your Recent History

  (What's this?)
You have no recently viewed items or searches.

After viewing product detail pages or search results, look here to find an easy way to navigate back to pages you are interested in.

Look to the right column to find helpful suggestions for your shopping session.

Continue shopping: Top Sellers
Paranoia
Paranoia by Joseph Finder
Glenn Beck's Common Sense
Finger Lickin' Fifteen
Finger Lickin' Fifteen by Janet Evanovich
My Soul to Lose
My Soul to Lose by Rachel Vincent

Conditions of Use | Privacy Notice © 1996-2009, Amazon.com, Inc. or its affiliates