如何有选择地将 Lazarus Apache 模块编译为 Apache 1.3、2.0 和 2.2?
我查看了 /etc/fpc.cfg 并提到了一些定义:
- FCAPACHE_1_3
- FCAPACHE_2_0
然后在 fcl-web 示例中提到:
- Apache1_3
我发现的唯一一个是在 apr.pas 上这两个文件:
- /usr/share/fpcsrc/2.4.0/packages/httpd20/src/apr/apr.pas
- /usr/share/fpcsrc/2.4.0/packages/httpd22/src/apr/apr.pas
那么怎么样编译器决定编译哪个版本的 APR?
I've had a look at /etc/fpc.cfg and there is mention to some defines:
- FPCAPACHE_1_3
- FPCAPACHE_2_0
Then in the fcl-web examples there is mention to:
- Apache1_3
The only one I've found is on the apr.pas on both these files:
- /usr/share/fpcsrc/2.4.0/packages/httpd20/src/apr/apr.pas
- /usr/share/fpcsrc/2.4.0/packages/httpd22/src/apr/apr.pas
So how does the compiler decide what version of APR to compile?
如果您启用这些条件/指令中的正确一个,那么 fpc.cfg 的其余部分应该将相应的 httpd 目录放在编译器搜索路径的第一个位置,以便采用该版本。
所以你应该只定义其中之一。
If you enable the right one of those conditionals/directives afaik, the rest of the fpc.cfg should put the corresponding httpd dir first in the compilers search path, so that that version gets taken.
So you should only define one of them.