Download visual studio 2015 for pc for free. Development Tools downloads - Microsoft Visual Studio 2015 by Microsoft and many more programs are available for instant and free download. PRODUCT KEY OF VISUAL STUDIO.Visual Studio 2015 Professional. HMGNV-WCYXV-X7G9W-YCX63-B98R2.Visual Studio 2015 Enterprise. 2XNFG-KFHR8-QV3CP-3W6HT-683CH.
After working on a very old project based on PHP 5.3, where the APC library was required to make it work, i knew how difficult is to find the APC extension to make it work on the Windows platform. For Linux, the process can be pretty easy with PECL, however in Window this was a real problem.
That's why today i'm going to show you how to compile a PHP extension from its source code from scratch in a Windows environment, specifically with the APC library and PHP 5.3.8.
Having said that, let's get started with the compilation !
Before getting started with the compilation of a PHP extension, you need to know that not every VS compiler is compatible with any version of PHP, so you will need to know which Visual Studio you need to use according to the version of PHP that you want compile your extension (obtain DLL file). Check out the following table that specifies which version of Visual Studio you need to compile your desired PHP version:
|PHP Version||5.2.x||5.3.x||5.4.x||5.5.x||5.6.x||7.0.x||7.1.x||7.2.x||64bits (***)|
|Visual C++ 6 (SP6 only)||Yes||Yes||No||No||No||No||No||No||No|
|Visual C++ 7/7.1 (2002, 2003, 2003+sp1)||Yes (**)||Yes (**)||No||No||No||No||No||No||No|
|Visual C++ 8 (VS 2005)||Yes (**)||No||No||No||No||No||No||No||No|
|Visual C++ 9 (VS 2008 SP1 only)||Yes (**)||Yes||Yes||Yes (**)||No||No||No||No||No|
|Visual C++ 11 (VS 2012)||No||No||Yes (**)||Yes||Yes||Yes (**)||No||No||Yes|
|Visual C++ 14 (VS 2015)||No||No||No||No||No||Yes||Yes(**)||Yes(**)||Yes|
|Visual C++ 15 (VS 2017)||No||No||No||No||No||Yes(**)||Yes(**)||Yes||Yes|
So to make it easy to understand, if you are willing to compile an extension for PHP 7, you will need the source code of PHP 7, the code of the extension as well and at least Visual Studio 2012 assuming that you want to compile it for PHP 7.0, because if you want it for PHP 7.1, then you would need at least Visual Studio 2015.
Knowing this, if you are sure that you have the correct version you shouldn't face any trouble while you compile the extension. Otherwise you will face weird exceptions during the configuration of the build:
In this tutorial we'll build the APC extension for PHP 5.3.8, so in our case we'll need to work with Visual Studio 2008 SP1 for visual c++ 9.
In order to run some administrative commands related to the development and build of your extension, you will need a command prompt with the context of Visual Studio. Namely the Developer Command Prompt for VS that you can find at the path:
C:ProgramDataMicrosoftWindowsStart MenuPrograms<Your Visual Studio Version e.g 2008 or 2017>Visual Studio Tools
Here you will find an executable of the command prompt that has access to all the tools that you will need to build the extension, execute it with administrator rights:
As mentioned, is a normal command prompt that contains the tools that we need for the next steps:
Let it open as we'll need in the step 5.
Now that you have the necessary tools to compile PHP along with your extension, you will need as well the source code of PHP. You can get the source code of the PHP version that you need from the official releases webpage of PHP here.
Once you download the tar/zip file with the code, extract it into a directory with a short path to prevent any problem with the length of the paths in Windows. In our case, we'll extract the source code of PHP 5.3.8 in the
We'll run the commands to build PHP along with your code in this directory within the command prompt later. It's worth to mention that the ext folder will contain the code of your extension but we will add it in the next step.
In order to build your extension, either you build an open source extension or create your own extension. In our case, we will build the APC extension, the version 3.1.6 specifically for PHP 5.3.8 (the same version of our PHP source code). This will ensure that the generated dll of PHP will be compatible with the PHP version that we need.
Once you download the source code of your extension (or you write your own code for it), extract it inside the
ext folder of the PHP source code. In our case, the directory for the extension would be
c:/php-src/ext/apc and it will contain the code of the extension (this is very important as the extension will be compiled along as a dynamic library with PHP):
Be sure as well that the
config.w32 file in the root directory of the source code of the extension, in the line that registers the extension with the EXTENSION function, the third parameter is set to true in order to generate a DLL (dynamic mode):
Because as you may know you can integrate the extension directly with PHP, but in this tutorial we are showing how to generate the DLL file that in our case will be
Go back to the visual studio developer command prompt and switch to the directory of the source code of PHP:
Then run the
buildconf.bat file with the
This will generate a new .bat file namely
configure.bat that will have the configuration of your PHP build. Run the bat with the following command and enable your extension using the
--enable-<extension_folder_name> argument. In our case, the extension is APC and we stored the source code in the
c:/php-src/ext/apc directory, so the extension name will be APC. Run the command to configure it:
If you run the previous command and you face an exception because bison.exe haven't been found:
Download the binaries of Bison from the website at Source Forge here. Then paste the bison.exe and m4.exe at the bin directory of Visual Studio e.g
C:Program Files (x86)<Your Microsoft Visual Studio Version e.g 9.0>VCbin. This will make the bison executable accesible to the path and the exception bison is required won't appear anymore.
--disable-all flag will help us to prevent any other exception of extensions that we don't need, just focusing on the APC extension that we need. And that's it, you will get a verbose output that includes a list with all the extensions that will be built along with PHP and its mode e.g Static (built-in classes in PHP) or Shared (a Dynamic Link Library dll):
As expected, our extension of PHP will be built into a DLL file just as we want it. By default, this will create a 'Thread Safe' build (PHP 5.3.8 TS). If you want a non thread safe build, just add the
--disable-zts flag to the configure command.
Finally, run the nmake command to start the build of your extension with PHP within the directory of the PHP source code with the developer command prompt. NMake is a make utility provided by Microsoft and available in Visual Studio. It is a handy tool for creating automated builds.
Just run the command:
This will start the compilation and will take a while. It will generate a verbose output as well with warnings etc:
Once it finishes, a new directory will appear inside the
c:/php-src directory, namely Release or Release_TS according to the Thread Safety configuration. There you will find a very basic built of PHP, but most important, the reason why you exclusively built PHP, your extension DLL file (in our case
This article is a recopilation of multiple sources that you may find useful as well during the compilation of an open source extension or your own extension:
Happy coding !
Visual Studio Crack offers you beneficial apparatuses. Presently you can assemble structure and convey application programs for Windows, Android, and web overseen by cloud also. Voxal voice changer for mac. You can find this software extremely useful because it contains cutting edge innovations that are not accessible in different projects. It is full included and broad Integrated Development Environments for individual designers. The Full form of Visual Studio 2020 Crack is currently accessible for Mac gadgets and Microsoft Windows too. Everybody finds the best and genuine item for their use.
It is certain that you are also searching for the original software program. Moreover, it is the noteworthy instrument on the off chance that you are identified with software advancement field. Everybody wishes to be the software engineer. So Visual Studio 2018 Free download gives you the chance to make applications. You can also manufacture, send, and plan application program for Windows, iOS alike.
Microsoft Visual Studio 2020 Crack is a stunning variant as of late discharged. Past renditions contain some bugs so this fixed variant accompanies most recent features with zero mistakes. Everybody enjoys those software those have blunder free program. This software accompanies 15 unique dialects so everybody can make applications for various purposes. It has included most generally used dialects all around the globe. It accompanies diverse renditions and every one of the adaptations are upgradeable with time. You will find here the third refresh of rendition 2018. Visual Studio 2020 Serial key is the most recent solution to initiate the top notch bundle.