php2exe,windows下的php编译器
首先,遗憾的是,此编译器暂时只支持 php 4.x。php 5 原理上是支持的,但是实际上我没有能够编译成功(是指编译针对 php 5 版本的编译器,作者只提供了 php 4.x 对应的编译好的编译器。)。
http://www.bambalam.se/bamcompile/
这是在网站上的一段介绍:
Bambalam PHP EXE Compiler/Embedder is a free command line tool to convert PHP applications to standalone Windows .exe applications.
Bambalam PHP EXE 编译器/打包器是用于将 PHP 程序转化为独立的 Windows .exe 程序的免费命令行工具。
The exe files produced are totally standalone, no need for php dlls etc.
生成的 exe 文件是完全独立的,不需要任何 php 动态连接库。
The php code is encoded using the Turck MMCache Encode library so it's a perfect solution if you want to distribute your application while protecting your source code.
这使得 php 代码使用 Turck MMCache Encode 进行了编码,所以如果你想分发你的程序同时保护你的源代码,这是最好的解决方法。
The converter is also suitable for producing .exe files for windowed PHP applications (created using for example the WinBinder library).
这个转化器同时也适用于生成使用 PHP 编写的窗口程序的 .exe 文件(如使用WinBinder library创建)。
It's also good for making stand-alone PHP Socket servers/clients (using the php_sockets.dll extension).
这个同时也是创建独立的 PHP Socket 服务器/客户端的好方法(使用 php_sockets.dll 扩展)。
It's NOT really a compiler in the sense that it doesn't produce native machine code from PHP sources, but it works!
由于它不从 PHP 代码中产生机器本地码,感觉上应该不算真正的编译器。但它确实能工作。
The tool is free and open source. However, if you use it commercially (ie to make money in some way) you should make a donation to keep the project alive!
这个工具是免费的,也是开源的。但是如果你在商业上使用它(比如从某些渠道获利),为了它能继续下去你应当对其作出贡献。
-----------------------------------
在 python 社区使用 py2exe 如火如荼的时候,php2exe无疑会给php带来更多的使用空间~~比如使用php编写的监控程序等等~~

01月 30th, 2007 at 12:02:58
谢谢! 正四处乱搜呢
by 小雨