Extending and Embedding Perl
Extending and Embedding Perl by Tim Jenness and Simon Cozens
Manning Publications, 2003
Nothing instills more fear in the average Perl programmer than working with XS, Perl's technology for interfacing with eXternal Subroutines in other languages, most notably C. Calling C libraries from Perl is a delicate science, as is the related technique of embedding the entire Perl interpreter into an existing C program. Not every Perl programmer needs to do such things, but when faced with the task, it's hard work.
Written by two respected members of the Perl community, Extending and Embedding Perl attempts to address the needs of such programmers. It covers a lot of ground: XS, the Perl API, alternatives to XS, embedding, the Perl internals, compiling and the Perl development process.
I particularly liked the use of real examples (and working source code) when discussing various aspects of this technology. There are code snippets from Tk, Apache::mod_perl and the Perl sources. I also liked how the authors often would present an obvious solution to a problem, only to highlight its shortcomings, refine the initial solution and then present the improvement. This made the book's material real and useful.
I don't agree with the authors' assumption that they provide enough C in the two chapters they devote to the language. Programmers already competent in Perl and C will get the most from this book. If all you know is Perl, you'll likely struggle with the material. This is not really the authors' fault: XS isn't easy, and the style of C that's used within the Perl sources and the XS interface is somewhat obscure (that's being kind). I was amazed how often I found myself looking at the presented C code and shuddering. That aside, this book is a welcome addition to the arsenal of Perl books. It should help with demystifying XS and associated technologies. As to whether Extending and Embedding Perl is a book for every Perl programmer, I'd have to say it is not. However, if you do need it, you will find it an invaluable reference.
Getting Started with DevOps - Including New Data on IT Performance from Puppet Labs 2015 State of DevOps Report
August 27, 2015
12:00 PM CDT
DevOps represents a profound change from the way most IT departments have traditionally worked: from siloed teams and high-anxiety releases to everyone collaborating on uneventful and more frequent releases of higher-quality code. It doesn't matter how large or small an organization is, or even whether it's historically slow moving or risk averse — there are ways to adopt DevOps sanely, and get measurable results in just weeks.
Free to Linux Journal readers.Register Now!
- Hacking a Safe with Bash
- Django Models and Migrations
- Secure Server Deployments in Hostile Territory, Part II
- Huge Package Overhaul for Debian and Ubuntu
- The Controversy Behind Canonical's Intellectual Property Policy
- Shashlik - a Tasty New Android Simulator
- Home Automation with Raspberry Pi
- Embed Linux in Monitoring and Control Systems
- KDE Reveals Plasma Mobile
- diff -u: What's New in Kernel Development