News Feed
Sections




News Archive
feed this:

Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

PHP-Security.net:
Suhosin 0.9.34-DEV Installation HowTo
May 03, 2012 @ 11:54:57

On the PHP-Security.net blog today there's a new post showing how to get the latest version of the Suhosin security patch for PHP installed.

With the recently released PHP 5.4, the Suhosin patch and extension were removed from many Linux distribution packages (i.e., Debian et al.) and until three weeks ago, there was no possibility to compile and run the Suhosin extension under PHP 5.4. This little howto shall serve as installation instruction for Debian Wheezy users - your mileage may vary. I blogged about this here.

They start with the apt-get commands to install the latest PHP5 for your distribution (yum commands are similar, of course) and includes the location to download the latest Suhosin version from Stefan Esser's github account. Unpack it, compile and "phpize" it and if all goes well, you should have a shared module built and ready for use.

0 comments voice your opinion now!
install suhosin shared module compile phpize tutorial


Christian Weiske's Blog:
Installing PHP extensions for phpfarm
July 25, 2011 @ 08:15:15

Christian Weiske has a new post to his blog today on how to get PHP extensions installed for phpfarm, the tool that lets you switch between multiple PHP versions on the same machine.

When using several PHP installations with phpfarm, installing PHP extensions is not always easy - mostly because Pyrus is very strict about package files - and many of the packages in PECL unfortunately have invalid non-validating package.xmls.

The installation follows most of the normal process with one exception - you use the phpfarm phpize and point the configure to use the phpfarm ini configuration file then enable it as usual.

0 comments voice your opinion now!
extension phpfarm multiple pear pyrus phpize configure


Zend Developer Zone:
Compiling PHP extensions with Zend Server
April 30, 2009 @ 08:46:52

On the Zend Developer Zone a new tutorial has been posted showing how to compile PHP extensions to work with the Zend Server web platform.

To date, Zend Server includes 77 PHP extensions that Zend considers essential or just very helpful for most PHP developers. Still, what if the one that your code uses is not among them? Or you wish to compile one of the extensions Zend Server is shipped with in a different way (against your own libraries or to support additional, less common features)? If this scenario sounds familiar to you, you may find this tutorial useful.

You'll need to know a bit about compiling and some of the tools (like autoconf, automake, the gcc compiler, and libtool) before you get started. Two scenarios are described - one for installing and compiling the Newt extension (RedHat's Newt New Terminal library) and another slightly less automated for the Pspell extension.

Each of these examples make a shared module that can be included into the PHP installation via your php.ini.

0 comments voice your opinion now!
zendserver extension compile phpize shared module phpini


Zend Developer Zone:
Wrapping C++ Classes in a PHP Extension
April 23, 2009 @ 10:21:50

On the Zend Developer Zone a new tutorial has been posted looking at taking your pre-existing C++ functionality and wrapping it in a PHP extension to be used directly in your code.

In this tutorial I am going to walk you through creating a PHP extension called "vehicles" which will expose a single class called "Car" (obviously in the real-world, your extensions will expose many classes, but I'm trying to keep things simple). The extension will be built for PHP 5. I am only going to give instructions for building the extension in a UNIX-like environment, although most of what I cover should apply to Windows extension development as well.

The tutorial walks you through everything - how the file layout should look, making a build system, the contents of his files (the sample extension lets you do things to the Car like shift gears and brake) and how to combine the C++ code with the build process to create a shared module you can include right in your php.ini.

0 comments voice your opinion now!
module shared phpize buildfile tutorial c extension cplusplus class


Abhinav Singh's Blog:
PHP Extensions - How and Why?
December 12, 2008 @ 11:17:23

Abhinav Singh has posted a guide to PHP extensions - what they are and how to write a simple "hello world" one.

Assuming you have read the previous post, lets discuss on how to build our first PHP extension: every PHP extension is built out of minimum of 2 files, a configuration file (config.m4) which tells us what files to build and what external libraries are needed and source File(s) which will contain the actual functionality.

He builds up an example skeleton for an extension (the config.m4) and explains how the file will be phpized and configured. Next up is the php_sample.h header file where the needed modules are loaded and the sample.c file to define them. Last, but not least, comes the extension code itself that calls the printf function to output the "hello world" message.

0 comments voice your opinion now!
extension tutorial header file config phpize helloworld


John Coggeshall's Blog:
Compiling extensions for Zend Core
January 08, 2008 @ 09:32:00

John Coggeshall has blogged about a method he's worked up for compiling extensions into the Zend Core software.

While Core does ship with a large list of extensions (which are all QA'd and supported by Zend) there are times when you would like to include non-official extensions from PECL for various reasons.

He breaks it down into a few simple steps - download, "phpize" the extension, compile it and add the extension to the php.ini. He details the second step of the process (the phpize) because of some of the differences there are between doing it for a normal PHP install and a Zend Core install.

He also provides directions for an exception to the rule - compiling a PDO driver for your ZC install. You'll have to trick the Zend Core installation into using the right files, though. Full instructions are included.

0 comments voice your opinion now!
compile extension zendcore pdo sqlite phpize compile extension zendcore pdo sqlite phpize



Community Events





Don't see your event here?
Let us know!


threedevsandamaybe unittest podcast language interview laravel symfony2 configure code testing framework opinion release developer list install introduction community refactor series

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework